addNode.sh
To incorporate a WAS installation into a cell run...
$WAS_HOME/bin/addNode.shThe node agent server is automatically started as part of the addNode.sh command. After a reboot, run a startNode.sh before stating any appservers.
The command syntax is...
addNode.sh deploymgr_host deploymgr_port [options]The deploymgr_host argument is required. The default port number is 8879 for the default SOAP port of the deployment manager. If you install the deployment manager using coexistence ports, the default SOAP port is 8889.
Parameters
The following options are available for the addNode.sh command...
-nowait Tells the addNode.sh command not to wait for successful initialization of the launched node agent process.
-quiet Suppresses the progress information that the addNode.sh command prints in normal mode.
-logfile filename Specifies the location of the log file to which information gets written.
-replacelog Replaces the log file instead of appending to the current log.
-trace Generates trace information into a file for debugging purposes.
-replacelog By default, the addNode.sh command appends to the existing trace file. This option causes the addNode.sh command to overwrite the trace file.
-noagent Tells the addNode.sh command not to launch the node agent process for the new node.
-username name Specifies the user name for authentication if security is enabled. Acts the same as the -user option.
-user name Specifies the user name for authentication if security is enabled. Acts the same as the -username option.
-password password Specifies the password for authentication if security is enabled.
-conntype type Specifies the JMX connector type to use for connecting to the deployment manager. Valid types are SOAP or RMI, which stands for Remote Method Invocation.
-includeapps By default the addNode.sh command does not carry over applications from the stand-alone servers on the new node to the cell. This option tells the addNode.sh command to attempt to include applications from the new node. If the application already exists in the cell, a warning is printed and the application is not installed into the cell. By default, during application installation, application binaries are extracted in the...
$WAS_HOME/installedApps/cellName...directory. After the addNode.sh command, the cell name of the configuration on the node that you added changes from the base cell name to the deployment manager cell name. The application binaries are located where they were before the addNode.sh command ran, for example, ...
$WAS_HOME/installedApps/old_cellNameIf the application was installed by explicitly specifying the location for binaries as the following example
where the variable ${CELL}, specifies the current cell name, then when the addNode.sh command runs, the binaries are moved to the following directory${INSTALL_ROOT}/${CELL}${INSTALL_ROOT}/currentCellNameYou have to use the -includeApps option to migrate all the applications to the new cell. Federating the node to a cell using the addNode.sh command does not merge any cell level configuration, including virtual host information. If the virtual host and aliases for the new cell do not match WAS, you cannot access the applications running on the servers. You have to manually add all the virtual host and host aliases to the new cell, using the administrative console running on the deployment manager.
-startingport portNumber Supports the specification of a port number to use as the base port number for all node agent and JMS server ports created during the addNode.sh command. With this support you can control which ports are defined for these servers, rather than using the default port values. The starting port number is incremented to calculate the port number for every node agent port and JMS server port configured during the addNode.sh command.
-help Prints a usage statement.
-? Prints a usage statement.
addNode.sh Process
addNode.sh...
- Copies the base WAS cell configuration to a new cell structure. This new cell structure matches the structure of deployment manager.
- Creates a new node agent definition for the node that the cell incorporates.
- Sends commands to the deployment manager to add the documents from the new node to the cell repository.
- Performs the first configuration synchronization for the new node, and verifies that this node is synchronized with the cell.
- Launches the node agent process for the new node.
After federating the node, the addNode.sh command backs up the plugin-cfg.xml file from the...
$WAS_HOME/config/cells...directory to the config/backup/base/cells directory. The addNode.sh command in Fix Pack 2 regenerates a new plugin-cfg.xml file at the Deployment Manger and the nodeSync operation copies the files to the node level.
Red Hat Notes
Red Hat users: The default Red Hat installation creates an association between the host name of the machine and the loopback address -- 127.0.0.1. In addition, the /etc/nsswitch.conf file is set up to use the /etc/hosts path before trying to look up the server using a name server. This setup can cause failures when trying to add or administrate nodes when the deployment manager or appserver is running on the Red Hat system.
If your deployment manager or your appserver run on the Red Hat system, perform the following operations on your Red Hat machines to ensure that you can successfully add and administer nodes...
- Remove the 127.0.0.1 mapping to the local host in the /etc/hosts path.
- Edit the /etc/nsswitch.conf file so that the hosts line reads
hosts: dns files
Usage scenario
The following examples demonstrate correct syntax
addNode.sh testhost 8879 addNode.sh deploymgr 8879 -trace (produces the addNode.log file) addNode.sh host25 8879 -nowait (does not wait for a node agent process)where 8879 is the default port.Example output
D:\WebSphere\AppServer\binaddnode dmgr_host ADMU0116I: Tool information is being logged in file D:\WebSphere\AppServer\logs\addNode.log ADMU0001I: Begin federation of node node_name with deployment manager at dmgr_host:8879. ADMU0009I: Successfully connected to deployment manager server: dmgr_host:8879. ADMU0505I: Servers found in configuration... ADMU0506I: Server name: server ADMU2010I: Stopping all server processes for node node_name ADMU0512I: Server server cannot be reached. It appears to be stopped. ADMU0024I: Deleting the old backup directory. ADMU0015I: Backing up the original cell repository. ADMU0012I: Creating node agent configuration for node: node_name ADMU0014I: Adding node node_name configuration to cell: cell_name ADMU0016I: Synchronizing configuration between node and cell. ADMU0018I: Launching node agent process for node: node_name ADMU0020I: Reading configuration for node agent process: nodeagent ADMU0022I: Node agent launched. Waiting for initialization status. ADMU0030I: Node agent initialization completed successfully. Process ID is... 2340 ADMU0523I: Creating queue manager for node node_name on server jmsserver ADMU0525I: Details of queue manager creation can be seen in the file... createMQ.node_name_jmsserver.log ADMU9990I... ADMU0300I: Congratulations! Your node node_name has been successfully incorporated into the cell_name cell. ADMU9990I... ADMU0306I: Be aware... ADMU0302I: Any cell-level documents from the stand-alone node_name configuration have not been migrated to the new cell. ADMU0307I: You might want to... ADMU0303I: Update the configuration on the cell_name deployment manager with values from the old cell-level documents. ADMU9990I... ADMU0306I: Be aware... ADMU0304I: Because the -includeapps option was not specified, applications installed on the stand-alone node were not installed on the new cell. ADMU0307I: You might want to... ADMU0305I: Install applications onto the cell_name cell using the wsadmin $AdminApp command or the administrative console. ADMU9990I... ADMU0003I: Node node_name has been successfully federated.
See Also
Port number settings in WAS versions