Starting the IBM Director command-line interface

Use the command-line interface to directly access many IBM Director functions.

The IBM Director command-line interface (CLI) is an important primary interface into IBM Director which may be used either as an efficient way to accomplish simple tasks directly or as an embeddable and scriptable framework for achieving higher level goals.

註: The IBM Director CLI provides support in version 5.10 for a subset of the commands previously available through the deprecated dircmd executable.

Complete the following steps to access the IBM Director command-line interface:

  1. Log in to the management server as an IBM Director super user. Log in directly, or remotely via telnet, SSH, or RSH. Command line access is solely limited to IBM Director super users, and the IBM Director command-line interface executable (dircli) is only installed with IBM Director Server.
  2. Type the command you want to execute.
    The general command syntax is described below:
    讀取語法圖表略過語法圖表
    >>-+-------------------------------------+----+---------------+--command----+--------------------+-><
       '-dircli----+-----------------------+-'    '-bundle--+---+-'             '-command_parameters-'   
                   '-management_parameters-'                '-/-'                                        
    
    
    dircli
    The dircli keyword is optional if both of the following are true:
    • the command is being run on a UNIX or Linux platform
    • the command is unique on that platform
    When these conditions are met, symbolic links are defined on installation of IBM Director Server which allow users to omit the dircli keyword.
    management_parameters
    management_parameters are principally retained for syntax compatibility with command-line execution through the dircmd executable which was implemented in earlier versions of IBM Director.
    bundle
    bundle specifies a command bundle, and is typically used with the retained commands formerly available through dircmd, or for extensions to the CLI.
    command
    command is one of the dircli commands, or one of the retained commands formerly available through dircmd. Specific syntax for each command is included in the reference topic for the command.
    command_parameters
    command_parameters are specific to the command being performed.

CLI command outputs are sent to stdout. Errors are sent to stderr.

Every CLI command that is executed is audited with the following information:
  • Executing user
  • Time stamp
  • Command
  • Command arguments
  • Return code
  • How long the command took to execute
The log is stored as ASCII text in the IBM_Director_Base_Directory\log\CLI\Log.txt file. Every time the IBM Director Server is restarted the Log.txt file is backed up to log.bk and a new log is created.

Examples

The following examples all execute the accessmo command on a UNIX platform:
dircli accessmo -n webserver
dircli managedobject/accessmo -n webserver
dircli managedobject accessmo -n webserver
accessmo -n webserver
相關參考
IBM Director CLI (dircli)
(C) Copyright IBM Corporation 1999,2005. All Rights Reserved.