What's new

Sync SDXC Drive with OneDrive

Thor

New Member
Running out of space on C: so I installed a 256G chip as the SDXC drive. Want to move my Documents folder there and have it synced with OneDrive. Is this possible, and if so how?

Thanks
 
Assuming you have already adjusted OneDrive settings for the most economic use of your hard drive (see how here), you can use the "mklink /j" command to link your folders on an external drive onto OneDrive. The "mklink /j" command makes a directory junction in Windows 10.

Example:

Assume I have folder D:\myfiles\ on my SDXC.
1. Create a folder on OneDrive which will sync with the "myfiles" folder and all its sub-folders. For example, Dfiles
2. Open a DOS command prompt ("cmd"), and ...
3. mklink /j "%UserProfile%\OneDrive\Dfiles" "D:\myfiles\"

OneDrive will begin syncing your files from D:\myfiles\ to the Onedrive folder.

To undo (remove or delete) this directory junction, you would run command:
rmdir “D:\myfiles\"
 
Assuming you have already adjusted OneDrive settings for the most economic use of your hard drive (see how here), you can use the "mklink /j" command to link your folders on an external drive onto OneDrive. The "mklink /j" command makes a directory junction in Windows 10.

Example:

Assume I have folder D:\myfiles\ on my SDXC.
1. Create a folder on OneDrive which will sync with the "myfiles" folder and all its sub-folders. For example, Dfiles
2. Open a DOS command prompt ("cmd"), and ...
3. mklink /j "%UserProfile%\OneDrive\Dfiles" "D:\myfiles\"

OneDrive will begin syncing your files from D:\myfiles\ to the Onedrive folder.

to undo (remove or delete) this directory junction, you would run command:
rmdir “D:\myfiles\"
 
I tried this with the command line and results as shown in the attachment. Have I misunderstood something? I am trying to sync my Documents folder to the Documents folder on the SDCX drive (F:) It has been synced to the Documents folder in the C: drive. Do I need to stop that synchronization in order to allow this to work? I was planning to do that after I had verified that this worked and then also delete the files in the Documents folder on the C:drive
Make Link Command Line.png
 
You neglected to include three spaces, highlighted below.
Annotation 2020-04-12 074057.png


Cut and paste the correct command into your DOS command window:
mklink /j "%UserProfile%\OneDrive\Documents" "F:\Documents\"
 
Thanks, that fixed the initial problem but I still have a problem. The response indicates that the Documents folder already exists. So I went to OneDrive and tried to delete it. It appears the the document folder has a unique status in Windows (or have i misinterpreted the error message?). I can't delete it. I even went to settings and stopped the backup to Documents and still couldn't delete it. I suppose that I could create a Documents 2 folder and use it as the backup folder but maybe this is just all getting too complicated. I really appreciate your help.
Make Link 2.png
 
The Documents folder is indeed special. You are only allowed to have one official Documents folder.

To move your documents folder to the SDXC drive, you must right-click on the documents folder in File Explorer, and choose Properties, then the Location tab, then Move. This will allow you to change its location on your computer.

It is a bit troublesome and slow to move your Documents folder to the SDXC card. Is it possible instead to move some other folder to free up space on your C:\ ?
 
Changed the location in File Explorer, although the Documents folder did not show up in SDXC F: . What I have there now is a shortcut to OneDrive which will pull down the documents files when I click on it. So the command line command gives me the same result: Cannot create a file..... Have tried various things, including deleting the Documents folder from C:\ . The reason I want to do this is that I want to have all my Documents files physically resident on my computer, and backed up to OneDrive. This gives me the ability to work offline and to back up these files to my backup drives. I thought that previous to this, I had it set up so that all those files resided on my C: drive and were synced to OneDrive. Is it possible that somehow the system decided to delete the files from C: and when I thought that I was accessing them there I was actually pulling them down from OneDrive. This is all getting very convoluted and maybe I should just go back to using the Documents folder on C: and syncing it with OneDrive. Then I can use the SDXC drive just for overflow.
 
Moving the Documents folder or Window software to a removable drive is generally a last resort.
It is like moving the engine of your car to a trailer towed behind it in order to make more room for cargo.

:)
 
I'm getting humbled by this whole process. I think that what I want to do is go back to where I was before I installed the SDXC drive. I have kind of made a mess of my file structure at this point. Can I just create a new Documents folder under C:'\Users\KentSurface and then sync OneDrive to that? Since it appears that the Documents folder is a system folder, does it work to just create a new one? Do I need to do anything to ensure that OneDrive will sync with it?
 
Try to locate your Documents folder with the File Explorer. If it is not at C:\Users\KentSurface\Documents, then find where it is.
Then right-click on the folder name and choose Properties, Location, Move to place it back at C:\Users\Kentsurface\Documents .
 
Back
Top