Rsync manually

    • OMV 4.x

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Rsync manually

      Really dumb question, but if I want to setup an rsync job but only execute it manually, do I simply not enable any of the time options in the setup? Or would it be easier to just do it manually when I want to via CLI?

      My problem is I don't quite understand the time option terminology so i'm not sure how to set a job to not run on a schedule and only be executed manually.

      Thanks....
    • The timing on them, is a little odd, IMO.. but it works once you get the hang of it. I'm by no means an expert, but this has been my general experience. What really got me, was the minutes setting... but once I got the hang of it, it was easy.

      Example below 1:
      imgur.com/MWvsFWk

      This one will run every day, at 0800. It will run one time at the top of the hour (thus the 0 in the minutes section). If you leave that set to *, it will run over and over for the full 0800 hour, until it hits 0900. If you set it to say, 10.. it will run over and over until 0810. This is probably whats frustrating you, as it did me...lol. This one is unaffected by shutdowns, power failures, etc. If the NAS is on at 0800, it will run. If it's not, it will wait until the next time it is on at 0800, and then run.

      Example 2:
      imgur.com/mcVv5fi

      This one will run every 8 hours (notice the "N Hour" trigger is enabled), one time at the top of the hour. The same rule as above applies, if you leave it set to *, its going to run over and over for the full 8th hour. Set it to 10, and it's going to run over and over for 10min, of the 8th hour. I should note this is server up time. So if you shut down your server, power failure, etc.. when you boot back up, the 8 hours starts over (or as best I can tell it is)

      Example 3:
      imgur.com/JH8QSNx

      This one, will run every 21 days, and on the 21st day, it will run every 8 hours, at 0 minutes. Same rule applies to shutting down, power failures, etc.

      Example 4:
      imgur.com/a/keZo1tE

      This one, will run the 21st of every month (notice the N Month trigger again) at 0800... If you want it to run every 8hrs, on the 21st day of the month, then you would set the N Hour trigger.

      Hope that helps.
      Air Conditioners are a lot like PC's... They work great until you open Windows.

      The post was edited 1 time, last by KM0201 ().

    • Thanks for all of that. I sort of get it now. Since I shutdown the server every night, I can just set it to run at one of the overnight hours. That way it will never be on at that time and the job will never start automatically. Then I can just run it manually at some point during the day when the server is on. Kind of awkward, but it will work until they add some kind of no scheduled time option.

      Thanks again...
    • flyinjoe13 wrote:

      Thanks for all of that. I sort of get it now. Since I shutdown the server every night, I can just set it to run at one of the overnight hours. That way it will never be on at that time and the job will never start automatically. Then I can just run it manually at some point during the day when the server is on. Kind of awkward, but it will work until they add some kind of no scheduled time option.

      Thanks again...
      If you're gonna do that, just disable the job, and run it manually whenever you feel like it.

      The scheduling is a little weird, and it took a minute for me to figure out, but once I got the hang of it, it's really no problem. I work overnights, typically I get home around 0630, I turn the NAS on and watch something till I fall asleep. So I just set my job to run at 00900.. as I'm usually out about that time. I wake up around 1400, mess around on the PC, NAS, etc. for an hour or so and then shutdown and get ready for work.

      The biggest issue I had, was trying to figure out why the job would start at 8am, and would run over and over for a full hour, before it stopped. Once I got that figured out, it was easy.

      The easiest way to test it (and how I finally felt I had a grasp on the scheduling).. I done this all locally as between two folders I created to keep it isolated from the rest of NAS...

      So "Dummy_Source" will backup to "Dummy_Backup".. Create a few text files or other directories, etc. inside the Dummy_Source folder. Then set the job to start at the top of the following hour (hour, and minute set to 0)... Clear the rsync log, so you only see what the new configuration does. Once it's done, you should see it sync the dummy files and folders you made on the Dummy_Backup location.

      Now go back, and delete the files/folders under Dummy_Source, and enable the delete trigger for the rsync job. Set it to run the following hour, but on the minute side.. change that to say, 5. Then clear the log. About 15 after the hour, check the log, and you'll see where it ran over and over for 5min, and in the process, deleted the files in Dummy_Backup

      Repeat using the N hour if you like... Set the Hour to say 1, and set the "N Hour" option, and make sure you change the minutes to 0.. then create a few files under Dummy_Source... and clear the log. Check the log about 5min after the hour, and you'll see it sync the files. Wait another hour, check the log, and you'll see the job ran again, but not make any changes (assuming you didn't make any changes to Dummy_Source).

      Once someone here explained it, and kinda like you it "sort of made sense"... so I did it that way so I could actually see it in action, then it made a lot more sense
      Air Conditioners are a lot like PC's... They work great until you open Windows.