IBM Support

Automatic startup of dsmcad daemon on system reboot on SUSE Linux



Automatic startup of daemon on Suse Linux may be done by adding an entry in /etc/inittab or via /etc/rc.d script which is executed by the init command at boot time or when changing runlevel. A sample configuration is provided in here.

Resolving The Problem

Starting with the Tivoli Storage Manager V6.3 client level, the client provides a startup script as /etc/init.d/dsmcad and creates a symbolic link. It is not necessary to write a startup script from scratch. For more details, refer to the online Knowledge Center. Information is available in the following section :

For clients at level V6.2 or below, the following information may be used to manually create a script.
The following discussion assumes that the Tivoli Storage Manager client acceptor daemon is responsible for the scheduler and for web client. If there are controlled separately, another script in /etc/init.d would have to be created in the same way as described below, then managedservices option should be adjusted accordingly.

1. Log in as the root user

2. Change to the /opt/tivoli/tsm/client/ba/bin directory

3. Use dsm.sys.smp as the template to create dsm.sys file. Here is an example below which assumes the client node name is tsmlinux and server hostname is tsmserver (must be in /etc/hosts or DNS):

SErvername mytsm
COMMmethod TCPip
TCPPort 1500
TCPServeraddress tsmserver
managedservices webclient schedule
nodename tsmlinux
passwordaccess generate
errorlogname /var/log/dsmerror.log
schedlogname /var/log/dsmsched.log
errorlogretention 365 S
schedlogretention 365 S

4. Use dsm.opt.smp as template to create dsm.opt file. Here is an example below which follows previous example :


5. Configure the client to start from boot

Method A Using the inittab

Add the following entry to the /etc/inittab :

cad::once:/opt/tivoli/tsm/client/ba/bin/dsmcad >/dev/null 2>&1 # TSM Webclient

Method B Using an /etc/init.d script

On a Suse linux system, adding corresponding scripts for the Tivoli Storage Manager client acceptor daemon, dsmcad, is a standard way to perform necessary administrative tasks like starting, stopping or restarting dsmcad and/or dsm scheduler using standard linux service start/stop/restart for automatic or manual operations. The below procedure may be used to configure dsmcad in such a way.

a. Create the following script file /etc/init.d/dsmcad:

#! /bin/sh
# /etc/init.d/dsmcad
# Provides: dsmcad
# Required-Start:
# Should-Start:
# Required-Stop:
# Should-Stop:
# Default-Start: 3 5
# Default-Stop: 0 1 2 6
# Short-Description: dsmcad (TSM client acceptor daemon)
# Description: Start dsmcad to launch the Tivoli Storage Manager
# client acceptor daemon, which can be used for web client access
# as well as client scheduling services.

# Check for missing binaries (stale symlinks should not happen)
# Note: Special treatment of stop for LSB conformance

# Please adjust for your Environment

test -x $DSMCAD_BIN || { echo "$DSMCAD_BIN not installed";
if [ "$1" = "stop" ]; then exit 0;
else exit 5; fi; }

#Source function library.
. /etc/rc.status

# Reset status of this service

case "$1" in
echo -n "Starting dsmcad"
export LANG LC_ALL
startproc $DSMCAD_BIN
rc_status -v

echo -n "Shutting down dsmcad"
killproc -TERM $DSMCAD_BIN
rc_status -v

$0 status
if test $? = 0; then
$0 restart
rc_reset # Not running is not a failure.

$0 stop
$0 start

echo -n "Reload service dsmcad"
$0 try-restart

echo -n "Reload service dsmcad, not supported"
rc_failed 3
rc_status -v

echo -n "Checking for service dsmcad"
checkproc $DSMCAD_BIN
rc_status -v

echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload}"
exit 1

b. Setup permissions to execute for /etc/init.d/dsmcad file (at least for root user), i.e,

# chmod 744 /etc/init.d/dsmcad

c. Now, run the insserv command to have the necessary links created in the rcN.d directory for the defauls levels specified in the INIT INFO section of the script, i.e,

# /sbin/insserv /etc/init.d/dsmcad

To have the links removed and not have dsmcad started at boot, type

# /sbin/insserv -r /etc/init.d/dsmcad

The above procedure will allow dsmcad to start automatically at system startup. It is also possible now to start and stop dsmcad using the script. For example :
  • To start dsmcad manually run:
    /etc/init.d/dsmcad start
  • To stop dsmcad run:
    /etc/init.d/dsmcad stop
  • To restart dsmcad (for example to refresh daemon after dsm.sys or dsm.opt modification) :
    /etc/init.d/dsmcad restart
  • To check if dsmcad is running run:
    /etc/init.d/dsmcad status
    ps -ef | grep dsmcad

[{"Product":{"code":"SSGSG7","label":"Tivoli Storage Manager"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"Client","Platform":[{"code":"PF016","label":"Linux"}],"Version":"All Supported Versions","Edition":"","Line of Business":{"code":"LOB26","label":"Storage"}}]

Document Information

Modified date:
17 June 2018