How to backup my files using xcopy or robocopy on Windows 7 and have it actually work

jkurant
jkurant used Ask the Experts™
on
What is Microsoft doing to us? I have the simplest possible requirement. I want to
copy c:\users\jason\My Documents\*.* to F:\backups\jason\My Documents
and
copy c:\users\jason\My Pictures\*.* to F:\backups\jason\My Pictures
and
copy c:\users\Marcia\My Documents\*.* to F:\backups\Marcia\My Documents
and
copy c:\users\Marcia\My Pictures\*.* to F:\backups\Marcia\My Pictures

So, I am just copying jason's and Marcia's files to a removable drive. SIMPLE! You used to be able to simply use XCOPY <Source> <dest> /s /e

But now I get all these ridiculous access denied errors. So, I set up a user called Backup Processor, and made it an administrator. I created a batch file that did XCOPYs and then I tried ROBOCOPY to copy the four folders as shown above. First it created hidden folders and so I created the folders before ROBOCOPY. But now I am getting access denied on the removable drive! ROBOCOPY copied a bunch of files to my F: drive and I can drill down to F:\backups\jason but when I double-click on My Documents I get Access Denied.

All users on the system are administrators. I have logged in as each of the three users on the system (Jason, Marcia and Backup Processor) and accessed the My Documents and My Pictures folders of the other two users, requesting access because of the prompt that asks if the user should get access. I thought maybe with that access ROBOCOPY would copy the files so I can actually access them.

Does anyone know the trick to making this work? I am baffled and very seriously thinking about going to Apple computer. I have been a microsoft developer for many years and I have just had it with Microsoft. They are making the simplest thing impossible!

Any ideas?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Commented:
1.  go to c:\windows\system32
2. right click on cmd.exe and click on [run as a different user]
3. use the local administrator username and password
4. once the command prompt opens up, type the following command:

***make sure you use " quotation marks " for the source and the destination!!!
***if the below doesn't work, then proceed to 5.

xcopy /CHEZK "c:\users\jason\My Documents\" "F:\backups\jason\My Documents"

***keep the command prompt open!

5. if the above doesn't work, then continue with the below steps....
6. type the following command

f: [ENTER]

7. after F: and then hitting enter, you should see the command prompt change to f:\
8. now type the following command

xcopy /CHEZK "c:\users\jason\My Documents\" "F:\backups\jason\My Documents"

9. continue the same for the rest of the copy jobs....
Commented:
one last thing......I don't understand how you have "My Documents" if you are running windows 7?!....


if you are trying to copy the files from a different computer, you may have to go to the security properties and do 2 things....

1. make yourself the owner of the files

2. remove security permissions and grant yourself full control

microsoft - take ownership of a file

windows 7 - permissions and ownership
Distinguished Expert 2017

Commented:
robocopy "c:\user\jason"  "f:\backups\jason\  /E /copy:dato  /xd "Application Data" /XD "Local"

Use the /L flag to see what would be copied and use the /XD to exclude directories you do not want /XF to exclude files.
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Lee W, MVPTechnology and Business Process Advisor
Most Valuable Expert 2013

Commented:
The problem is that Windows 7 enforces security on user folders - you (jason) don't have access to "Marcia's" folder.

I would suggest you look into other forms of backup or make scripts for each user.  You can also adjust permissions on the other user's folders if you're an admin.

I've started using IDrive for backup - 5 GB free for an online backup service.

Author

Commented:
Your comment about "My Documents" vs "Documents" got me thinking. I believe the My Documents folder that I saw on my customer's machine was actually a shortcut that was created either by Windows or possibly some utility that someone used to copy my customer's data from one machine to another. I think I was trying to copy the shortcut. I'll find out once I get back to my customer's computer, but with your help I should be able to take ownership of the files, fix any permissions problems and get the backup to work properly.
Thanks!

Author

Commented:
@ajjmunoz:
Your comment about "My Documents" vs "Documents" got me thinking. I believe the My Documents folder that I saw on my customer's machine was actually a shortcut that was created either by Windows or possibly some utility that someone used to copy my customer's data from one machine to another. I think I was trying to copy the shortcut. I'll find out once I get back to my customer's computer, but with your help I should be able to take ownership of the files, fix any permissions problems and get the backup to work properly.
Thanks!

(I wrote this twice so people would know who i was responding to)

Commented:
Thanks for the acknowledgement and points. Take care.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial