[opensuse-factory] restarting apache takes a veryyy long time
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent": \_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch At some point this times out, and apache is started again. What is systemctl actually waiting for here? -- Per Jessen, Zürich (23.4°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Per Jessen wrote:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
I've just done a 2nd restart, which happened in the expected 1-2 seconds. -- Per Jessen, Zürich (23.3°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase
at startup..
--
Frederic Crozat
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty. It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt? -- Per Jessen, Zürich (25.1°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Le vendredi 06 septembre 2013 à 14:15 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty. It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Either in plymouth (graphical) or on the boot.
Try running systemctl to see if you get any prompt for passphrase, after
being logged.
--
Frederic Crozat
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 14:15 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty. It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Either in plymouth (graphical) or on the boot.
No plymouth here, it's a head-less server.
Try running systemctl to see if you get any prompt for passphrase, after being logged.
The funny thing is - after the first long wait, it now no longer waits when I do a restart. I presume that is because it defaulted to an empty passphrase when the first attempt timed out and this is now remembered? If so, can I clear it? thanks Per -- Per Jessen, Zürich (25.7°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Le vendredi 06 septembre 2013 à 14:48 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 14:15 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty. It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Either in plymouth (graphical) or on the boot.
No plymouth here, it's a head-less server.
Try running systemctl to see if you get any prompt for passphrase, after being logged.
The funny thing is - after the first long wait, it now no longer waits when I do a restart. I presume that is because it defaulted to an empty passphrase when the first attempt timed out and this is now remembered? If so, can I clear it?
No, it should have timed-out (and when there is some caching, it is done
at plymouth level).
Nothing has changed in that regarder on systemd side, so whoever
maintains apache should have a look at what changed.
--
Frederic Crozat
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 14:48 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 14:15 +0200, Per Jessen a écrit :
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty. It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Either in plymouth (graphical) or on the boot.
No plymouth here, it's a head-less server.
Try running systemctl to see if you get any prompt for passphrase, after being logged.
The funny thing is - after the first long wait, it now no longer waits when I do a restart. I presume that is because it defaulted to an empty passphrase when the first attempt timed out and this is now remembered? If so, can I clear it?
No, it should have timed-out (and when there is some caching, it is done at plymouth level).
Okay, interesting.
Nothing has changed in that regarder on systemd side, so whoever maintains apache should have a look at what changed.
Yup. -- Per Jessen, Zürich (26.4°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
On Friday 2013-09-06 14:15, Per Jessen wrote:
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty.
Note that an empty passphrase may not be the same as "unprotected" (openssl req -nodes).
It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Manually invoking httpd2 from the command line while it is not running should show it. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Jan Engelhardt wrote:
On Friday 2013-09-06 14:15, Per Jessen wrote:
Frederic Crozat wrote:
Le vendredi 06 septembre 2013 à 11:14 +0200, Per Jessen a écrit :
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
Looks like you have an SSL certificate which is prompting for passphrase at startup..
That's what I thought too, but I'm pretty certain the passphrase is empty.
Note that an empty passphrase may not be the same as "unprotected" (openssl req -nodes).
It was before I upgraded to apache 2.4. If it is a passphrase it is waiting for, how do I get to the prompt?
Manually invoking httpd2 from the command line while it is not running should show it.
Yep, thats what I thought too. I tried running like this: /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf -DSSL -DNO_DETACH -k start No prompt for a passphrase. Which appears to match the current behaviour when started with systemd (i.e. no prompt/delay). I'm not sure if I can reproduce the situation. -- Per Jessen, Zürich (20.4°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ? -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Cristian Rodríguez wrote:
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ?
I'm not sure - I only noticed yesterday, but I think I've seen it before. Sorry about being so vague, I'll have to try to reproduce. -- Per Jessen, Zürich (20.3°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Per Jessen wrote:
Cristian Rodríguez wrote:
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ?
I'm not sure - I only noticed yesterday, but I think I've seen it before. Sorry about being so vague, I'll have to try to reproduce.
Well, I've reproduced it, but accidentally. I restarted apache2 just now, and I'm back waiting here: \_ systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch After a while (maybe two minutes) it times out, and apache is then running. A second restart goes through without delay. Given that I don't know how to reproduce this on demand, what can I do to gather more information about what's happening? -- Per Jessen, Zürich (14.1°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
В Mon, 16 Sep 2013 09:26:05 +0200
Per Jessen
Per Jessen wrote:
Cristian Rodríguez wrote:
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ?
I'm not sure - I only noticed yesterday, but I think I've seen it before. Sorry about being so vague, I'll have to try to reproduce.
Well, I've reproduced it, but accidentally. I restarted apache2 just now, and I'm back waiting here:
\_ systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
systemctl always spawns systemd-tty-ask-password-agent (unless explicitly disabled using --no-ask-password) to handle possible password requests, so it is normal and does not necessary indicate apache wants password.
After a while (maybe two minutes) it times out, and apache is then running. A second restart goes through without delay. Given that I don't know how to reproduce this on demand, what can I do to gather more information about what's happening?
systemctl by default is executed synchronously - it waits until unit is started. There is timeout though; so systemctl timeouts waiting but systemd continues to execute startup. For systemd apache is started when apache2ctl has exited. You really need to look on apache side why startup takes so long. I do not see what can be done here from systemd side except show verbose apache output if it is enabled. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
Andrey Borzenkov wrote:
В Mon, 16 Sep 2013 09:26:05 +0200 Per Jessen
пишет: Per Jessen wrote:
Cristian Rodríguez wrote:
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ?
I'm not sure - I only noticed yesterday, but I think I've seen it before. Sorry about being so vague, I'll have to try to reproduce.
Well, I've reproduced it, but accidentally. I restarted apache2 just now, and I'm back waiting here:
\_ systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
systemctl always spawns systemd-tty-ask-password-agent (unless explicitly disabled using --no-ask-password) to handle possible password requests, so it is normal and does not necessary indicate apache wants password.
Okay, I wasn't aware of that. What is systemd-tty-ask-password-agent then waiting for in this case? There is clearly some difference between my first restart this morning and the later ones when these didn't wait. I too think this is an apache issue or perhaps an apache/systemd interaction issue. -- Per Jessen, Zürich (13.6°C) http://www.dns24.ch/ - free DNS hosting, made in Switzerland. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
В Mon, 16 Sep 2013 11:03:05 +0200
Per Jessen
Andrey Borzenkov wrote:
В Mon, 16 Sep 2013 09:26:05 +0200 Per Jessen
пишет: Per Jessen wrote:
Cristian Rodríguez wrote:
El 06/09/13 05:14, Per Jessen escribió:
I'm running apache 2.4 (although on 12.3), and restarting it take very long - systemctl restart apache2 appears to be hanging. I noticed that systemctl invokes "systemd-tty-ask-password-agent":
\_ /bin/systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
At some point this times out, and apache is started again. What is systemctl actually waiting for here?
OK, when this started to happen ? inmediately after you upgraded to 2.4 ? after an update ?
I'm not sure - I only noticed yesterday, but I think I've seen it before. Sorry about being so vague, I'll have to try to reproduce.
Well, I've reproduced it, but accidentally. I restarted apache2 just now, and I'm back waiting here:
\_ systemctl restart apache2 \_ /usr/bin/systemd-tty-ask-password-agent --watch
systemctl always spawns systemd-tty-ask-password-agent (unless explicitly disabled using --no-ask-password) to handle possible password requests, so it is normal and does not necessary indicate apache wants password.
Okay, I wasn't aware of that. What is systemd-tty-ask-password-agent then waiting for in this case?
it waits for password requests. Systemctl does not know whether started unit may request password so it starts it "just in case". It is terminated automatically by systemctl.
There is clearly some difference between my first restart this morning and the later ones when these didn't wait. I too think this is an apache issue or perhaps an apache/systemd interaction issue.
-- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
participants (5)
-
Andrey Borzenkov
-
Cristian Rodríguez
-
Frederic Crozat
-
Jan Engelhardt
-
Per Jessen