Updating the TSLM system on Linux

The following example shows how to update the TSLM system on Linux®.

The TSLM binary files for the secondary or tertiary instances are references to the primary TSLM server binary files. Therefore, the version of each instance is the same.

  1. Stop all library manager and media manager processes.
    [tslm1@ermm3 ~]$ echo $USER
    tslm1
    [tslm1@ermm3 ~]$ ermmLmStop
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    
    Stop ermmLmStart daemon
    Stopping ermmLmStart PID 22158.
    ermmLmStart 22158 stopped
    Stopping LibraryManager by SIGTERM, pid 22157
    maximum retry=30, retry interval=5 [sec]
    trial [1]
    LibraryManager 22157 stopped
    ermmLmStop completed!
    
    [tslm1@ermm3 ~]$ ermmStop
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    PIDFILE=/opt/IBM/tslm1/run/ermmd.pid
    PIDLOCK=22104
    Stopping ermmStart process (PIDS=22104)...
    Stopping MediaManager process (MMPIDS=22113)...
    IBM Tape System Library Manager daemon stopped
    IBM Tape System Library Manager stopped
    
    [tslm2@ermm3 ~]$ echo $USER
    tslm2
    [tslm2@ermm3 ~]$ ermmLmStop
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    
    Stop ermmLmStart daemon
    Stopping ermmLmStart PID 22220.
    ermmLmStart 22220 stopped
    Stopping LibraryManager by SIGTERM, pid 22219
    maximum retry=30, retry interval=5 [sec]
    trial [1]
    LibraryManager 22219 stopped
    ermmLmStop completed!
    
    [tslm2@ermm3 ~]$ ermmStop
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    PIDFILE=/opt/IBM/tslm2/run/ermmd.pid
    PIDLOCK=22098
    Stopping ermmStart process (PIDS=22098)...
    Stopping MediaManager process (MMPIDS=22111)...
    IBM Tape System Library Manager daemon stopped
    IBM Tape System Library Manager stopped
    
  2. Uninstall the primary instance.
    [root@ermm3 scripts]# ./uninstall_xlinux.sh -p
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    Reading /etc/tslm.cfg...
    Checking Instance...
    ####### TSLM Configuration of Primary Instance #######
    TSLM_GROUP=tslm1
    TSLM_USER=tslm1
    TSLM_USERDIR=/home/tslm1
    TSLM_BASEDIR=/opt/IBM/tslm1
    DB_ADM_NAME=db2inst1
    DB_ADM_GRP_NAME=db2grp1
    DB_ADM_DIR=/home/db2inst1
    SQLLIB_PATH=/home/db2inst1/sqllib/bin
    Would you like to continue? (y/n)
    y
    RHEL(x86_64) 6.9 detected
    compatible mode:uninstall_xlinux.sh
    ###############################################################################
    Start of TSLM installation process on Wed Apr 25 16:04:34 JST 2018
    ###############################################################################
    
    ###############################################################################
    Checking prerequisite
    ###############################################################################
    Checking OS Version...
    RHEL(x86_64) 6.9
    Accepted
    
    ###############################################################################
    TSLM Uninstallation Menu
    ###############################################################################
    TSLM System
    TSLM Media Manager
    TSLM Library Manager
    TSLM Library Balancer
    TSLM External Library Manager
    TSLM Host Drive Manager
    TSLM CLI
    TSLM Password Creation Tool (pwgen)
    Would do you like to continue? (y/n)
    y
    ###############################################################################
    TSLM Uninstallation Menu
    ###############################################################################
    Uninstalling TSLM Library Balancer Package
    tslm-libbal-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-libbal
    Removal of tslm-libbal was successful.
    
    Uninstalling TSLM External Library Manager Package
    tslm-elm-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-elm
    Removal of tslm-elm was successful.
    
    Uninstalling TSLM Host Drive Manager Package
    Killing process of Host Drive Manager (PID: 29622)...
    
    tslm-hdm-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-hdm
    Removal of tslm-hdm was successful.
    
    Uninstalling TSLM CLI Package
    tslm-cli-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-cli
    Removal of tslm-cli was successful.
    
    Uninstalling TSLM Password Creation Tool (pwgen) Package
    tslm-pwgen-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-pwgen
    Removal of tslm-pwgen was successful.
    
    Uninstalling TSLM Library Manager Package
    Trying to run /opt/IBM/tslm1/bin/ermmLmStop...
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    
    Stop ermmLmStart daemon
    No active Library Manager found to stop.
    ermmLmStop completed!
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    
    Stop all Library Managers forcibly.
    
    
    tslm-lm-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-lm
    Removal of tslm-lm was successful.
    
    Uninstalling TSLM Media Manager Package
    Trying to run /opt/IBM/tslm1/bin/ermmStop...
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    PIDFILE=/opt/IBM/tslm1/run/ermmd.pid
    PIDLOCK=22104
    detected stale pid file
    Stopping ermmStart process (PIDS=)...
    Stopping MediaManager process (MMPIDS=)...
    IBM Tape System Library Manager not running
    
    
    tslm-mm-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-mm
    Removal of tslm-mm was successful.
    
    Uninstalling TSLM System Package
    tslm-system-1.2.0-3.ibm.x86_64
    Attempting to remove tslm-system
    Removal of tslm-system was successful.
    
  3. Install the updated version of TSLM (the primary instance).
    [root@ermm3 scripts]# ./install_xlinux.sh -b
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    Reading /etc/tslm.cfg...
    Checking Instance...
    ####### TSLM Configuration of Primary Instance #######
    TSLM_GROUP=tslm1
    TSLM_USER=tslm1
    TSLM_USERDIR=/home/tslm1
    TSLM_BASEDIR=/opt/IBM/tslm1
    DB_ADM_NAME=db2inst1
    DB_ADM_GRP_NAME=db2grp1
    DB_ADM_DIR=/home/db2inst1
    SQLLIB_PATH=/home/db2inst1/sqllib/bin
    Would you like to continue? (y/n)
    y
    RHEL(x86_64) 6.9 detected
    compatible mode:install_xlinux.sh
    ###############################################################################
    Start of TSLM installation process on Wed Apr 25 16:07:41 JST 2018
    ###############################################################################
    
    ###############################################################################
    Checking prerequisite
    ###############################################################################
    Checking OS Version...
    RHEL(x86_64) 6.9
    Accepted
    
    Checking Perl...
    Perl version 5.10.1 detected on this system.
    Accepted
    
    Checking lin_tape driver...
    lin_tape driver version 3.0.23 detected on this system.
    Accepted
    
    
    Checking packages for Media Manager...
    audit-libs-2.4.5-6.el6.i686
    libstdc++-4.4.7-18.el6.i686
    cracklib-2.8.16-4.el6.i686
    libselinux-2.0.94-7.el6.i686
    pam-1.1.1-24.el6.i686
    ksh-20120801-36.el6_9.x86_64
    db4-4.7.25-22.el6.i686
    
    Checking packages for Library Manager...
    sg3_utils-1.28-12.el6.x86_64
    sg3_utils-libs-1.28-12.el6.x86_64
    
    Checking packages for Host Drive Manager...
    sg3_utils-1.28-12.el6.x86_64
    sg3_utils-libs-1.28-12.el6.x86_64
    perl-Locale-Maketext-Simple-0.18-144.el6.x86_64
    
    Checking packages for CLI...
    perl-Locale-Maketext-Simple-0.18-144.el6.x86_64
    Checking DB2 Instance...
    Accepted
    
    DB2 10.5 is detected
    Accepted
    
    ###############################################################################
    TSLM Installation Menu
    ###############################################################################
    TSLM System
    TSLM Media Manager
    TSLM Library Manager
    TSLM External Library Manager
    TSLM Host Drive Manager
    TSLM CLI
    TSLM Password Creation Tool (pwgen)
    Would do you like to continue? (y/n)
    y
    ###############################################################################
    Checking previous installations...
    ###############################################################################
    ###############################################################################
    Start installing TSLM packages..
    ###############################################################################
    Installing TSLM System Package
    Attempting to install tslm-system-1.2.0-3.ibm.x86_64.rpm
    Installation of system was successful.
    
    Installing TSLM Media Manager Package
    Attempting to install tslm-mm-1.2.0-3.ibm.x86_64.rpm
    Installation of mm was successful.
    
    Installing TSLM Library Manager Package
    Attempting to install tslm-lm-1.2.0-3.ibm.x86_64.rpm
    Installation of lm was successful.
    
    Installing TSLM External Library Manager Package
    Attempting to install tslm-elm-1.2.0-3.ibm.x86_64.rpm
    Installation of elm was successful.
    
    Installing TSLM Host Drive Manager Package
    Attempting to install tslm-hdm-1.2.0-3.ibm.x86_64.rpm
    Installation of hdm was successful.
    
    Installing TSLM CLI Package
    Attempting to install tslm-cli-1.2.0-3.ibm.x86_64.rpm
    Installation of cli was successful.
    
    Installing TSLM Password Creation Tool (pwgen) Package
    Attempting to install tslm-pwgen-1.2.0-3.ibm.x86_64.rpm
    Installation of pwgen was successful.
    
    Creating database ermm...
    Reading /etc/tslm.cfg...
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2017 All Rights Reserved
    
    Prepare log archive for db2 instance at /home/db2inst1/sqllib/adm
    TSLM_USER=tslm1
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    Starting database instance ...
    Creating database ermm. This may take a while ...
    SQL1005N  The database alias "ermm" already exists in either the local
    database directory or system database directory.
    Cannot create database ermm.
    Would you like to recreate database ermm? (y/n)
    n
    Done!
    
    Preparing Media Manager config file...
    Config file of Media Manager "mm.xml" already exists in /opt/IBM/tslm1/conf/.
    Would you like to use the current config file? (y/n)
    y
    Done!
    
    Preparing Host Drive Manager config file...
    Config file of Host Drive Manager "genhdm.cfg" already exists in /opt/IBM/tslm1/conf/.
    Would you like to use the current config file? (y/n)
    y
    Done!
    
    Preparing External Library Manager config file...
    Config file of External Library Manager "elm.cfg" already exists in /opt/IBM/tslm1/client/tsm/.
    Would you like to use the current config file? (y/n)
    y
    Done!
    
    [root@ermm3 scripts]# ps -ef | grep ermm
    ermm      3576     1  0 Mar28 ?        00:00:00 db2
    root      4445  4425  0 Mar28 pts/7    00:00:00 su - ermm
    ermm      4446  4445  0 Mar28 pts/7    00:00:00 -bash
    root     31875     1  0 16:09 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm1/bin/ermmGenHDM
    root     31877  3403  0 16:09 pts/0    00:00:00 grep ermm
    
    [root@ermm3 scripts]# /opt/IBM/tslm1/bin/tslmlevel
    Reading /etc/tslm.cfg...(TSLM_0}
    TSLM_GROUP=tslm1
    TSLM_USER=tslm1
    TSLM_USERDIR=/home/tslm1
    TSLM_BASEDIR=/opt/IBM/tslm1
    DB_ADM_NAME=db2inst1
    DB_ADM_GRP_NAME=db2grp1
    DB_ADM_DIR=/home/db2inst1
    SQLLIB_PATH=/home/db2inst1/sqllib/bin
    Package Name                             Version
    =======================================  ==========
    TSLM Command Line Interface              1.2.0.3
    TSLM External Library Manager            1.2.0.3
    TSLM Host Drive Manager                  1.2.0.3
    TSLM Library Manager                     1.2.0.3
    TSLM Media Manager                       1.2.0.3
    TSLM pwgen                               1.2.0.3
    TSLM System                              1.2.0.3
    
  4. Re-create the reference for the secondary instance.
    [root@ermm3 scripts]# /opt/IBM/tslm1/install/manageTSLMClone.pl -c -T TSLM_1
    # tslm-system package
    the file[/opt/IBM/tslm1/ermmdbarchive] doesn't exist. ermmdbarchive is not installed.
    Reading /etc/tslm.cfg...
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    Reading /etc/tslm.cfg...
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    Creating /home/tslm2/tslmprofile...
    Creating /home/db2inst2/tslmprofile...
    # tslm-mm package
    # tslm-lm package
    Giving user "tslm2" access to SCS log directory "/var/log"...
    The group of /var/log is "root". Adding user "tslm2" to group "root"...
    Done!
    Giving group "root" access permissions to "/var/log"...
    Done!
    # tslm-hdm package
    detected RHEL6
    Creating GHDM_tslm2.conf in /etc/init...GHDM_tslm2 start/running, process 32560
    done
    # tslm-elm package
    # tslm-3494 package
    the file[/opt/IBM/tslm1/codelvel/3494.lvl] doesn't exist. tslm-3494 is not installed.
    # tslm-cli package
    # tslm-libbal package
    the file[/opt/IBM/tslm1/codelvel/libbal.lvl] doesn't exist. tslm-libbal is not installed.
    # tslm-pwgen package
    Done
    
    [root@ermm3 scripts]# ps -ef | grep ermm
    root       389     1 19 16:13 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm1/bin/ermmGenHDM
    root       391  3403  0 16:13 pts/0    00:00:00 grep ermm
    ermm      3576     1  0 Mar28 ?        00:00:00 db2
    root      4445  4425  0 Mar28 pts/7    00:00:00 su - ermm
    ermm      4446  4445  0 Mar28 pts/7    00:00:00 -bash
    root     32560     1  3 16:12 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm2/bin/ermmGenHDM
    
  5. Start all library manager and media manager processes.
    [tslm1@ermm3 ~]$ ermmStart
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    Spawning IBM Tape System Library Manager daemon
    Using log file: /opt/IBM/tslm1/log/ermmstart.log. Please check this file in case of problems.
    [tslm1@ermm3 ~]$ ermmLmStart
    /opt/IBM/tslm1
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    Added lm-lm3592-3.xml into proc list.
    Update proccess list: /opt/IBM/tslm1/run/ermmLmProc.lst
    Checking core files in /opt/IBM/tslm1/bin/../run/lm-lm3592-3...
    Checking log files in /opt/IBM/tslm1/bin/../log...
    No core dump file to process.
    Starting background daemon.
    ermmLmStart daemon is started.
    
    [tslm2@ermm3 ~]$ ermmStart
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    Spawning IBM Tape System Library Manager daemon
    Using log file: /opt/IBM/tslm2/log/ermmstart.log. Please check this file in case of problems.
    [tslm2@ermm3 ~]$ ermmLmStart
    /opt/IBM/tslm2
    IBM Tape System Library Manager
    Licensed Materials - Property of IBM
    (C) Copyright IBM Corp. 2004, 2018 All Rights Reserved
    
    US Government Users Restricted Rights - Use, duplication or
    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    Added lm-lmLTO.xml into proc list.
    Update proccess list: /opt/IBM/tslm2/run/ermmLmProc.lst
    Checking core files in /opt/IBM/tslm2/bin/../run/lm-lmLTO...
    Checking log files in /opt/IBM/tslm2/bin/../log...
    No core dump file to process.
    Starting background daemon.
    ermmLmStart daemon is started.
    
    [tslm2@ermm3 ~]$ ps -ef | grep tslm
    tslm1      679     1  0 16:14 pts/2    00:00:00 /bin/ksh /opt/IBM/tslm1/bin/ermmStart -z
    tslm1      688   679  1 16:14 pts/2    00:00:00 /opt/IBM/tslm1/bin/MediaManager -r /opt/IBM/tslm1/nls/mm /opt/IBM/tslm1/conf/mm.xml
    tslm1      739     1  0 16:14 ?        00:00:00 /opt/IBM/tslm1/bin/LibraryManager -d -nocopyright -s /opt/IBM/tslm1/conf/lm-lm3592-3.xml
    tslm1      740     1  0 16:14 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm1/bin/ermmLmStart
    tslm2      763     1  0 16:14 pts/1    00:00:00 /bin/ksh /opt/IBM/tslm2/bin/ermmStart -z
    tslm2      773   763  0 16:14 pts/1    00:00:00 /opt/IBM/tslm2/bin/MediaManager -r /opt/IBM/tslm2/nls/mm /opt/IBM/tslm2/conf/mm.xml
    tslm2      806     1  0 16:14 ?        00:00:00 /opt/IBM/tslm2/bin/LibraryManager -d -nocopyright -s /opt/IBM/tslm2/conf/lm-lmLTO.xml
    tslm2      807     1  0 16:14 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm2/bin/ermmLmStart
    root       826     1  2 16:14 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm2/bin/ermmGenHDM
    root       964     1 51 16:15 ?        00:00:00 /usr/bin/perl /opt/IBM/tslm1/bin/ermmGenHDM
    tslm2      965 19847  0 16:15 pts/1    00:00:00 ps -ef
    tslm2      966 19847  0 16:15 pts/1    00:00:00 grep tslm
    root     19846 28922  0 10:39 pts/1    00:00:00 su - tslm2
    tslm2    19847 19846  0 10:39 pts/1    00:00:00 -bash
    root     28740 24526  0 15:58 pts/2    00:00:00 su - tslm1
    tslm1    28741 28740  0 15:58 pts/2    00:00:00 -bash