6

This is a two-parter.

A) Trying to do this in server 2008, with command being run by domain admin:

Robocopy \server\c$\users D:\backupfolder /MIR

I get "Access Denied" on all files in the user folders. This works on any server but 2008 though, so it must be the new security structure.

B) After reading, I attempted the /B for "backup mode" switch on robocopy. This says the following error:

ERROR : You do not have the Backup and Restore Files user rights. ***** You need these to perform Backup copies (/B or /ZB).

ERROR : Robocopy ran out of memory, exiting. ERROR : Invalid Parameter #%d : "%s"

My user is domain admin, also added to the local "backup operators" group on the server. What do I have to do to be allowed backup/restore user rights on a 2008 server?

Aszurom
  • 463
  • 2
  • 8
  • 19
  • You may be running into an issue I've come across with robocopy, the /B (and /ZB) switches don't always work effectively on remote targets (ie shares). Do you have the same problem if you try to do this in the other direction ie with Robocopy running on the W2K8 server and pushing the data to your backup folder? – Helvick Nov 10 '09 at 14:59
  • I cannot even have a /B flag on robocopy C:\test D:\test -- I get the same "you lack the rights to use /B" error. – Aszurom Nov 10 '09 at 15:36
  • sorry, missed that. Your account needs to be either a member of the Backup Operators group or the local administrator's group on both ends to invoke /b. This is a new behaviour with user profiles with W2k8/Vista/Windows 7. – Helvick Nov 10 '09 at 17:44

5 Answers5

4

Lessons Learned:

  1. "User Account Control" is still of the devil. It was causing access denied for domain admin to read the user files.

  2. Once UAC was disabled, I was still getting access denied. This turned out to be due to server 2008's use of JUNCTION POINTS in the user profile directories. This made an recursive loop like this:

C:\users\username\appdata\appdata\appdata\appdata\appdata...

So, when using robocopy vs. a 2008 server apparently /XJD and /XJF are pretty important. (Those are for "exclude junction points for files/directory").

After addressing both above points, no more problems.

Aszurom
  • 463
  • 2
  • 8
  • 19
  • 1
    User Account Control was the best thing introduced in Vista and beyond. The fact that you or the program you are running does not know how to use it properly is another thing. Remember, this is a classic PEBCAK. – riahc3 Sep 02 '15 at 17:01
3

I'll post my solution here if it helps someone else.

You need to add user or group to following Local Security Settings

  • Security settings\Local Policies\User Rights Assignment\Back up files and direcories
  • Security settings\Local Policies\User Rights Assignment\Restore files and direcories
  • This is the only thing that worked for me, copying from local drive to usb flash drive on Windows 8.1 Professional. Thanks – kodybrown Mar 24 '15 at 17:03
1

I had this problem. Solved it by going to security, and temporarily removing the Ransom Ware protection from folders. Worked fine.

1

If it´s not working even with the "/B" switch, please try this hotfix:

Windows 2008 R2: http://support.microsoft.com/kb/979808/en-us Windows 2008: http://support.microsoft.com/kb/973776/en-us

Sepu
  • 11
  • 1
  • 1
    Welcome to Server Fault! Generally we like answers on the site to be able to stand on their own - Links are great, but if that link ever breaks the answer should have enough information to still be helpful. Please consider editing your answer to include more detail. See the [FAQ](http://www.serverfault.com/faq) for more info. – slm Apr 30 '13 at 14:06
  • @Sepu, Is there a hotfix for the Win 8.1 robocopy? – Pacerier Apr 25 '15 at 07:18
1

Make sure you run this command in command prompt you start with administrator privileges (right-click, Run as Administrator). The problems you are having sound like they are caused by the UAC.

Zoredache
  • 130,897
  • 41
  • 276
  • 420