[systemd-devel] [RFC] Preset Files
Bill Nottingham
notting at redhat.com
Wed Jul 6 07:31:26 PDT 2011
Michal Schmidt (mschmidt at redhat.com) said:
> On Wed, 6 Jul 2011 00:42:25 +0200 Lennart Poettering wrote:
> > Actually, I do want a way how people can reset all service enable
> > states to what the vendor intended. And that should be "systemctl
> > preset" without arguments I believe.
>
> That would be too easy to run accidentally.
>
> They can run:
> cd /lib/systemd/system && systemctl preset *.service
> or require an extra parameter, e.g.:
> systemctl preset --all
I agree here - having some extra argument (--all, --force) to do the
global reset seems like a safe default to avoid accidents.
Some comments in general:
- Doing globbing matching in the config file may have unintended
consequences depending on how services are named, if they share a
common prefix. However, I suspect most globs would only be '*',
'*', so probably not an issue in practice.
- If we go down the road of having spin-specific preset files, this
will lead to conflicts for the people that install multiple desktops;
there needs to be some way to adjudicate these, or design the installation
process so that someone who wants both KDE and GNOME doesn't have their
installation stuck. Maybe have a simple way to package non-conflicting
presets, and then 'apply' them.
- (bikeshed) 'preset' vs 'reset' (or 'apply-preset') as the command
- There's a bit of overlap with the snapshot code, as someone may want
to snapshot the system's current state as their preset.
Bill
More information about the systemd-devel
mailing list