[systemd-devel] Service not run, although enabled

Andrei Borzenkov arvidjaar at gmail.com
Tue Aug 8 08:36:23 UTC 2023


On Tue, Aug 8, 2023 at 11:31 AM Martin Stenzel
<m.stenzel at mail.xy-space.de> wrote:
...
> Your answer:
> These Wants and After are redundant, every standard service will be
> ordered after local-fs.target unless it also has
> DefaultDependencies=no.
>
> My answer/question:
> I want my service to be run DIRECTLY (at first place) AFTER the local filesystems (in /etc/fstab) were mounted.
>

You misunderstand what the After directive does. It does not do what you want.
...
> >
> > This is my service file.
> >
> > --
> > [Unit]
> > Description=Mount Bestcrypt containers
> > Wants=local-fs.target
> > After=local-fs.target
> >
>
> These Wants and After are redundant, every standard service will be
> ordered after local-fs.target unless it also has
> DefaultDependencies=no.
>


More information about the systemd-devel mailing list