[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Commands Reference, Volume 1

crex Command

Purpose

Starts the concurrent daemon for the Distributed System Management Interface Tool (DSMIT).

Syntax

crex [ -w Machine ,Machine ... ] [ -W Domain ,Domain ] ... ] Command

Note: Add a space after the -w and -W flags. Do not put a space between the comma and multiple values for the Machine or Domain parameters. If the Command includes any spaces, then the Command must be enclosed in double quotes (").

Description

The crex command allows you to bypass the DSMIT interface by entering commands at the command line. The command is sent to all the machines specified in concurrent mode. To send commands to machines specified in sequential mode, see the srex command.

Note: If the command contains any reserved shell characters such as a single quote ('), ampersand (&), or pipe symbol (|), use double quotes to enclose the command. If the command contains double quotes ("), use single quotes to enclose the command.

To use the crex command, you must have your system configured correctly as a DSMIT server. To learn more about DSMIT and configuring your system, see "Distributed System Management Interface Tool (DSMIT) Overview," in Distributed SMIT 2.2 for AIX: Guide and Reference.

Note: Do not use the crex command with interactive commands such as passwd or full-screen commands such as diag. To run interactive commands, use the srex command.

Propagating Commands Through Multiple Managing Machines

The crex command can be used for a fast fan-out of commands. For example, suppose that A, B, and C are DSMIT managing machines and that B and C are connected by a slow communication line. A domain of managed machines (Domain_B) is on a LAN together with machine B, and a domain of managed machines (Domain_C) is on a LAN together with machine C. To use managing machine A to execute a non-interactive command on the managed machines in Domain_B and Domain_C, follow these steps:

  1. Root must be a registered DSMIT administrator on machines B and C.
  2. Enter the following commands on A to establish root's DSMIT administrator credentials on B and C:
    srex -w B,C dsmit-login
  3. Send a command from A to B and C. In this example, we remove the user davis from all of the managed machines in Domain_B and Domain_C :
    crex -w B "crex -W Domain_B rmuser davis"
    crex -w C "crex -W Domain_C rmuser davis"
    Note: Alternatively, you could run crex -w B,C "crex -W Domain_B rmuser davis","crex -W Domain_C rmuser davis"

Flags

-w Machine Specifies the machines to be in the working collective.
-W Domain Specifies the domains to be in the working collective.

Security

Access Control: You must be a registered DSMIT administrator to run this command.

Examples

  1. To gather all the network information for a domain and save it in a file, enter:
    crex -W Domain "netstat -rn" > network_info
    The network data is saved in network_info within the current directory.
  2. To see if a guest account exists on a specific machine or on a machine within a domain, enter:
    crex -w Machine -W Domain 'lsuser -a id ALL | grep -e "host" -e "guest"'
  3. To remove user adam from machine A and user davis from machine B, enter:
    crex -w Machine_A,Machine_B "rmuser adam","rmuser davis"
    DSMIT matches the first command with the first machine, the second command with the second machine, and so on.

Files

/usr/share/DSMIT/domains Contains the list of domains used by DSMIT.
/usr/share/DSMIT/dsmitos Contains the list of operating systems of DSMIT clients.
/usr/share/DSMIT/hosts Contains the list of machines with DSMIT installed that can run commands built by the DSMIT server.
/usr/share/DSMIT/security/v5srvtab Stores the local machine's unique DSMIT principal key.
/usr/share/DSMIT/security/admin.cfg Stores the DSMIT administrator's keys
/usr/share/DSMIT/security/managing.cfg Stores intermediate keys used by the managing systems.
/usr/share/DSMIT/security/managed.cfg Stores the managed machine's DSMIT principal keys.
/usr/share/DSMIT/security/dsmit.ptr Stores the name of the DSMIT configuration file server.

Related Information

The srex command, dsmit command.

Distributed System Management Interface Tool (DSMIT) Overview in the Distributed SMIT 2.2 for AIX: Guide and Reference.


[ Previous | Next | Contents | Glossary | Home | Search ]