Command Line Interface - Send Log Files

Before you Begin

Usage

To send log files from the command line, navigate to the <software installation path>\Base folder and enter the required information. You can choose to type in the commands manually at the command prompt or use an input file as described in the following sections:

Using Arguments at the Command Prompt:

sendLogFiles.exe -<argument_value>

Using an Input File:

sendLogFiles.exe -af "<location_of_input_file>\<name_of_input_file>"

Create Custom Commands

Custom commands can be created by defining new commands utilizing the required arguments.

To create custom commands:

  1. Open the GXCommands table by navigating to Start | Programs | Microsoft SQL Server 2005 | SQL Server Management Studio | Databases | CommServ.
  2. In the commandToRun column, add the appropriate arguments to a new row in the table (see Required Arguments for a list of available arguments to include).

    Note the ID number for the new command as it appears in the ID column.

  3. Open the GXCommandOSMapping table by navigating to Start | Programs | Microsoft SQL Server 2005 | SQL Server Management Studio | Databases | CommServ.
  4. Locate the ID number for your command in the GXCommandid column.
  5. Enter the operating system ID for your computer in the simOSFamily column. This information should be entered in the cell that corresponds to the command ID number. The operating system IDs supported are listed below:

    1: Linux

    2: Windows

    4: HP-UX

    5: Solaris

    6: AIX

    10: NetWare

    11: Tru64

    13: FreeBSD

    14: Macintosh

Required Arguments:

-vm Virtual machine

-vm <CommServe_name>

-CS Sends log files from the CommServe.
-rm Specifies which remote computer’s log files are to be sent.

Repeat the -rm argument to specify multiple remote computers.

-rm <remote_computer_name>

-j Sends log files for a particular Job ID.

-j <Job_ID_Number>

-w Sends the log files from all computers associated with a particular Job ID.
-db Sends the log files from the CommServe SQL database.
-sql Sends the SQL error logs.
-sl Sends the system logs.
-gu Sends information on software updates.
-cd Sends the crash dump.
-mc Sends machine information.
-sc Sends the system command output.
-gl Sends software component logs. Must be used in conjunction with either the -cs or -rm arguments.

-gl -cs OR -gl -rm

-uc Sends user-defined command output.
-FTP Used to send selected log files to an existing FTP server running the CommCell Console.

FTP Server information can be defined or overridden using the FTPServer/FTPUser/FTPPassword command.

-n Used to specify an email address to which notification emails regarding successful and failed FTP operations will be sent.

If this option is not specified, the FTP notification email will be sent to the current notification email address in the CommServe database.

A list of email addresses can be entered with comma as separator.

-n <ftp_notification_mailbox@mail.com>

-r Used to specify an email address to which the log files will be sent.

A list of email addresses can be entered with comma as separator.

-r <mailbox1@mail.com>

-d The directory to which the log files will be saved.

-d <full_directory_path>

-s Used to specify a custom subject line for the email containing the log files.

-s “<subject_line_text>

Example 1:

In this example, the log files for client1 are sent to mailbox1@mail.com. A custom subject line will be displayed in the e-mail messages.

sendLogFiles.exe -vm commserve1 -rm client1 -r mailbox1@mail.com -s “Log Files for client1

Example 2:

In this example, the CommServe log files and the log files for client1 and client2 are stored in the c:\logs directory on the CommServe computer.

sendLogFiles.exe -vm commserve1 -rm client1 -rm client2 -d c:\logs

Example 3:

In this example, the input file is located in the c:\logs directory on the CommServe computer. An input file is created which will be executed at the command prompt using the following command:

sendLogFiles.exe -af "c:\logs\logs.txt"

The input file is formatted as follows:

[<CommServe_Name>]

[s]

[<subject>]

<email_address>

[j]

<job_ID_number>

The -j and -rm commands cannot be used together in the same send log files operation.