Current location - Quotes Website - Collection of slogans - How to configure jndi of db2kettle
How to configure jndi of db2kettle
1. Update node configuration file (Linux and UNIX)

The node configuration file (db2nodes.cfg) is located in the home directory of the instance owner, and it contains some configuration information that tells DB2 which servers participate in the instance of the partitioned database environment. Each instance in a partitioned database environment has a db2nodes.cfg file.

The db2nodes.cfg file must contain an entry for each server participating in the instance. When an instance is created, the db2nodes.cfg file is automatically created and entries are added to the server that owns the instance.

For example, when using the DB2 installation wizard to create a DB2 instance on the server ServerA that owns the instance, the db2nodes.cfg file will be updated as follows:

0 server A 0

This task provides the steps to update the db2nodes.cfg file to include entries for participating computers.

To update the db2nodes.cfg file:

1) as the instance owner (in this case, db2inst 1 is the instance owner).

2) Enter the following command to ensure that the DB2 instance has stopped:

INSTHOME/sqllib/adm/db2stop,

Where INSTHOME is the home directory of the instance owner (the db2nodes.cfg file is locked when the instance is running and can only be edited when the instance is stopped).

For example, if the instance home directory is /db2home/db2inst 1, enter the following command:

/db 2 home/db 2 inst 1/sqllib/ADM/db 2 stop

3) For each DB2 instance, set the. Rhosts file. Update the file by adding the following:

& lt hostname & gt& ltdb2instance & gt

among

4) Add an entry in the db2nodes.cfg file of each participating server. When you first look at the db2nodes.cfg file, it should contain the following entries:

0 server A 0

The entry includes the database partition server number (node number), the TCP/IP host name of the server where the database partition server is located, and the logical port number of the database partition server.

If you are installing the partition configuration described in the installation overview (there are four computers with a database partition server installed on each computer), an update db2nodes.cfg similar to the following should appear:

0 server A 0

1 server B 0

2 server C 0

3 server D 0

5) After updating the db2nodes.cfg file, enter INSTHOME/sqllib/adm/db2start command, where INSTHOME is the home directory of the instance owner. For example, if the instance home directory is /db2home/db2inst 1, enter the following command:

/db 2 home/db 2 inst 1/sqllib/ADM/db 2 start

6) Cancel.

2. The first step to start DB2.

1) It is recommended to log in with the user of the instance owner, so that more functions can be used.

2) Call the default environment settings (necessary for beginners)

source/home/db 2 inst 1/sqllib/db 2 profile

Of course, if you want to configure the environment every time you start, please add this sentence to. Configuration file,. bashrc.

3) Check whether the environment variable has been set.

set | grep DB2

4) Check whether the DB2 instance is running:

PS lax | grep db 2 sysc | grep–v grep

5) Start the first step.

Db2fs (requires an absolute path, generally in the form of /home/db2inst 1/sqllib/, or /opt/ibm/db2/v9. 1/bin.

6) Use DB2FS, you can try it ~