Adding Targets Using EMCLI

You can add a MySQL target using the EMCLI add_target command.

For information on the add_target command, see add_target in Enterprise Manager Command Line Interface.

If you are adding a target using the EMCLI add_target command, refer to the following tables to ensure that the -type and -properties parameters contain the correct values.

Target Type Parameter Values

Target Type -type Parameter Value
MySQL Database oracle_omys_database
InnoDB Cluster oracle_omys_cluster
InnoDB Clusterset oracle_omys_clusterset

Configuration Property Parameter Values

Configuration Property -properties Parameter Value
Username <type>_username
Password <type>_password
Host <type>_host
Port <type>_port
Socket <type>_socket
Use Secure <type>_use_secure
Kerberos KDC Server <type>_kerberos_kdc
Kerberos Realm <type>_kerberos_realm
Kerberos Configuration File <type>_kerberos_config
Client Truststore <type>_ts_dir, <type>_ts_type, <type>_ts_pass

Note:

You must replace <type> in the Configuration Property Parameter Values table with the target type being used, as listed in the -type Parameter Value column in the Target Type Parameter Values table.

Here is an example of how to add a target that connects to a remote database via TCP:

emcli add_target
      -name="MySQL Database Target"
      -type="oracle_omys_database"
      -host="oma.example.com"
      -properties="oracle_omys_database_username:$USERNAME;oracle_omys_database_passw
       ord:$PASSWORD;oracle_omys_database_host:db.example.com;oracle_omys_database_port
       :3306;"