Re: cron @shutdown
- In reply to: Jan Bramkamp : "Re: cron @shutdown"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 15 Aug 2022 18:07:21 UTC
In message <6c1ce943-bcd8-3a34-f59c-1b60d05f23fa@rlwinm.de>, Jan Bramkamp write s: > On 02.08.22 16:54, Cy Schubert wrote: > > Hi, > > > > Does anyone think there might be some utility with an @shutdown crontab(5) > > "nickname" similar to @reboot but instead when cron shuts down? > > > > I pointed out to one of my customers that @reboot might be an option > > instead of an rc script (or in his case a systemd unit file). Not that an > > @reboot for FreeBSD cron would contribute to solving his Linux problem but > > might our users be interested in something like this? > How would this interact with signaling and restarting the cron daemon? > Are there status files or something similar allowing cron to tell a > `pkill cron` from a `service cron restart` from a real `shutdown -p now`? > Typically cron is rarely restarted. However, at $JOB it is expected that scripts that are called in this manner should use some kind of lock file to avoid starting another instance of the applicaion. -- Cheers, Cy Schubert <Cy.Schubert@cschubert.com> FreeBSD UNIX: <cy@FreeBSD.org> Web: http://www.FreeBSD.org NTP: <cy@nwtime.org> Web: https://nwtime.org e**(i*pi)+1=0