[systemd-devel] Cannot start service due to 'systemd-tty-ask-password-agent --watch' not answering

Yeela Kaplan ykaplan at redhat.com
Tue Sep 8 04:56:11 PDT 2015



----- Original Message -----
> From: "Lennart Poettering" <lennart at poettering.net>
> To: "Yeela Kaplan" <ykaplan at redhat.com>
> Cc: systemd-devel at lists.freedesktop.org, "Oved Ourfali" <ovedo at redhat.com>, "Dan Kenigsberg" <danken at redhat.com>
> Sent: Tuesday, September 8, 2015 1:45:54 PM
> Subject: Re: [systemd-devel] Cannot start service due to 'systemd-tty-ask-password-agent --watch' not answering
> 
> On Tue, 08.09.15 05:51, Yeela Kaplan (ykaplan at redhat.com) wrote:
> 
> > > This is really a misconception about what
> > > systemd-tty-ask-password-agent actually does. It's job is to bring
> > > password queries from system components to the screen while you wait
> > > for systemctl to finish. This is useful for things like LUKS hdd
> > > encryption where the system might have to query the user for a
> > > passphrase to proceed starting units. Other cases where this is used
> > > is for passphrases of SSL certificates.
> > > 
> > > Unless you actually use LUKS or SSL certificates with a passphrase
> > > (with a web server that supports querying passwords via systemd's
> > > password querying mechanism), the agent does pretty much nothing.
> > > 
> > > The agent is forked off, waits for passwords to be queried, queries
> > > them when there are any, and then exits when systemctl finishes.
> > > 
> > > You can pass --no-ask-password to systemctl to turn off the agent. See
> > > the man page for details.
> > > 
> > 
> > Thank you for your response.
> > I have tried running:  strace -f systemctl --no-ask-password start
> > supervdsmd.service
> > and it still reproduces.
> > but now intead of:
> > bash(3448)─┬─pstree(3625)
> >            └─strace(3618)───systemctl(3623)───systemd-tty-ask(3624)
> > 
> > I get:
> > bash(3448)─┬─pstree(3586)
> >            └─strace(3564)───systemctl(3569)
> > 
> > Do you know what systemctl is waiting for then?
> 
> Most likely that supervdsmd.service finishes start-up. Maybe there's a
> bug in the unit file regarding notification when it finished start-up?
> 
> (You can also tell systemctl to just enqueue a start job, but not wait
> for it to complete. Use --no-block for that).

This is the unit file:
[Unit]
Description="Auxiliary vdsm service for running helper functions as root"
Requires=libvirtd.service

[Service]
Type=simple
LimitCORE=infinity
EnvironmentFile=-/etc/sysconfig/supervdsmd
ExecStart=/usr/share/vdsm/daemonAdapter "/usr/share/vdsm/supervdsmServer" --sockfile "/var/run/vdsm/svdsm.sock"
Restart=always


The service works fine on other machines... this is the first time we see it..
and the service is able to start without systemd.. by just running: /usr/share/vdsm/daemonAdapter "/usr/share/vdsm/supervdsmServer" --sockfile "/var/run/vdsm/svdsm.sock" 
but hangs for a long time without starting even when using --no-block..

> 
> Lennart
> 
> --
> Lennart Poettering, Red Hat
> 


More information about the systemd-devel mailing list