Follow

Move old DGE to a new physical DGE

Note: these instructions are for migrating a Traverse DGE (upstream) to a new server of the same OS (e.g. Linux to Linux or Windows to Windows). Any references to TRAVERSE_HOME should be replaced with the actual Traverse installation directory (e.g. C:\Program Files (x86)\Traverse or /usr/local/traverse)

  1. Install the identical Traverse revision on the (new) destination server, as the original server
  2. Stop Traverse software components on the destination server
  3. Stop Traverse software on the (original) source server
  4. Copy the 'TRAVERSE_HOME\etc\licenseKey.xml' from the source to the same destination on the new server.
  5. Apply any customization from 'TRAVERSE_HOME\etc\emerald.xml' and 'TRAVERSE_HOME\etc\dge.xml' (namely the unique dge name) on the source to the same file on the destination server. One way to achieve this is to compare the two files to highlight the differences (e.g. 'diff' or 'compare' commands)
  6. In the rare case that changes have been made to any device signatures in 'etc\typedef', copy the customized device signatures from the source server to overwrite the copies in the destination server.  Altering files in this folder is not recommended as the folder is overwritten during upgrades.
    1. Restore the MySQL databases:

      Windows

      Copy the following files and folders from source to destination:


      TRAVERSE_HOME\database\mysql\aggregateddatadb\
      TRAVERSE_HOME\database\mysql\processdb\
      TRAVERSE_HOME\apps\silk\data\
      TRAVERSE_HOME\plugin\

      cd TRAVERSE_HOME
      net start nvdgedb

      apps\mysql\bin\mysql --defaults-file=etc\mysql.conf --execute="SHOW TABLES" --database="aggregateddatadb" > tables.txt

      for /F "skip=1" %G IN (tables.txt) DO @apps\mysql\bin\mysql --defaults-file=etc\mysql.conf --execute="REPAIR TABLE %G USE_FRM" aggregateddatadb >> logs\database_restore.log


      apps\mysql\bin\mysql --defaults-file=etc\mysql.conf --execute="SHOW TABLES" --database="processdb" > tables.txt

      for /F "skip=1" %G IN (tables.txt) DO @apps\mysql\bin\mysql --defaults-file=etc\mysql.conf --execute="REPAIR TABLE %G USE_FRM" processdb >> logs\database_restore.log

      Linux

      On the source server:
      cd /tmp/

      tar zxvf TRAVERSE_HOME/database/backup/backup-mm-dd-yy,hh-mm.tar.gz database/backup/backup_dge

      tar zxvf TRAVERSE_HOME/database/backup/backup-mm-dd-yy,hh-mm.tar.gz database/backup/backup_apm

      • Copy the following files and folders from source to destination:

      SOURCE (old DGE): /tmp/database/backup/backup_dge
      DESTINATION (new DGE): TRAVERSE_HOME/database/mysql/backup_dge/ 

      SOURCE (old DGE):/tmp/database/backup/backup_apm
      DESTINATION (new DGE): TRAVERSE_HOME/database/mysql/backup_apm/

      • Copy the following files and folders from source to destination:

      TRAVERSE_HOME\apps\silk\data\
      TRAVERSE_HOME\plugin\

  7. On the destination server:
    cd TRAVERSE_HOME

    etc/dgedb.init start restore

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf --skip-column-names -u root --password= -e 'show tables;' --database=backup_dge > /tmp/tables.txt

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/dropDGEdb.sql

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createDGEdb.sql

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createDGEdbUsers.sql

    for i in `cat /tmp/tables.txt`; do apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= --execute "RESTORE TABLE $i FROM 'TRAVERSE_HOME/database/mysql/backup_dge'" aggregateddatadb; done

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createDGEdbProcs.sql

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf --skip-column-names -u root --password= -e 'show tables;' --database=backup_apm > /tmp/tables.txt

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/dropAPMdb.sql

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createAPMdb.sql

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createAPMdbUsers.sql

    for i in `cat /tmp/tables.txt`; do apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= --execute "RESTORE TABLE $i FROM 'TRAVERSE_HOME/database/mysql/backup_apm'" processdb; done

    apps/mysql/bin/mysql --defaults-file=etc/mysql.conf -u root --password= < database/schema/mysql/createAPMdbProcs.sql

     

  8. cd TRAVERSE_HOME

    Linux
    etc/dgedb.init stop

    utils/db_optimize.sh

    Windows
    net stop nvdgedb

    utils\db_optimize.cmd

  9. Start the Traverse components on the (new) destination server

  10. Linux
    You may now delete the database/mysql/backup_dge and database/mysql/backup_apm directories after verifying test history within the Traverse UI

 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Article is closed for comments.