Saturday, February 25, 2012

backup and restore

I have a database xxxx on server a, I want to copy this DB to server b.How can I do this By back and restore.
WHere can take this back up?I want to take this to a personal folder and wanted to restore to server b from this folder.Is it possible?
Thanks.On server a:
backup database xxx to disk = '\\b\sharename\xxx.bak' with init

and then on server b:
restore database xxx from disk = 'd:\sharename\xxx.bak' with replace,
move 'xxx_data' to 'e:\xxx_data.mdf',
move 'xxx_log' to 'f:\xxx_log.ldf'|||You can backup to a network location, then have a seperate job run the restore using that location. See backup [described] in BOL.

HTH

No comments:

Post a Comment