Search This Blog

Friday, January 4, 2019

Doing Dashing DOS ... Commands

I needed a more efficient way to copy "S:\Disaster Recovery Planning\*.*" to "C:\RH\DRM\DRExternal2" by using Xcopy commands. How to say no to all “do you want to overwrite” prompts in a batch file copy?, which seems fairly popular, according to the page's "asked / viewed / active" stats:


From that page, I was able to write this command:

xcopy "s:\disaster recovery planning" c:\rh\drm\drexternal2 /e /d /y


I'm happy with the testing I've done thus far. I modified "S:\Disaster Recovery Planning\Statement-Rejection\Statement-Rejection.docx" and then re-ran the command. As you can see below, it copied the modified file:


I did learn something today, which is a really good thing. Thanks to the web page above, I learned my user profile does not have the Manage Auditing user right, per this error message:


As a concluding note, I located this page - https://social.technet.microsoft.com/Forums/ie/en-US/c4486f3d-45cb-4bfd-a6ae-f4a797d5b4ee/robocopy-error-you-do-not-have-the-manage-auditing-user-right?forum=winservergen - through Google. The proposed solution on the page You need to have the command prompt to be run as administrator. right click run as admin  does not work for me as my admin account doesn't have access to network drives - it was granted to me so that I could install software locally. I understand this because if my admin user account did have access to network drives, it would be a lot of authority that I really do not want!

No comments: