Sync the same folder twice

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Sync the same folder twice Thu Jul 16, 2015 2:17 pm • by Bane
Sorry, I hope this is easy enough but I'm a bit stumped but the rule I'd like is:
"Watch folder X > "If any file/folder/subfolder here > Date last modified in last 1 hr / sync into these 2 folders"

I have an art folder that I keep my work in on my NAS, I'd like Hazel to simply watch it and if any changes have been made (last modified > 15 min) or 12 at night etc. I'd like it to sync (copy?) the changes to a folder in dropbox and gdrive. (Can't be too safe you know :lol: )

The problem is if I set the "DO" line to "Sync into folder xdropbox" and enter another one ""Sync into folder gdrive" it won't process the 2nd line to do the same to gdrive; only the top "do" line is processed no matter which is on top. Even reading the verbose logging (debug checked) just showed that the second "do" line was never initiated. I'm sure its that I'm missing something simple.

Also what is the difference between a sync and copy?
Copy has options for overwriting exiting files and keeping the folder structure, etc but sync looks like a 1 way copy without options for overwriting or which version to keep. (IE I'd like to replace the old with the new) when is each appropriate?

Sorry for the trouble, but thanks for the assistance!
Bane
 
Posts: 8
Joined: Thu Jul 16, 2015 1:56 pm

Re: Sync the same folder twice Fri Jul 17, 2015 10:55 am • by Mr_Noodle
Sync is meant for whole folder trees. It is more efficient in that it automatically only copies things that have changed and also has the advantage in that it can also sync file deletions (as long as you sync the folder that contains the file).

Can you post the rule? Also, how big are the folders in question? Does it take a long time to sync them?
Mr_Noodle
Site Admin
 
Posts: 11868
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Sync the same folder twice Fri Jul 17, 2015 6:17 pm • by Bane
Hello Mr_Noodle,
Thanks for the help!

A) Sync sounds like what I want to do (Folder tree and all)
B) Size is just over 500mb
C) It does NOT take a long time to sync them, about what would be expected to copy them. Once the sync's been done and I force the rule to run again its almost instant of course since nothing but maybe 1 file has changed due to my editing.

I got the Sync rule from you here on the forum and tried to edit/modify it, though I've tried simpler versions just to see if I could find the failure. If it helps, I watch the folder and don't have any problems with the "if" part, I can find and grab all the files, its the end part that doesn't function.

In the example below the dropbox folder works, gdrive folder does not update the file. If I reverse them, gdrive works, dbox does not update.
Thanks!

https://drive.google.com/file/d/0B91NaY ... sp=sharing

Image
Bane
 
Posts: 8
Joined: Thu Jul 16, 2015 1:56 pm

Re: Sync the same folder twice Mon Jul 20, 2015 11:03 am • by Mr_Noodle
Check the logs (click "View Log" in the Info section). See if you can find where it syncs and see what happens after that. Post or email the excerpt from there.
Mr_Noodle
Site Admin
 
Posts: 11868
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Sync the same folder twice Mon Jul 20, 2015 4:55 pm • by Bane
Ok, Sort of fixed it.

I think it was permission based. I copied the folder to the mac and then ran the rules there -> (put it on my NAS, Dropbox and GDrive) but if I tried to run the rule on the mapped Nas drive (I'm using Unraid/SMB if it matters) I was getting rsync errors after the first sync.

Just for clarification should I be using sync or copy? At most i'll be working on 1 or 2 files at a time and I don't want to delete anything so I'm assuming you will suggest a copy with an overwrite option?

Finally if you'd like me to continue giving you info (for the permissions or nas troubleshooting) please let me know. I know I've fixed my issue but if you think it will help someone else I can keep going.

Thanks!
Bane
 
Posts: 8
Joined: Thu Jul 16, 2015 1:56 pm

Re: Sync the same folder twice Tue Jul 21, 2015 11:09 am • by Mr_Noodle
If it's just a couple of files, I'd use the copy action. Not sure how common your problem is so if things are working for you then that's all that matters here.
Mr_Noodle
Site Admin
 
Posts: 11868
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support