ServiceManager

This document lists and describes the start parameters of the Automic ServiceManager.

General

UNIX:

Starting the ServiceManagers: nohup ./ucybsmgr [-ipath and name of the INI file]  phrase&

Windows:

Installing the service: UCYBSMGR[.EXE] -install phrase [-ipath and name of the INI file]
De-installing the service: UCYBSMGR[.EXE] -remove phrase

Command Line Program

With the command line program UCYBSMCL, the ServiceManager can be managed through batch processing. Services can be started and ended with this program. A list of all services of a computer belonging to a ServiceManager environment can also be called up. The command line program is available for Windows and for UNIX.

Please mind the correct spelling as upper and lower case are distinguished.

Syntax

Windows:

UCYBSMCL[.EXE]  -c GET_PROCESS_LIST -h computer name -n phrase
UCYBSMCL[.EXE]  -c START_PROCESS -h computer name -n phrase -s name of the service [-p password]
UCYBSMCL[.EXE]  -c STOP_PROCESS -h computer name -n phrase -s name of the service [-m stop mode] [-p password]

Unix:

ucybsmcl  -c GET_PROCESS_LIST -h computer name:port number -n phrase
ucybsmcl  -c START_PROCESS -h computer name:port number -n phrase -s name of the service [-p password]
ucybsmcl  -c STOP_PROCESS -h computer name:port number -n phrase -s name of the service [-m password] [-p password]

Parameter Descriptions

Start Parameter

Assignment

Description

-c

 

Command that is to be processed.
This parameter must always be specified.

 

GET_PROCESS_LIST

Requests a list of all services belonging to a ServiceManager environment on a computer together with the available information.

 

START_PROCESS

Starts a service

 

STOP_PROCESS

Stops a service

-h

 

Computer
This parameter must always be specified.

 

Computer name

Name of the computer on which the ServiceManager is to be handled.

A remote computer can also be used. This computer must be available from the computer which is calling it. The user must be authorized to access services on this remote computer.

 

Port number 

In UNIX, the port number of the ServiceManager must additionally be indicated.

-n

 

ServiceManager environment.
This parameter must always be specified.

 

Phrase

Name of the ServiceManager environment which summarizes/outlines the various AE services on a computer. In the dialog program of the ServiceManager, this is designated as a phrase.

-s

 

Service.
This parameter must always be specified, with the sole exception of GET_PROCESS_LIST.

 

Name of the service

Specification of the name of a service

Available in the following places:

  • it is shown in the "Service" column of the dialog program
  • it is listed in the definition file Phrase.SMD
  • in the output of the command  GET_PROCESS_LIST

Since a service name can also contain spaces, it should always be entered within quotation marks.

-m

 

End mode.
This parameter is optional for STOP_PROCESS.

 

Stop mode

Way in which a service should be ended

Allowed values: "C" (default value), "S", "A"
"C" = Close. The service ends normally.
"S" = Shutdown. The service stops immediately independent of ongoing tasks.
"A" = Abnormally. The service is immediately stopped by the ServiceManager through a system call (kill). Use this command only when attempts by the service to stop itself were not successful.

-p

 

Password.
This parameter is optional for START_PROCESS and STOP_PROCESS. For information on encrypting passwords, see Encoding Passwords.

 

Password

Password for service start and stop authorization.

-sm  

The start mode of server work processes (WPs)

The values that are allowed for the parameter -sm depend on the service definition in the ServiceManager's SMD configuration file.
To ensure that a specific start mode can be assigned to the WP when it starts, you must set START1=, START2=, START3= ... in the SMD file for each DEFINE of a WP service. The supplied SMD file UC4.SMD includes some sample definitions.

  Start mode

For example, the definition of a WP service in an SMD file (including variables):

