Tivoli Header

Administrator's Guide


Starting and Halting the Server


Task Required Privilege Class
Start, halt, and restart the server System or operator

Starting the Server

The following events occur when you start or restart the Tivoli Storage Manager server:

To start the server, complete the following steps:

  1. Change to the /usr/tivoli/tsm/server/bin directory from an AIX session.

    Enter:

    cd /usr/tivoli/tsm/server/bin
    
  2. Start the server by entering:
    dsmserv
    
    Note:
    If the server does not start, set the ulimit parameter to unlimited. For example,
    ulimit -d unlimited
    

When the server is started, Tivoli Storage Manager displays the following information:

If Tivoli Storage Manager detects an invalid system date and time, the server is disabled, and expiration, migration, reclamation, and volume history deletion operations are not allowed. An error message (ANR0110E) is displayed. You may either change the system date if it is in error, or issue the ACCEPT DATE command to force the server to accept the current system date as valid. After the system date is resolved, you must issue the ENABLE SESSIONS command to re-enable the server for client sessions.

The date and time check occur when the server is started and once each hour thereafter. An invalid date is one that is:

Running the Server in Background Mode

You may choose to run the server in the background. When the server runs in the background, you control the server through your administrative client.

Attention:
Before running the server in the background, ensure the following conditions exist:
  1. An administrative node has been registered and granted system authority. See Registering Administrators.
  2. The administrative client options file has been updated with the correct SERVERNAME and TCPPORT options.
  3. The administrative client can access the Tivoli Storage Manager server.

If you do not follow these steps, you cannot control the server. When this occurs, you can only stop the server by canceling the process, using the process number displayed at startup. You may not be able to take down the server cleanly without this process number.

To start the server running in the background, enter the following:

nohup dsmserv quiet &

You can check your directory for the output created in the nohup.out file to determine if the server has started. This file can grow considerably over time.

Capturing Server Console Messages to a User Log File

You can capture Tivoli Storage Manager server console messages to a user log file with the Tivoli Storage Manager dsmulog utility. You can invoke the utility with the ADSMSTART shell script which is provided as part of the Tivoli Storage Manager AIX server package. You can have the server messages written to one or more user log files. When the dsmulog utility detects that the server it is capturing messages from is stopped or halted, it closes the current log file and ends its processing.

When you specify more than one file, Tivoli Storage Manager manages the user logs as a circular list of files based on size or change of day. You can manage the amount of space the logs used in the file system by specifying a size parameter (in kilobytes) in the ADSMSTART shell script for the dsmulog utility. When the specified limit is reached, Tivoli Storage Manager closes the current user log and opens the next user log. When the specified limit is reached on the next user log, Tivoli Storage Manager writes to the next user log and can overwrite the previous contents of the file. If a size parameter is not specified, the utility writes to the next user log file when it detects a change of day.

If the user log file names are not fully qualified in the ADSMSTART shell script, the user logs are created in the directory where ADSMSTART is invoked. The user logs should not be placed in the /usr/lpp file system because space constraints in the file system can prevent the Tivoli Storage Manager server from starting.

The following is an example of how to set up and invoke the dsmulog utility to rotate through the user logs on a daily basis:

  1. Change to the server bin directory:
    cd /usr/tivoli/tsm/server/bin
    
  2. Copy ADSMSTART.SMP to ADSMSTART:
    cp adsmstart.smp ./adsmstart
    
  3. Edit ADSMSTART. Do NOT change the first line in the file. Specify the user log files to capture messages on a daily basis. For example:
    dsmulog /u/admin/log1 /u/admin/log2 /u/admin/log3
     
    

    The following steps automatically start the server with console logging when the system is rebooted:

  4. If the server is running, halt the server.
  5. Run the dsm_rmv_itab autostart script.
  6. Run the dsm_update_itab autotrace script.
  7. Restart the server in one of the following ways:

In the above example, if you invoke the utility on Friday, on Friday the server messages are captured to log1, on Saturday the messages are captured to log2, and on Sunday the messages are captured to log3. On Monday the messages are captured to log1 and the previous Friday messages are overwritten.

The following example shows how to invoke the dsmulog utility to rotate through the user logs based on size limit:

dsmulog /u/admin/log1 /u/admin/log2 /u/admin/log3 size=500

When the server is started, the utility captures the server messages to log1 until it reaches a file size of 500 kilobytes and then changes to log2.

Tip: If the Tivoli Storage Manager server goes down unexpectedly, copy the current user logs to other file names before you restart the server. This will prevent the dsmulog utility from overwriting the current logs. You can then view the user logs to try and determine the cause of the unavailability of the server.

To log console messages during the current session, do the following:

  1. If the server is running, halt the server.
  2. Issue the dsmserv command as specified in the ADSMSTART shell script. For example:
    /usr/tivoli/tsm/server/bin/dsmserv 2>&1 | dsmulog /u/admin/log1 /u/admin/log2
    

To stop console logging and have the server automatically start after a system reboot, complete the following steps:

  1. If the server is running, halt the server.
  2. Change to the server bin directory:
    cd /usr/tivoli/tsm/server/bin
    
  3. Run the dsm_rmv_itab autotrace script.
  4. Run the dsm_update_itab autostart script.
  5. Restart the server by running the rc.adsmserv script. This script starts the server in the quiet mode.

Starting the Server in Other Modes

The following Tivoli Storage Manager command options specify how you can start the server in other modes as part of the dsmserv command. For example:

dsmserv option

Where option can be any one of the following:

quiet
Starts the server as a daemon program. The server runs as a background process, and does not read commands from the server console. Output messages are directed to the SERVER_CONSOLE.
Note:
Before issuing this command, you must have an administrative client registered and authorized with system authority. The administrative client must be started. Otherwise, the server will run in the quiet mode and you will not be able to access the server.

-o filename
Specifies an explicit options file name when running more than one server.

Defining Environment Variables

If you want to run the Tivoli Storage Manager server from a directory other than the default directory or to run multiple servers, you may have to define environment variables.

An environment variable describes the operating environment of a process, such as the home directory or the terminal in use. It provides the path that the server requires to find and create files.

For example, to define the DSMSERV_DIR environment variable to point to the usr/lpp/adsmserv/bin directory so that the server can find various files, such as dsmreg.lic or the message file (dsmameng.txt) enter:

     export DSMSERV_DIR=/usr/tivoli/tsm/server/bin

You can also define an environment variable to point to the server options file. For example, to define the DSMSERV_CONFIG environment variable to point to the server options file, enter:

     export DSMSERV_CONFIG=/usr/tivoli/tsm/server/bin/ filename.opt

where filename is the name you assigned your server options file (dsmserv.opt).

Notes:

  1. The -o parameter of the DSMSERV command can also be used to specify an options file name.

  2. The set environment command:
         setenv DSMSERV_DIR /usr/tivoli/tsm/server/bin
    
    is issued if your shell is in the "csh" family.

  3. If you want to save this environment, save these entries in the .kshrc or the .cshrc file of your $HOME directory.

  4. The dsmserv.dsk is always read from the directory in which the server is started.

Running Multiple Servers on a Single Machine

To have multiple servers running on a single machine, issue the DSMSERV FORMAT command from different directories to create multiple pairs of recovery log and database files. You do not have to install the server executable files in more than one directory.

However, if non-root users will be running servers, you must modify the access permission by adding read permission to the following files:

Use these commands as a root user to modify the permission for these files:

 chmod 755 /usr/tivoli/tsm/server/bin/dsmlicense
 chmod 755 /usr/tivoli/tsm/server/bin/dsmtli.drv

The following procedure shows how to set up an additional Tivoli Storage Manager server:

  1. Determine the directory where you want the server files created, for example, /usr/tivoli/tsm/myserver, and make that directory:
    mkdir /usr/tivoli/tsm/myserver
    
  2. Copy the dsmserv.opt file to your directory:
    cp /usr/tivoli/tsm/server/bin/dsmserv.opt
    dsmserv.opt /usr/tivoli/tsm/myserver/dsmserv.opt
    
    Note:
    Ensure that the communication parameters are unique among all other Tivoli Storage Manager servers. The communication protocols are:
    • TCPPORT for TCP/IP
    • HTTPPORT for HTTP Access in the Web Administrative Client Browser

    For example, if your first server is using the default TCPport of 1500, ensure that the new server is using a TCPport other than 1500 by providing a real value in the server options file.

  3. Set your path on the server console or from an aixterm session. Define your environment variables, for example:

    To define the DSMSERV_DIR, enter:

    export DSMSERV_DIR=/usr/tivoli/tsm/server/bin
    

    Ensure that you are in the target directory before continuing.

  4. Format the database and recovery log files, for example:
    /usr/tivoli/tsm/server/bin/dsmfmt -m -db dbvol2 5
    /usr/tivoli/tsm/server/bin/dsmfmt -m -log logvol2 9
    

    In this example, db indicates the database log, -m indicates megabytes and log indicates the recovery log. Refer to Administrator's Reference for more information on these commands.

  5. Create the database and recovery log in the desired directory for the new server, for example:
    /usr/tivoli/tsm/server/bin/dsmserv format 1 logvol2 1 dbvol2
    
    Note:
    You need additional license authorizations to run additional servers. You can use the register license file command to register these licenses. See Registering Licensed Features for more information.

Halting the Server

You can halt the server without warning if an unplanned operating system problem requires the server to be stopped.

When you halt the server, all processes are abruptly stopped and client sessions are canceled, even if they are not complete. Any in-progress transactions are rolled back when the server is restarted. Administrator activity is not possible.

If possible, halt the server only after current administrative and client node sessions have completed or canceled. To shut down the server without severely impacting administrative and client node activity with the server, you must:

  1. Disable the server to prevent new client node sessions from starting by issuing the DISABLE SESSIONS command. This command does not cancel sessions currently in progress or system processes like migration and reclamation.
  2. Notify any existing administrative and client node sessions that you plan to shut down the server. The server does not provide a network notification facility; you must use external means to notify users.
  3. Cancel any existing administrative or client node sessions by issuing the CANCEL SESSION command and the associated session number. To obtain session numbers and determine if any sessions are running, use the QUERY SESSION command. If a session if running, a table will appear showing the session number on the far left side of the screen.
  4. Find out if any other processes are running, such as server migration or inventory expiration, by using the QUERY PROCESS command. If a database backup process is running, allow it to complete before halting the server. If other types of processes are running, cancel them by using the CANCEL PROCESS command.
    Note:
    If the process you want to cancel is currently waiting for a tape volume to be mounted (for example, a process initiated by EXPORT, IMPORT, or MOVE DATA commands), the mount request is automatically cancelled. If a volume associated with the process is currently being mounted by an automated library, the cancel may not take effect until the mount is complete.
  5. Halt the server to shut down all server operations by using the HALT command.
Note:
The QUIESCE option on the HALT command is recommended only if you plan to do a database dump by using the DSMSERV DUMPDB command immediately after halting. Because Tivoli Storage Manager supports online database backup (BACKUP DB command), the DSMSERV DUMPDB command should be rarely, if ever, needed.

Stopping the Server When Running as a Background Process

If you started the server as a background process and want to stop the server, connect to the server as an administrative client and issue the HALT command. If you cannot connect to the server with an administrative client and you want to stop the server, you must cancel the process by using the kill command with the process ID number (pid) that is displayed at initialization.

Note:
Before you issue the kill command, ensure that you know the correct process ID for the Tivoli Storage Manager server.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]