Site icon Database Tutorials

Sybase ASE Migration from Physical to Virtual Machine

 

Pre-Migration : Questionnaire

That need to ask from the client before planning to migrate SAP Sybase ASE database servers from physical machines to virtual. This following questionnaire is necessary for mission critical systems in-order to safeguard post migration issues related to performance glitches and service interruptions.

 

Migration Activity / Action Plan

Scenario: We need to move the database from physical server machines to virtual in offline mode whereas the operating system and database versions will be the same on both servers. Downtime will be observed during this phase (i.e. depends on the size of the databases)

Current Production Server
1. First of all check and match the Mount Points / locations and their size on both the server
a. Df –h or fdisk –l
2. Check the hostnames of both servers /etc/hosts. It must be same.
3. Note the OS configuration whereas possible
4. Note the IP Addresses of both the servers.
5. Run the following SQL Queries on primary database server from isql or any query tool and save
the output on grid format on excel spreadsheet.
a. select @@version
b. sp_version
c. sp_helpdevice
d. sp_helpserver
e. sp_configure
f. select @@max_connections
g. select @@servername
h. select * from syslogins
i. select * from sysusers
j. sp_helpdb
k. sp_helpdb ‘FOR EACH Database’;

l. note the record count of important activity tables from you critical databases and export it to any external file excel or notepad etc.

6. Take the backup of all users databases using dump database command
7. Shutdown the Sybase ase of primary server using following 2 commands
a. shutdown SYB_BACKUP
b. shutdown with nowait
8. Copy the database backup to new server to any location

New Production Server

9. (Optional if you are moving all binaries from old server to new server OR Sybase ASE Server already installed in this machine) / Install the sybase ASE 15.7 Enterprise Edition on new server with the same server name as  of primary and with the same home location of $SYBASE. Follow the options and proceed the installation and default configuration. (You may change $SYBASE home if you don’t have any constraints of location / mount points in that case you need to readjust the following steps.)

10. Copy/Backup the SERVER.cfg and master.dat on the new server
11. COPYING all DB & Log Files from old server to new server with the same location
12. make a copy of RUN_SERVER File on new server (optional)
13. start DB at destination with single user mode i.e. with -m switch (-c/opt/sybase/ASE-
15_0/SYBASEPRD.cfg -m\) (optional)
14. restore the master database on new server (optional)
15. load database master from’/sw/DB_BKs/master_bk.dat’;(optional)
16. after loading sybase will shutdown automatically(optional)
17. check & verify the all user database files location (DB & LOGS)
18. Switch the IP of new server as of primary and disconnect the primary server from the network
19. Login new server with Sybase or any other less privileged user then root

Note: In case you are moving all the binaries of sybase home $SYBASE , skip the database dump and load steps from the above action plan.

20. Run $SYBASE/source.sh file to load environmental variables.
21. start the sybase with default RUN Files (i.e. $SYBASE/ASE-15/install/RUN_Servername_BS & RUN_Servename)

 

Post Migration Phase:

To ensure the successful migration of database servers we go-through the following steps.

1. login to the new / migrated server and checkout the error log (i.e. $SYBASE/ASE-15/install/servername.log) for the startup activity of new Sybase ASE
2. verify that New Sybase ASE is started using following command
a. ps –ef|grep Sybase
b. showserver
c. connect to isql or any other query tool of Sybase to verify the connectivity / availability
3. Run following queries on isql of new server and check & verify all outputs which are taken from
primary server specially user databases and logins. It must be same as of primary server. If
anything is not same as primary troubleshoot it before moving further.
a. select @@version
b. sp_version
c. sp_helpdevice
d. sp_helpserver
e. sp_configure
f. select @@max_connections
g. select @@servername
h. select * from syslogins
i. select * from sysusers
j. sp_helpdb
k. sp_helpdb’FOR EACH Database’;
4. Connect to the databases and verify the records which was exported earlier or/which as possible and go live with the new server

DONE!

Exit mobile version