Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12

Quick and Dirty DR Solution Using Robocopy Expand / Collapse
Author
Message
Posted Thursday, November 10, 2011 7:25 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Today @ 3:07 AM
Points: 904, Visits: 838

It copies the backup files not the .mdf or .ldf , moeover the article explains some params of the roocopy so that it will retry a few times to copy the backup files.

Once the backup files copied in the second location you should be able to restore the database.

This tool looks to me more as an"quick and dirty" extension of the backup so that it also push the database to another location.

Maybe what you are looking for is mirroring, replication, failover clustering, etc.

Regards,
Iulian
Post #1203525
Posted Thursday, November 10, 2011 8:59 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Friday, October 19, 2012 12:02 PM
Points: 3, Visits: 37
I couldnt agree more :)
Post #1203636
Posted Friday, November 11, 2011 9:00 AM


SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Friday, July 18, 2014 12:06 AM
Points: 27, Visits: 462
You should always run Robocopy from the standby host (the secondary) to copy from primary to secondary. This way the Robocopy uses secondary host resources and only reads the backup files from primary host.

If you have money to spend, you can use double-take. It copies at data-block level.

Jason
http://usa.redirectme.net/


Jason
http://dbace.us
Post #1204230
Posted Friday, November 11, 2011 10:22 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Tuesday, May 20, 2014 8:59 AM
Points: 42, Visits: 178
yes this article is about copying backup files but you can copy mdf and ldf from one server to another and then attach them.
Post #1204382
Posted Monday, November 14, 2011 4:29 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Monday, January 2, 2012 1:18 AM
Points: 32, Visits: 89
Great tip!
One change is needed in my opinion though:


SET /A ERRLEV = "(%ERRLEV1% & %ERRLEV2%) & 24"


Should be "(%ERRLEV1% | %ERRLEV2%) & 24"
(untested)

Otherwise you'll miss error code(s) in cases when e.g.
ERRLEV1=8 and ERRLEV2=16
or
ERRLEV1=24 and ERRLEV2=0


Edit:
Hope this example illustrates my point:
select (8 & 16) & 24 as errorcode_lost

select (8 | 16) & 24 as errorcode_active
select (0 | 16) & 24 as errorcode_active
select (8 | 8) & 24 as errorcode_active

select (5 | 6) & 24 as no_errorcode
select (0 | 0) & 24 as no_errorcode

Post #1205030
Posted Tuesday, December 27, 2011 11:10 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, December 20, 2013 1:49 AM
Points: 20, Visits: 123
Hi,

Regarding the /Z switch. Not only does it slow down the copy process, it can lead to unresponsive SQL Server. As it happens. There is a bug of some sort with this combination: robocopy with /Z switch inside SQL Agent Job on Windows Server 2003 x64 and SQL Server 2005 x64. When connection was lost between server and destination location, Windows started to aggressively trim SQL Server memory. Server started to page, and slowed down to the point of unusability. SQL Server was not configured with Lock Pages in Memory privilege.

You can test this out by disabling network card on your destination location.
Post #1227032
Posted Friday, August 3, 2012 4:26 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, July 9, 2014 2:05 PM
Points: 1, Visits: 58
This is late to the party, but for the permanent record, the experience with /Z switch is unlikely the source of the problem. Robocopy simply doesn't do unbuffered IO. In my experience on win2k3 you'll get that aggressive trim behavior from any kind of copy operation that does it buffered when the file is read into memory.

Only two options for win2k3 that I've found, use unbuffered IO utility (such as eseutil) to push the file from the SQL box to the destination box) or enable Lock Pages In Memory for the SQL process (that's a commonly suggested setting for x64 SQL on Win2k3 (but not win2k8)).

I have not experienced the same memory issue on windows 2k8 when copying, but I have limited real life experience since production env is 2k3.

ESEUTIL or RICHCOPY can both do unbuffered pushes (network pulls are always handled by win2k3 as buffered operations)




Post #1340148
Posted Saturday, August 4, 2012 3:15 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Saturday, August 4, 2012 3:09 AM
Points: 2, Visits: 2
We use RoboCopy with an add-on utility called RoboCopyPlus (www.robocopyplus.com). It wraps around RoboCopy and not only analyzes the result, based on exit code, but also compresses the logfiles to see only exceptions, and then emails them off to us depending on the result, with the compressed logfiles attached.
Plus, it generates eeventlogentries based on the copy-job result, so you can integrate the lot into a management system.
Makes the whole thing a LOT easier for us to manage and therefore much more useful and stable.
Post #1340175
Posted Saturday, September 28, 2013 12:43 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Saturday, September 28, 2013 12:42 AM
Points: 1, Visits: 0
Long Path Tool can simplify and probably end your problems in unlocking, managing and renaming files that appear to have a long filename.
Post #1499642
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse