Am Mon, Dec 13, 2021 at 04:54:30PM -0500 schrieb Rich Freeman: > On Mon, Dec 13, 2021 at 4:42 PM Michael Orlitzky <m...@gentoo.org> wrote: > > > > On Mon, 2021-12-13 at 22:38 +0100, Frank Steinmetzger wrote: > > > > > > Well I *could* disable run-crons altogether and add entries to fcron’s own > > > crontab which would run those scripts in /etc/cron.{hourly,daily,...} > > > instead. > > > > > > However, I like predictable times at which those jobs will run. Especially > > > if one of them is a zfs scrub; the NAS is powered down for weeks, > > > sometimes > > > months. And when I power it up, it’s for a reason. And that reason usually > > > is not a scrub, which—at the current zfs fill level—takes 10½ hours. > > > > > > > Why choose fcron then? It sounds like you have the same rationale as I > > do: "no, I don't want to run the 4am backup job in the middle of the > > business day just because it wasn't run at 4am."
Fair point. Fcron has a serialisation feature, so that for instance updatedb and mandb don’t run at the same time. Me kinda liky. > fcron is perfectly capable of running jobs at either set times or at > loosely-defined intervals that are compensated for if the machine is > off. Indeed, I can say "@monthly * 0 *" to run a monthly job (like the scrub) only at night. *pondering* > Systemd timers can also be set that way, and can also have > limits put on scheduling (daily nominally at 3AM but allowed between > 11PM and 5AM or whatever). Obviously the more expressive the crontab > equivalent is, the more you can tweak it to do what you want it to. I’ve gotten used to systemd on my Arch-based desktops. But the NAS is still on good-ol’ openrc. :) > I'll also note that zfs scrubs checkpoint at shutdown and will > auto-resume where you leave off. That’s a nice bit of knowledge. > If they are involved multiple times > with the default options I think any attempt to scrub something that > is already being scrubbed is just a no-op. Obviously if you don't > want all that IO during the day you'll have to do something more > clever - you can instruct it to pause and resume so you could have a > couple of crontab entries and scripts to do just that. Or, since I am the only user of that system, I could go back to my previous way: just run the scrub manually every other month or so before I go to bed. Because then I know that nothing will interfere with it and it won’t interfere with anything else. -- Grüße | Greetings | Qapla’ Please do not share anything from, with or about me on any social network. This message was written using only recycled electrons.
signature.asc
Description: PGP signature