[systemd-devel] Why working this on reboot but not on start up

Andrei Borzenkov arvidjaar at gmail.com
Tue Sep 30 09:38:10 PDT 2014


В Tue, 30 Sep 2014 13:24:13 +0200
Günther J. Niederwimmer <gjn at gjn.priv.at> пишет:

> Hello,
> 
> I have a problem to run this correct, it is working on a reboot but not on 
> start up.
> 

What "does not work" means exactly?

> Can any help me for this Problem, Thanks.
> 

Without clear explanation what "working" and what "not working" is?
Unlikely.

> I make a new service File for the kerberos initialisation
> 
> this is my construct is any wrong in this files?
> 
> /etc/tmpfiles.d/kinit.conf
> d /run/user/0/krb5cc 1777 root root -
> 
> 
> /etc/systemd/system/kinit.service
> [Unit]
> Description=Kerberos initial kinit
> Wants=SuSEfirewall2_setup.service

Why Kerberos initialization *wants* firewall? I can understand After,
but I have hard time to understand Wants here.

> After=SuSEfirewall2_setup.service
> 
> [Service]
> Type=simple

Do you really mean it? I'd rather expect oneshot here.

> ExecStart=/usr/bin/kinit -k host/asmtp.gjn.prv
> Restart=on-failure
> RestartSec=30
> 
> [Install]
> WantedBy=multi-user.target
> 
> 
> /etc/systemd/system/kinit.timer
> [Unit]
> Description=Fist Initialisation of KRB5
> 
> [Timer]
> OnBootSec=3min
> 
> [Install]
> WantedBy=timers.target
> 

Why do you need to start it two times - once as normal service and
second time as timer?

> 
> Thanks for the help.
> 



More information about the systemd-devel mailing list