May 3, 2006 at 1:42 pm
I need an example of a DOS Batch File which copies directories from one server to another server. I need it to handle the network drive mappings (from server to server), to overwrite directories and files if they already exists on the target server and to create directories on the target server. I am planning on scheduling the DOS Batch File using the Windows Scheduler to backup some direstories. (If you have other ways of doing this please let me know but please provide the DOS Batch File example.)
We are using Windows 2003.
Thanks in advance, Kevin
May 3, 2006 at 2:22 pm
I would have a look at using robocopy utility
May 4, 2006 at 12:56 am
Have a look at SyncToy from Mircosoft:
http://www.microsoft.com/windowsxp/using/digitalphotography/prophoto/synctoy.mspx
Look in it's help file for "Schedule SyncToy" under "SyncToy How To Topics".
This was designed for XP and Photos, but then they are just Files and Folders...
Andy
May 4, 2006 at 8:14 am
I use this kind of instruction as a last step of my backup-jobs to copy to safehaven.
XCOPY C:\MSSQL\BACKUP\*.* \\myUNCservername\myshare\MyDbServerName\Database\ /c /k /h /v /y
Johan
Learn to play, play to learn !
Dont drive faster than your guardian angel can fly ...
but keeping both feet on the ground wont get you anywhere :w00t:
- How to post Performance Problems
- How to post data/code to get the best help[/url]
- How to prevent a sore throat after hours of presenting ppt
press F1 for solution, press shift+F1 for urgent solution 😀
Need a bit of Powershell? How about this
Who am I ? Sometimes this is me but most of the time this is me
May 4, 2006 at 2:17 pm
use this script. save file as .vbs, and run. If the z:\folder exists, it will overwrite it with the d:\folder.
dim fs
dim delfolder
delfolder="z:\folder"
set fs = Wscript.CreateObject("Scripting.FileSystemObject")
If(fs.FolderExists(delfolder)) Then
fs.DeleteFolder(delfolder)
End If
fs.CopyFolder "d:\folder","z:\folder"
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply