submit_add_host
Submits an Add Host session that installs management Agents on unmanaged hosts, thereby converting them to managed hosts.
Format
emcli submit_add_host –host_names=<host_list> -platform=<platform_id> -installation_base_directory=<installation_base_directory> -credential_name=<credential_name> [-instance_directory=<instance_directory>] [-credential_owner=<credential_owner>] [-properties_file=<properties_file>] [-session_name=<deployment_session_name>] [-privilege_delegation_setting=<privilege_delegation_setting>] [-port=<agent_port>] [-deployment_type=FRESH|SHARED|CLONE] [-preinstallation_script=<preinstallation_script_location>] [-preinstallation_script_on_oms] [-preinstallation_script_run_as_root] [-postinstallation_script=<postinstallation_script_location>] [-postinstallation_script_on_oms] [-postinstallation_script_run_as_root] [-additional_parameters=<parameter1 parameter2 parameter3 .... >] [-wait_for_completion] [-source_agent=<clone_source_agent_name>] [-master_agent=<master_agent_name>] [ ] indicates that the parameter is optional
Options
-
host_names
Names of the hosts where the Agents need to be installed, separated by a semi-colon.
-
platform
ARU platform ID of the hosts where the Agent needs to be installed. To show the list of supported agent platforms, run the command emcli list_add_host_platforms -all.
-
installation_base_directory
Directory where you want to install the Agent. Provide this option in double-quotes if it is an MS-DOS/Windows-style path.
-
credential_name
Named credential to be used for installing the Agent.
-
instance_directory
Instance directory of the Agent. Provide this option in double-quotes if it is an MS-DOS/Windows-style path.
-
credential_owner
Owner of the named credential owner.
-
session_name
Session name that uniquely identifies the Add Host session.
-
privilege_delegation_setting
Privilege delegation setting you want to use to install an Agent and run the root script.
-
port
Port on which the Agent should communicate with the OMS.
-
deployment_type
Type of Agent deployment, which can be FRESH, CLONE, or SHARED. The default is FRESH.
-
preinstallation_script
Script you want to run before installing the Agent. Provide this option in double-quotes if it is an MS-DOS/Windows-style path.
-
preinstallation_script_on_oms
Use this option if the pre-installation script resides on the OMS host.
-
preinstallation_script_run_as_root
Use this option if you want to run the pre-installation script as the root user.
-
postinstallation_script
Script to run after installing the Agent. Provide this option in double-quotes if it is an MS-DOS/Windows-style path.
-
postinstallation_script_on_oms
Use this option if the post-installation script resides on the OMS host.
-
postinstallation_script_run_as_root
Use this option if you want to run the post-installation script as the root user.
-
additional_parameters
Additional parameters you want to use to install an Agent.
-
wait_for_completion
Runs the Add Host operation synchronously. If you specify this option, the command waits until the add host session completes before returning control to you on the command line.
-
source_agent
Source Agent you want to use to install a cloned Agent. The source Agent name should have the format of "agent host name:agent port". For example: foo.example.com:3872 .
-
master_agent
Master Agent you want to use to install a shared Agent. The master Agent name should have the format of "agent host name:agent port". For example: foo.example.com:3872 .
Examples
Example 1
This example submits an Add Host session on the host 'example.com', having platform ID '226' with '/opt/agent' as the installation base directory,using the named credential 'oracle' and privilege delegation setting /usr/bin/sudo -u %RUNAS% %COMMAND%.
emcli submit_add_host -host_names="example.com" -platform=226 -credential_name=oracle -installation_base_directory=/opt/agent -privilege_delegation_setting="/usr/bin/sudo -u %RUNAS% %COMMAND%"
Example 2
This example submits an Add Host session on the host 'example2.com', having platform ID '233' with 'C:\agent' as the installation base directory, and using the named credential 'oracle'.
emcli submit_add_host -host_names=example2.com -platform=233 -installation_base_directory="C:\agent" -credential_name=oracle