Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Restore Database onto another server

Status
Not open for further replies.

antzzz

Programmer
Mar 9, 2001
85
0
0
AE
We're using Sybase ASE 12 on Solaris. I took a backup of a database DB1 on SERVER A and put it onto SERVER B in a disk dump file "/opt/sybase/DB1.dmp" and I want to restore this backup on SERVER B.

The same database also exists on SERVER B but the data devices and physical device names (and paths) are different than those on SERVER A. All the database objects are the same on both servers.

Will the following simple command work:

load database DB1
from disk '/opt/sybase/DB1.dmp'

Or Do I need to do some more work? Do I need to recreate the device files exactly as on SERVER A?

Pls advise

Thanks
 
As I know important point is size of devices and order of devices.
Look the example below.
1> select * from sysusages where dbid = 12
2> go
dbid segmap lstart size vstart pad unreservedpgs
crdate
------ ----------- ----------- ----------- ----------- ------ -------------
--------------------------
12 3 0 48640 68611072 NULL 21896
Dec 21 2003 2:19PM
12 4 48640 23552 102440960 NULL 23460
Dec 21 2003 2:19PM
12 3 72192 38400 68659712 NULL 38250
Dec 21 2003 2:19PM
12 4 110592 19968 102464512 NULL 19890
Dec 21 2003 2:19PM
12 3 130560 92160 68698112 NULL 91800
Dec 21 2003 2:19PM
12 4 222720 46080 102484480 NULL 45900
Dec 21 2003 2:19PM

(6 rows affected)
1>
segmap 3 : data device
segmap 4 : log device

First 48640 page (95 Mb) should be data devices
Than 23552 page (46 Mb) should be log device.
If you do not follow this, your database will be loaded but data and log devices will be mixed.
 
Thanks for the info.

So if don't do anything on SERVER B, you mean if I do a restore, it will use the physical devices that I have on SERVER B (regardless of whether they have the same names or paths)?

Does the backup dump file retain information on physical device paths and filenames from the original server or it only contains pure data which can be restored anywhere on any server as long as I specify the same database name?

Pls advise

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top