Robocopy copying folders from the wrong place


  1. Posts : 9
    Windows 7
       #1

    Robocopy copying folders from the wrong place


    I've set up a back up batch file to copy my Documents, Pictures, Music, and Videos folders from my computer to an external hard drive.
    However, while running the Documents backup, it seems to find, the pictures, music, and videos folders all inside the documents folders labelled "My Music", etc.
    However, these folders do not exist. When I navigate in explorer to C:\Users\username\Documents\ I cannot find a folder labelled "My Music". When I try to navigate to C:\Users\username\Documents\My Music it tells me that "access is denied". I cannot find them through command line either.
    As well, when I try and find the folders on the backup drive, they do not seem to be there either.
    I just don't understand where this is coming from.
      My Computer


  2. Posts : 19,383
    Windows 10 Pro x64 ; Xubuntu x64
       #2

    Hi,

    It sounds like you are running foul of junction points. You may need to use the /XJ switch.

    Post your BAT code here, and I'll take a look at it for you.

    Regards,
    Golden
      My Computer


  3. Posts : 9
    Windows 7
    Thread Starter
       #3

    I got around the problem by specifically excluding those folders, but I would like to know why exactly this happened in the first place. What are junction points?

    Here's my batch file:


    @echo off
    ::variables
    set drive=F:

    echo Backing up Documents
    ROBOCOPY "C:\Users\*****\Documents" "%drive%\Documents" /MIR /XD "My Music" "My Pictures" "My Videos" /LOG+:"C:\Users\*****\Desktop\log.txt"

    echo Backing up Music
    ROBOCOPY "C:\Users\*****\Music" "%drive%\Music" /MIR /LOG+:"C:\Users\*****\Desktop\log.txt"

    echo Backing up Videos
    ROBOCOPY "C:\Users\*****\Videos" "%drive%\Video" /MIR /LOG+:"C:\Users\*****\Desktop\log.txt"

    echo Backing up Pictures
    ROBOCOPY "C:\Users\*****\Pictures" "%drive%\Pictures" /MIR /LOG+:"C:\Users\*****\Desktop\log.txt"

    echo Finished Backup
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 16:31.
Find Us