WebDav mapped drive and Robocopy


#1

I'm running a batch file that uses robocopy to mirror a folder with files and sub folders. This works when using a USB or NAS but when using a WebDav mapped drive to OwnCloud I get robocopy errors. Specifically I get "ERROR 2 (0x00000002) Creating Destination Directory". It seems as though robocopy is unable to create folders. Has anyone else seen this issue?


#2

Can you create manually a small folder and files and see if it can't create folders at all? Might be interesting to check the owncloud and webserver logfiles at the moment when Robocopy runs into this error. Which way are you syncing from owncloud or to owncloud (idea: some file and folder names are not allowed in Windows)?

To exclude owncloud, you could perhaps try a different webdav server or a different owncloud setup (different version). There is also an external tool that allows you to test a webdav storage:


#3

I have done more testing and tried the same thing with Microsoft OneDrive to see what would happen and found the same issue so this must be an issue with Robocopy creating folders or files through a WebDav mapped drive. I sure wish I could get this figured out. If Robocopy would work with a WebDav mapped drive just like it does with any other drive I'd just about have the perfect combination for a scheduled off site backup. I don't want to use the OwnCloud client because I can not schedule the sync and send an email confirmation. I can do all that with Robocopy and Blat.exe. I would sure appreciate any help anyone has.


#4

I can create folders and files using a command line so WebDav works somewhat with command line. Ugh...


#5

Have a look at unison: http://www.cis.upenn.edu/~bcpierce/unison/docs.html
I'm not sure how good you can run this from command line on Windows.


#6

Just curious, but is there a reason you're stuck using Windows OS on this server? Or just a personal preference? Anything relating to scripting and automation is infinitely more flexible and easy on a Linux server OS. I can't think of any use cases where running ownCloud on a Windows OS has any advantage.