-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I've talked about this before on-list, and so have other people... however, today I needed to add another new 2008 Server machine for backups, and decided to do it properly. I started with the solution at: http://majentis.com/2011/01/03/backuppc-with-sshrsyncvss-on-windows-server/
However, it didn't work for me, so I made a few changes as follows. Note, I've removed all the comments from the scripts I stole, but that was just because I didn't want to re-type them all... console copy and paste doesn't seem to work from the console of the server (accessed via VNC) to my desktop (linux). A copy of my comment on the web page, with the copies of my scripts/etc... If anyone has any suggestions/ideas, or makes improvements to the following, please let me know and post on the web page and this list (I figure most people won't see anything posted on the website, unless they go and look.... so that is mainly for people who find it via google in the future). I couldn?t get this to work on Windows Server 2008, so in the end I did the following: Created ?c:\Users\Administrator\myvshadow.bat? ???????????????????????????????? c:\windows\vshadow.exe -do=c: c:\windows\vshadow.exe -do=c: c:\windows\vshadow.exe -do=c: c:\windows\vshadow.exe -script=c:\shadow\vshadow-out.cmd -p c: call c:\shadow\vshadow-out.cmd c:\windows\vshadow.exe -el=%SHADOW_ID_1%,c:\shadow\c ???????????????????????????????? The reason I attempt to delete any shadows beforehand is to ensure they don?t somehow build up over time, etc?. This probably isn?t required? Then, install this script as a onboot scheduled task: schtasks /create /tn BackupPCPre /tr c:\Users\Administrator\myvshadow.bat /sc onstart Then, use Task Scheduler (GUI) to edit the task, and ensure the following options are set: ?Run whether user is logged on or not? (not default) ?Allow task to be run on demand? (default) Save, and set the Administrator username and password for the task This will create the shadow at each bootup, and map it to the c:\shadow\c directory. However, we remove that and re-create it on-demand with the pre-script backuppc will call which is now much simpler: /home/Administrator/pre-backuppc.sh ???????????????????????????????? #!/bin/bash function shadow_drive () { schtasks /run /TN BackupPCPre sleep 60 } rm -f /cygdrive/c/shadow/vshadow-out.cmd sleep 5 mkdir -p /cygdrive/c/shadow/c shadow_drive c: ???????????????????????????????? That basically calls the scheduled task, which does all the work for us?. Finally, at this point I don?t have a post script? the shadow can sit there until tomorrow when the backup runs again?. Probably I will end up creating another scheduled task as above which will do the cleanup, and call it in a similar way. I still don?t know why I didn?t have permission to do all the above using ?at?, but it seems to me that schtasks is actually easier to use anyway. Additional error checks should probably be added, and the scripts could be made more generic (to work for multiple drives). Also, perhaps you don?t want to remove shadows that were not created for backuppc, etc? This is just my first attempt, I haven?t even run a single backup yet, but the files get created properly from my ssh command. Hope this helps people?. Adam - -- Adam Goryachev Website Managers www.websitemanagers.com.au -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk3egTkACgkQGyoxogrTyiU5TwCgh2uSi0iqXsolf1AahHCZquTw i3UAoLJBb9ZtYNCQJQUQM2MbAaaGFv1E =Plja -----END PGP SIGNATURE----- ------------------------------------------------------------------------------ vRanger cuts backup time in half-while increasing security. With the market-leading solution for virtual backup and recovery, you get blazing-fast, flexible, and affordable data protection. Download your free trial now. http://p.sf.net/sfu/quest-d2dcopy1 _______________________________________________ BackupPC-users mailing list BackupPC-users@lists.sourceforge.net List: https://lists.sourceforge.net/lists/listinfo/backuppc-users Wiki: http://backuppc.wiki.sourceforge.net Project: http://backuppc.sourceforge.net/