From: "Bolle" <bolle@geodb.org>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [REASON][PATCH-REQUEST] Starting QEMU by PHP/Apache
Date: Fri, 16 Oct 2009 06:49:13 +0200 [thread overview]
Message-ID: <web-1433162@x41.ch> (raw)
In-Reply-To: <web-1432056@x41.ch>
After some research, I think that Apache with mod_php is
blocking the SIGALRM.
This is not the fault of QEMU. But maybe, QEMU could check
on the start-up, if SIGALRM is enabled and usable. If not,
then it can bail out and inform the user about this.
I believe, there are other environments where SIGALRM is
blocked too.
Andreas
PS: Sorry for not being able to provide a patch by my
self.
On Wed, 14 Oct 2009 07:12:56 +0200
"Bolle" <bolle@geodb.org> wrote:
> Hello all
>
>First, I forgot to say, that I use the QEMU stable
>version 11.0 on a Gentoo box. I did some more testings.
>The QEMU instance is starting and sometimes the OS starts
>to load, but then QEMU stucks and consumes 100% CPU.
>
> I checked the startup it with strace. The start of QEMU
>itself produces the same output in strace, regardless if
>started by the PHP CLI or by mod_php from Apache.
>
> I then attached strace to the QEMU process, and there is
>a big difference.
>
> When starting QEMU with the PHP script from the CLI (as
>the same user as the web server), it works and I get
>something like that:
> ...
> select(12, [6 11], [], [], {4, 993369}) = ?
>ERESTARTNOHAND (To be restarted)
> --- SIGALRM (Alarm clock) @ 0 (0) ---
> write(7, "\0"..., 1) = 1
> sigreturn() = ? (mask now
>[])
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146485529}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146548886}) = 0
> timer_gettime(0, {it_interval={0, 0}, it_value={0, 0}})
>= 0
> timer_settime(0, 0, {it_interval={0, 0}, it_value={0,
>250000}}, NULL) = 0
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146758750}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146819115}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146879549}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2818001, 146938839}) = 0
> --- SIGALRM (Alarm clock) @ 0 (0) ---
> write(7, "\0"..., 1) = 1
> sigreturn() = ? (mask now
>[])
> ...
>
> If QEMU has been started by the web server with the same
>script and user, I get:
> ...
> select(11, [5 10], [], [], {3, 767239}) = 0 (Timeout)
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818297714}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818382772}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818444894}) = 0
> timer_gettime(0, {it_interval={0, 0}, it_value={0, 0}})
>= 0
> timer_settime(0, 0, {it_interval={0, 0}, it_value={0,
>250000}}, NULL) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818698197}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818759263}) = 0
> timer_gettime(0, {it_interval={0, 0}, it_value={0,
>67453}}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818894002}) = 0
> clock_gettime(CLOCK_MONOTONIC, {2817617, 818954673}) = 0
> timer_gettime(0, {it_interval={0, 0}, it_value={0, 0}})
>= 0
> timer_settime(0, 0, {it_interval={0, 0}, it_value={0,
>250000}}, NULL) = 0
> ...
>
> There are no SIGALRM executed. What can be the reason
>for that ?
>
> Andreas
next prev parent reply other threads:[~2009-10-16 4:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-13 11:26 [Qemu-devel] Starting QEMU by PHP/Apache Bolle
2009-10-13 13:12 ` François Revol
2009-10-14 5:12 ` [Qemu-devel] " Bolle
2009-10-16 4:49 ` Bolle [this message]
2009-10-20 10:10 ` [Qemu-devel] " Richard W.M. Jones
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=web-1433162@x41.ch \
--to=bolle@geodb.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.