Seite 1 von 1

opsi-product-updater syntax

Verfasst: 17 Mai 2013, 23:14
von djm79
I'm going to run the product updater as a cron job to keep my depots up to date with the main config server, my question is what is the correct syntax for the cronjob?

Would it be 30 13 0 0 1 opsi-product-updater -i to have it run on Sat at 1:30 pm?

Re: opsi-product-updater syntax

Verfasst: 18 Mai 2013, 10:04
von tobias
Hi,

the 1 is Monday ;)
7 and 0 is Sunday
6 is Saturday
5 is Friday ....

Minute,Hour,day,month,weekday

Re: opsi-product-updater syntax

Verfasst: 28 Mai 2013, 16:12
von djm79
After some digging around I found where I was going wrong with my crontab job. So I'll post this for other in case they need to schedule an opsi job. To find the location and path to input into you crontask run this command whereis "opsi command you want to run" and it will output the path to the command script and this will need to be entered after you select the time you want it to run. Example:

30 13 * * 6 /usr/bin/opsi-package-manager -i

This should run the opsi package manager to pull all the packages from the repository to the depot server. It will run at 1:30 pm on Sat every week.

Re: opsi-product-updater syntax

Verfasst: 29 Mai 2013, 15:07
von djm79
Is there a way to stop the opsi-product-updater at a current time, so I want to start my sync on Sat and want to make sure that Monday morning it stops at 7:30 as the remote locations only have T1 connections to them and they can't operate with the sync running at the same time.

Thanks to the Opsi team this has been one of the best Open Source software journeys I have been on. :D

Re: opsi-product-updater syntax

Verfasst: 11 Jun 2013, 12:16
von bmsoft
Well, you can put a job into crontab that kills the product updater and the desired time. I would log and modify the times instead of killing the task. hth, lorenzo