13.5 Registry Agent Options

The Registry Agent module allows you to perform the following tasks from the command line:

13.5.1 Registering an Agent

The following command registers an agent with the Framework Manager. It must be run from the agent machine.

To run the command and be prompted to supply information:

./unifi regclnt register

You are prompted to supply the IP address of the Framework Manager, the registration port (the default port is 29120), the DNS name or IP address of the agent machine, the agent name, then a Framework Manager username and password.

To run the command with all the parameters on the command line:

./unifi regclnt register <manager> 29120 <hostname> <agent name> <admin> <password>

Replace <manager> with the IP address of the Framework Manager, <hostname> with the DNS name or IP address of the agent machine, <agent name> with the name of the agent, <admin> with a Framework Manager username, and <password> with the user’s password. For example:

./unifi regclnt register manager1 29120 agent1.domain.com agent1 admin netiq

13.5.2 Finding a Primary Manager Package

The following command displays details about primary manager packages. It can be run from any host machine, and displays the primary manager information contained in the local machine’s databases.

Syntax: ./unifi -n regclnt getManager <package>

If you have not mapped your local account to a Framework Manager user (see Modify User: Native Maps), replace the -n option with -u <username> -p <password> options and specify the name and password of a Framework Manager user who has the rights to perform this task.

Replace <package> with one of the following: admin, audit, auth, cmdctrl, msgagnt, pkgman, registry, secaudit, syslogemit.

For example, the following command returns details about the primary Command Control Manager:

./unifi regclnt getManager cmdctrl

13.5.3 Agent Status

The following command displays the status of agents within the framework. It can be run from any host machine.

Syntax: ./unifi -n regclnt status [option]

If you have not mapped your local account to a Framework Manager user (see Modify User: Native Maps), replace the -n option with -u <username> -p <password> options and specify the name and password of a Framework Manager user who has the rights to perform this task.

Replace [option] with one or more of the following:

Option

Description

-s <server>

Displays status of the specified host. This option can be repeated on the command line for more than one host.

-o <domain>

Allows you to request status for all agents in a domain. This option can be repeated on the command line for more than one domain.

-S <server>

Confirms whether the host can communicate with the specified agent.

-M <module>

Confirms whether the agent can communicate with the specified module.

-a

Displays the status for all defined hosts.

-c

Provides output in CSV format.

-h

Prevents the display of the CVS header.

-?

Displays the usage message.

13.5.4 Adding Hosts and Domains

The unifi command supports the addition of hosts and domains directly from the command line during the host registration process. The additional roles that must be provided in the Framework User Manager are:

  • To allow creation of host records during registration

    Module: unifi Role: register_host

    Module: unifi Role: register

  • To allow creation of domain records during registration

    Module: unifi Role: register_domain

    Module: unifi Role: register

For example:

  • To create a host record from command line:

    Syntax: /opt/netiq/npum/sbin/unifi regclnt register <Manager IP Address> 29120 <Agent IP Address> /Host <admin> <password>

  • To create a host under a domain:

    Syntax: ./unifi regclnt register <Manager IP Address> 29120 <IP or hostname of agent></DomainPath/HostName of the agent> <admin> <password>

    DomainPath: If you want to register an agent to a domain, you must specify the domain path in the format Domain/SubDomain1/SubDomain2/AgentName. If the domain or sub domains does not exist, registration process creates the domain automatically and places the agent under them. DomainPath is case insensitive.