VAR SRV_STARTPATH;*OWN\..\..\Server\bin
VAR WP_STARTCMD;*SRV_STARTPATH\UCsrvwp.exe *SRV_STARTPATH\ucsrv.ini -svc%port%
VAR WP_STARTCMD_COLD;*WP_STARTCMD -parm"StartMode=Cold"
VAR WP_STARTCMD_STOP;*WP_STARTCMD -parm"SystemStop=Yes"
VAR WP_STARTCMD_COLDSTOP;*WP_STARTCMD -parm"StartMode=Cold;SystemStop=Yes"

DEFINE UC4 WP2;*WP_STARTCMD;*SRV_STARTPATH;START1=(Coldstart,*WP_STARTCMD_COLD);START2=(Systemstop,*WP_STARTCMD_STOP);START3=(Coldstart with Systemstop,*WP_STARTCMD_COLDSTOP)

For this WP service, the following values can be used for the parameter -sm

"Coldstart" = Cold start mode
"Systemstop" = Normal start. The system is stopped for this purpose.
"Coldstart with Systemstop" = Cold start including a system stop.

When you call the command line program using incorrect or missing parameters, a short help text will be displayed that shows correct parameters and return codes.

 


Output

When you call the command line program with the GET_PROCESS_LIST command, the requested information will be displayed line by line. It corresponds to the view of the ServiceManager Dialog program.

Output format

"Service" "StatusZustand einer Aufgabe (z.B. aktiv, blockiert, in Generierung, usw.)." ["ProcID" "Start time" "Runtime" "CPU Time"]

Column/Field

Description

Service

The name of the service.

Status

Service status.
"R" = Running. Service is active.
"S" = Stopped. Service ended.

ProcID

Process number of a service
Only information pertaining to active services (Status = R) will be displayed.

Starttime

The start date and time of a service.
Format: "YYYY-MM-DD HH:MM"
Only information pertaining to active services (Status = R) will be displayed.

Runtime

The runtime of a service.
Format: "DD/HH:MM"
Only information pertaining to active services (Status = R) will be displayed.

CPU Time

The CPU time that a service requires.
Format: "DD/HH:MM:SS:HS"
HS represents hundredths of seconds
Only information of active services (Status = R) will be displayed.

 


Return Codes

Return code

Description

0

A command has been processed without an error.

1

An incorrect command has been entered.

2

No active ServiceManager has been located on the specified computer.

Possible reason:
Either the name of the computer was not entered, or no ServiceManager is active on this computer.

3

The ServiceManager reacts to a command in an unexpected way.

Possible reason:
The ServiceManager version is not up to date.

4

Errors occurred with the ServiceManager connection.

5

The specified ServiceManager environment is not present on the corresponding computer.

Possible reason:
The ServiceManager for the specified ServiceManager environment is either not installed or not started.

 


Examples

The first example retrieves all services that belong to the computer "WINW2K01" and the ServiceManager environment "UC4P".

UCYBSMCL.EXE -c GET_PROCESS_LIST -h WINW2K01 -n UC4P

Output:

"UC4 CP1" "R" "1588" "2004-04-05 21:39" "0/01:11" "0/00:00:22.69"
"UC4 WP1" "R" "3388" "2004-04-05 21:39" "0/01:11" "0/00:00:22.69"
"UC4 WP2" "R" "1576" "2004-04-05 21:39" "0/01:11" "0/00:00:22.69"
"Win32-Agent WIN01" "R" "2708" "2004-04-05 21:40" "0/01:11" "0/00:00:01.31"
"Win32-Agent WIN21" "R" "2392" "2004-04-05 21:40" "0/01:10" "0/00:00:01.30"
"Win32-Agent UC4MAIL" "R" "2932" "2004-04-05 21:40" "0/01:10" "0/00:00:01.31"
"SAP Agent C46" "S"
"PeopleSoft-Agent PS01" "S"

The second example terminates a UNIX agent normally.

./ucybsmcl -c STOP_PROCESS -h unixw2k01:8871 -n uc4p -s unix01 -m Close

See also: