Migrating WEM Server from Solaris to Linux

This chapter covers information and steps for migrating WEM server from Solaris to Linux platform. The average time required for this migration is two hours. This document assumes that the default WEM install path is /users/ems. If you want to install WEM on a different path, such as, /opt/ems, then, replace /users/ems. with /opt/ems.

This chapter provides information on the following configuration files:

Tasks on Solaris Machine

  1. Go to WEM installation path and stop the WEM processes.

    IMPORTANT:

    Note that when you stop all the server processes, all pending traps will get deleted. If you want to retain pending traps then ignore this step and perform the next step.

    [root@solaris1
     /]# cd /users/ems/server/
    
    [root@solaris1
    server]# ./serv stop
    
    --------------
    Cisco WEM Server Manager ---------------Stopping
    Monitor Server...Monitor Server stopped.Stopping WEM Server...WEM
    Server stopped.Stopping Script Server...Script Server stopped.Stopping
    BulkStat Server...BulkStat Server stopped.Stopping BulkStat Parser...BulkStat
    Parser stopped.Stopping NorthBound Server...NorthBound Server stopped.Stopping
    Notification Service...Notification Service stopped.Stopping PCRF
    Report Generation...Stopping PCRF Report Generation with interrupt...PCRF Report
    Generation stopped.
    
  2. Take a manual backup.
    To take a manual backup, go to flash directory and create manual_backup directory and take backup of the WEM database in this directory.
    [root@solaris1
    server]# cd flash/
    
    [root@solaris1
    flash]# mkdir manual_backup
    
    [root@solaris1
    flash]# cd ../scripts
    
    [root@solaris1
    scripts]# ./backup.sh backup /users/ems/postgres /users/ems/server/flash/manual_backup/backup /users/ems/server/flash/manual_backup/logfile /users/ems/server/flash/manual_backup/errorfile
    
    [root@solaris1
    scripts]# \ls -lrt /users/ems/server/flash/manual_backup/backuptotal
    20drwxr-xr-x 2 root root 20480 Mar  7 17:03 ems_backup
    
    [root@solaris1
    scripts]# \ls -lrt /users/ems/server/flash/manual_backup/backup/ems_backup
    
    [root@solaris1
    scripts]# cd /users/ems/server/flash/manual_backup/backup
    
    [root@solaris1
    backup]# tar -cvf ems_backup.tar ems_backup/
    

Tasks on Linux Machine

Peform the following tasks on the Cisco cutomized RHEL machine.

  1. Install the WEM software on Linux machine.

    IMPORTANT:

    The WEM version that you install on the Linux machine should be the same as on the Solaris machine.

  2. Copy ems_backup.tar present in /users/ems/server/flash/manual_backup/backup directory from the Solaris machine to the Linux machine.
  3. Store it at some location. For example, /tmp/solaris_data
    [root@pnstextappsucs5
    scripts]# cd /tmp
    
    [root@pnstextappsucs5
     tmp]# mkdir  solaris_data
    
    [root@pnstextappsucs5
    tmp]# cd  solaris_data
    
    [root@pnstextappsucs5
    solaris_data]# sftp <username>@<solaris-machine-name>sftp>
    cd /users/ems/server/flash/manual_backup/backupsftp>
    get ems_backup.tarsftp> quit
    
    [root@pnstextappsucs5
    solaris_data]# lsems_backup.tar
    
    [root@pnstextappsucs5
    solaris_data]# tar -xvf ems_backup.tar
    
    [root@pnstextappsucs5
    solaris_data]# \lsems_backup
     ems_backup.tar[root@pnstextappsucs5
    solaris_data]# cd ems_backup
    
    [root@pnstextappsucs5
    ems_backup]# pwd/tmp/solaris_data/ems_backup
    
  4. Restore database.
    Restoring database will restore the WEM database from the /tmp/solaris_data/ ems_backup

    Note:

    Make sure that postgres session is not opened, that is, it is not connected to any WEM database.

    [root@pnstextappsucs5
    ems_backup]# cd  /users/ems/server/scripts
    
    [root@pnstextappsucs5
    scripts]#  ./backup.sh restore
    
    \cPlease
    enter ems directory ?
    
    /users/emsPlease
    enter backup directory location ?  
    
    /tmp/solaris_data/ems_backupPlease
    enter database administrator [postgres] ?
    
    Please
    enter database port [5432] ?
    
    Proceeding
    further will stop all ems processes. Do you want to proceed?
    
    Please
    enter [yes/no] ?yes
    
    status = yes
    
    Checking
    and Stopping running EMS processes...stop -
    
    --------------
    Cisco WEM Server Manager ---------------
    
    Monitor
    Server is not running.WEM Server is not running.Script Server is
    not running.BulkStat Server is not running.BulkStat Parser is not
    running.NorthBound Server is not running.Notification Service is not
    running.
    
    PCRF Report Generation
    is not running.
    
    ----------------------------------------------------------Stopped
    EMS processesRestoring Database from /tmp/solaris_data/ems_backup Creating
    Databases...\n
    
    Applying
    schema for database ...\n
    
    DELETE
    303COPY 302Updating migrationtimestamp tableDELETE 1INSERT 0 1Restoration
    of data for database audit, mibdb, bsdb, p2pdb, trapdb continue..\n
    
    UPDATE
    0 Database Restoration is still going on as background process.User
    can start EMS processes.Data restore completion will be indicated
    through progress bar in EMS
    
    [root@pnstextappsucs5
    scripts]#
    
  5. Start WEM process.
    [root@pnstextappsucs5
    scripts]# cd ..
    
    [root@pnstextappsucs5
    server]# ./serv start
    
    ---------------
    Cisco WEM Server Manager ---------------
    
    Starting
    WEM Server...WEM Server started.PID: 10816Logfile generated as:./log/SERVER_LOG_20130307_171657/SERVER_LOGStarting
    Script Server...Script Server started.PID: 10915Logfile generated
    as:./log/SCRIPT_LOG_20130307_171707/SCRIPT_LOGStarting
    BulkStat Server...BulkStat Server started.PID: 11002Logfile generated
    as:./log/BS_SERVER_LOG_20130307_171717/BS_SERVER_LOGStarting
    BulkStat Parser...BulkStat Parser started.PID: 11054Logfile generated
    as:./log/BS_PARSER_LOG_20130307_171727/BS_PARSER_LOGStarting
    Notification Service...Notification Service started.PID: 11406Logfile
    generated as:Starting NorthBound Server...NorthBound Server started.PID:
    11473Logfile generated as:./log/NB_SERVER_20130307_114748/NB_SERVERStarting
    PCRF Report Generation...PCRF Report Generation started.PID: 11599Logfile
    generated as:./log/PCRF_REPGEN_20130307_171758/PCRF_REPGENStarting Monitor
    Server...Monitor Server started.PID: 11632Logfile generated as:/users/ems/server/log/.watchdog.log
    

Information Note:

  1. Only contents in the database are restored from Solaris to Linux machine.
  2. Configuration files present in /users/ems/server/etc directory are not restored. You must perform manual changes if modification is required in the configuration file on the Linux machine.
  3. Contents of the flash, bulkstat_archive, xmldata and data directory are not restored. If this data required on Linux machine then you must manually copy the required content.