Group: Forum Members
I am a home user of Macrium Reflect and not a computer whiz, so a novice. Please bear that in mind when replying.
What I want to do is take a Files & Folders backup of NAS folders, and then use robocopy to sync the backups to another NAS.
The NAS folders are mapped to the PC, but as these are not visible in Macrium Reflect. I set up the the backup to access the NAS directly via the NAS' name.
This works some of the time. As I wanted to take backups automatically, it was not acceptable. I then switched the backup to use the NAS' IP address. This works every time, IF I run it from the Backup Definition file. But, as I want to use robocopy to sync the backup, I need to run the VBScript. This is scheduled, but every time it runs it fails, with the message: ' Error: Folder '\\192.168.0.7\Backup' could not be found' for each NAS folder I have included.
Any suggestions as to why this is occurring and how to automate the backup would be appreciated.
Sincerely R A Evans
Macrium Reflect v7.1.2646
P.S. I have two other backup definitions, my C and D drives, also using robocopy via a VBScript. These backup okay, but robocopy's output does not appear in the log. Have I missed something? Is it supposed to? If not, why not, surely you need to get conformation that it worked without problems?
Most Valuable Professional
Group: Forum Members
One point of clarification first: You say you're taking a backup of one NAS (call it "NAS 1") and then you want to sync the files to another NAS ("NAS 2"). So what is the destination of the actual Reflect job, i.e. where are the .mrbak files being generated before robocopy runs? Are you backing up some NAS 1 files onto NAS 1 itself?
If the backup runs when you click "Run Now" but not when scheduled, it's a credentials issue. Basically, when you click Run Now, Reflect runs under your own user account, which means that any credentials you've already entered in Windows to connect to the NAS shares -- including the credentials of your own user account -- are also available to Reflect, as well as Robocopy. By comparison, a scheduled task runs as the SYSTEM account, which does not have those credentials available -- nor would it have any drive letter mappings created in your user account available, which is why it's not recommended to use them as backup sources or destinations.
One way to fix this is to go to Other Tasks > Edit Defaults > Network. That way, Reflect will always have those credentials available, regardless of how it is started. Make sure the syntax of the path you specify here matches the definition file, i.e. if you use \\IPAddress\share in the definition file, use the same thing here. If your definition file sends jobs directly to NAS 2, you should enter credentials for that too. Note: I know that this feature was primarily intended to allow Reflect to access network destinations, e.g. for people who capture backups of their local systems and want to send them to a NAS. I'm not sure whether Reflect will use stored credentials like this to access a backup source as you need. You'll have to try it, but if that doesn't work (or even if it does), read on for further ideas.
Even if NAS 1 and NAS 2 are both directly involved in the Reflect job, credentials entered there may only help Reflect -- not Robocopy. I say "may" because the authenticated connections that Reflect opens remain open for a while after Reflect finishes, according to a Windows default (I believe 15 minutes), which might be enough time for Robocopy to "borrow" them for its work, but I've never tried that. If NAS 2 is not involved in the original backup job and/or this Reflect feature can't be used to access sources, or Robocopy just isn't working afterward, then the fallback solution would be to skip the feature I mentioned above and instead add a pair of "net use" commands to your VBS file, one each for NAS 1 and 2, that map drive letters to locations on each and specify credentials to do so -- you would want to place those lines before the Reflect job. Note that you don't have to actually use those mapped letters in Reflect or Robocopy. Creating a drive mapping to a network path with credentials means that any other connections to that network path (not just the drive letter) will be able to use those credentials. This does of course require you to store credentials in plain text in a script file though, so if that's a concern, at least make sure that file is not stored somewhere readable by any random person on the PC. You also forego one handy feature of using Edit Defaults > Network, which is that any credentials stored there will be copied into your Rescue Media so that when you boot from Rescue, those locations are automatically available, but if you're only performing F&F jobs, chances are you wouldn't need to perform any restores from Rescue anyway.
For your image jobs, which log are you looking at where Robocopy is missing? If you're looking at Reflect's log under the Logs tab, then Reflect's log only ever covers Reflect's activity. If you're calling Reflect from a VBS file and want to log other things that happen before and/or after that, you would have to make arrangements for that within your script, such as piping the Robocopy command to a log file so Robocopy's output will be recorded there. Reflect technically doesn't even know that it was called from a script, and even if it did, it wouldn't have any way to capture activity before or after it ran anyway. The way it works is not, "Scheduled task runs Reflect, which runs script file so that Reflect is open the entire time"; the way it works is, "Scheduled task runs a VBS file, part of which involves calling Reflect, so Reflect can only see its own activity."