qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] -serial stdio broken
@ 2009-12-13  8:24 Blue Swirl
  2009-12-13  9:38 ` [Qemu-devel] " Blue Swirl
  2010-01-07 11:55 ` [Qemu-devel] " Richard W.M. Jones
  0 siblings, 2 replies; 15+ messages in thread
From: Blue Swirl @ 2009-12-13  8:24 UTC (permalink / raw)
  To: Gerd Hoffmann, qemu-devel

I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
targets:
qemu -serial stdio -monitor stdio
chardev: opening backend "stdio" failed
qemu: could not open serial device 'stdio': No such file or directory

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Qemu-devel] Re: -serial stdio broken
  2009-12-13  8:24 [Qemu-devel] -serial stdio broken Blue Swirl
@ 2009-12-13  9:38 ` Blue Swirl
  2009-12-14 10:55   ` Gerd Hoffmann
  2010-01-07 11:55 ` [Qemu-devel] " Richard W.M. Jones
  1 sibling, 1 reply; 15+ messages in thread
From: Blue Swirl @ 2009-12-13  9:38 UTC (permalink / raw)
  To: Gerd Hoffmann, qemu-devel

[-- Attachment #1: Type: text/plain, Size: 1857 bytes --]

On Sun, Dec 13, 2009 at 8:24 AM, Blue Swirl <blauwirbel@gmail.com> wrote:
> I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
> 998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
> targets:
> qemu -serial stdio -monitor stdio
> chardev: opening backend "stdio" failed
> qemu: could not open serial device 'stdio': No such file or directory
>

e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 is first bad commit
commit e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59
Author: Gerd Hoffmann <kraxel@redhat.com>
Date:   Tue Dec 8 13:11:44 2009 +0100

    zap serial_monitor_mux

    The logic in this code obviously predates the multiple monitor
    capability of qemu and looks increasingly silly these days.

    I think the intention of this piece of code is to get a reasonable
    default for the -nographic case: have monitor and serial line muxed
    on stdio.

    With the new default_serial and default_monitor variables we have now
    doing just that became much easier ;)

    Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>

:100644 100644 0d3f5e6687934a94e8586a13b2f5b7432065c430
e3e035f45349c8a2a86317dc46575c899acc8321 M      vl.c

git revert e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59
Auto-merged vl.c
CONFLICT (content): Merge conflict in vl.c
Automatic revert failed.  After resolving the conflicts,
mark the corrected paths with 'git add <paths>' or 'git rm <paths>'
and commit the result.

My attempt to merge (attached) does not compile:
/src/qemu/vl.c: In function 'serial_monitor_mux':
/src/qemu/vl.c:4795: error: 'DEV_MONITOR' undeclared (first use in
this function)
/src/qemu/vl.c:4795: error: (Each undeclared identifier is reported only once
/src/qemu/vl.c:4795: error: for each function it appears in.)

Please fix ASAP, this happens to break my test setup completely.

[-- Attachment #2: 0001-Revert-zap-serial_monitor_mux.patch --]
[-- Type: application/x-patch, Size: 2453 bytes --]

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Qemu-devel] Re: -serial stdio broken
  2009-12-13  9:38 ` [Qemu-devel] " Blue Swirl
@ 2009-12-14 10:55   ` Gerd Hoffmann
  2009-12-14 16:50     ` Blue Swirl
  0 siblings, 1 reply; 15+ messages in thread
From: Gerd Hoffmann @ 2009-12-14 10:55 UTC (permalink / raw)
  To: Blue Swirl; +Cc: qemu-devel

On 12/13/09 10:38, Blue Swirl wrote:
> On Sun, Dec 13, 2009 at 8:24 AM, Blue Swirl<blauwirbel@gmail.com>  wrote:
>> I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
>> 998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
>> targets:
>> qemu -serial stdio -monitor stdio

Oh.  It is actually used on the command line.  Hmm.

First, you can use '-serial mon:stdio' instead.

Second, with 'qemu -nographic' you don't need to specify this at all 
because that is the default.

What is gone now is the automagic conversion of '-serial stdio -monitor 
stdio' into '-serial mon:stdio' because I didn't expect people actually 
using that on the command line (see commit message).  Also this kind of 
post-processing is pretty horrible thing for the command line parser 
code.  Thus I would pretty much prefer to not re-introduce this ...

Can you live with one of the alternatives outlined above?

cheers,
   Gerd

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Qemu-devel] Re: -serial stdio broken
  2009-12-14 10:55   ` Gerd Hoffmann
@ 2009-12-14 16:50     ` Blue Swirl
  2009-12-14 17:12       ` Gerd Hoffmann
  0 siblings, 1 reply; 15+ messages in thread
From: Blue Swirl @ 2009-12-14 16:50 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel

On Mon, Dec 14, 2009 at 10:55 AM, Gerd Hoffmann <kraxel@redhat.com> wrote:
> On 12/13/09 10:38, Blue Swirl wrote:
>>
>> On Sun, Dec 13, 2009 at 8:24 AM, Blue Swirl<blauwirbel@gmail.com>  wrote:
>>>
>>> I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
>>> 998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
>>> targets:
>>> qemu -serial stdio -monitor stdio
>
> Oh.  It is actually used on the command line.  Hmm.
>
> First, you can use '-serial mon:stdio' instead.
>
> Second, with 'qemu -nographic' you don't need to specify this at all because
> that is the default.
>
> What is gone now is the automagic conversion of '-serial stdio -monitor
> stdio' into '-serial mon:stdio' because I didn't expect people actually
> using that on the command line (see commit message).  Also this kind of
> post-processing is pretty horrible thing for the command line parser code.
>  Thus I would pretty much prefer to not re-introduce this ...

It looks like vl.c was a poor place to do the mux choice. I just
wonder why mux option can't be automatically enabled for stdio in
qemu-char.c:qemu_chr_parse_compat() or somewhere nearby.

> Can you live with one of the alternatives outlined above?

I removed -monitor stdio from all my tests, now they work.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Qemu-devel] Re: -serial stdio broken
  2009-12-14 16:50     ` Blue Swirl
@ 2009-12-14 17:12       ` Gerd Hoffmann
  0 siblings, 0 replies; 15+ messages in thread
From: Gerd Hoffmann @ 2009-12-14 17:12 UTC (permalink / raw)
  To: Blue Swirl; +Cc: qemu-devel

> It looks like vl.c was a poor place to do the mux choice. I just
> wonder why mux option can't be automatically enabled for stdio in
> qemu-char.c:qemu_chr_parse_compat() or somewhere nearby.

The mux driver grabs the 'Ctrl-a' hotkey, so I wouldn't enable that 
unconditionally because the chardev isn't transparent any more with mux 
enabled.

It also wouldn't really help with command line parsing.

cheers,
   Gerd

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2009-12-13  8:24 [Qemu-devel] -serial stdio broken Blue Swirl
  2009-12-13  9:38 ` [Qemu-devel] " Blue Swirl
@ 2010-01-07 11:55 ` Richard W.M. Jones
  2010-01-07 12:10   ` Richard W.M. Jones
  2010-01-07 12:34   ` Anthony Liguori
  1 sibling, 2 replies; 15+ messages in thread
From: Richard W.M. Jones @ 2010-01-07 11:55 UTC (permalink / raw)
  To: Blue Swirl; +Cc: Gerd Hoffmann, qemu-devel

On Sun, Dec 13, 2009 at 08:24:54AM +0000, Blue Swirl wrote:
> I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
> 998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
> targets:
> qemu -serial stdio -monitor stdio
> chardev: opening backend "stdio" failed
> qemu: could not open serial device 'stdio': No such file or directory

-serial stdio on its own is broken for me (qemu from git).  The error
is a little bit different, so I don't think this is the same bug:

  chardev: opening backend "stdio" failed
  qemu: could not open serial device 'stdio': Invalid argument

The full command line is:

$qemudir/x86_64-softmmu/qemu-system-x86_64 \
    -L $qemudir/pc-bios \
    -drive file=/tmp/test.img,cache=off,if=ide \
    -m 500 \
    -no-reboot \
    -nographic \
    -serial stdio \
    -no-hpet \
    -net user,vlan=0,net=10.0.2.0/8 \
    -net nic,model=virtio,vlan=0 \
    -kernel /tmp/libguestfsUnRd8H/kernel \
    -initrd /tmp/libguestfsUnRd8H/initrd \
    -append 'panic=1 console=ttyS0 udevtimeout=300 noapic acpi=off printk.time=1 cgroup_disable=memory selinux=0 guestfs_vmchannel=tcp:10.0.2.2:36065 guestfs_verbose=1 '

I'll look into this a bit further now.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine.  Supports Linux and Windows.
http://et.redhat.com/~rjones/virt-df/

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 11:55 ` [Qemu-devel] " Richard W.M. Jones
@ 2010-01-07 12:10   ` Richard W.M. Jones
  2010-01-07 12:32     ` Gerd Hoffmann
  2010-01-07 12:35     ` Anthony Liguori
  2010-01-07 12:34   ` Anthony Liguori
  1 sibling, 2 replies; 15+ messages in thread
From: Richard W.M. Jones @ 2010-01-07 12:10 UTC (permalink / raw)
  To: Blue Swirl; +Cc: Gerd Hoffmann, qemu-devel

On Thu, Jan 07, 2010 at 11:55:05AM +0000, Richard W.M. Jones wrote:
>   chardev: opening backend "stdio" failed
>   qemu: could not open serial device 'stdio': Invalid argument

Or sometimes:

chardev: opening backend "stdio" failed
qemu: could not open serial device 'stdio': Success

(!)

So what seems to be happening here is there is an implicit monitor
being set up which grabs stdio.  Because:

  #define STDIO_MAX_CLIENTS 1

my own -serial stdio option subsequently fails.  This is a regression
over previous behaviour.  I didn't specify a monitor device, because I
don't want one, and previous versions of qemu didn't give me one in
nographic mode.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
New in Fedora 11: Fedora Windows cross-compiler. Compile Windows
programs, test, and build Windows installers. Over 70 libraries supprt'd
http://fedoraproject.org/wiki/MinGW http://www.annexia.org/fedora_mingw

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:10   ` Richard W.M. Jones
@ 2010-01-07 12:32     ` Gerd Hoffmann
  2010-01-07 13:25       ` Richard W.M. Jones
  2010-01-07 12:35     ` Anthony Liguori
  1 sibling, 1 reply; 15+ messages in thread
From: Gerd Hoffmann @ 2010-01-07 12:32 UTC (permalink / raw)
  To: Richard W.M. Jones; +Cc: Blue Swirl, qemu-devel

   Hi,

> So what seems to be happening here is there is an implicit monitor
> being set up which grabs stdio.  Because:
>
>    #define STDIO_MAX_CLIENTS 1
>
> my own -serial stdio option subsequently fails.  This is a regression
> over previous behaviour.  I didn't specify a monitor device, because I
> don't want one, and previous versions of qemu didn't give me one in
> nographic mode.

They gave you a monitor too.  Try typing 'Ctrl-A c' on stdio, and you'll 
see.  qemu tries to be more clever than you.  Which sucks IMHO.  But 
getting rid of that without adding regressions seems to be really hard ...

Easiest way to workaround this is to simply not specify '-serial stdio'. 
  It is the default anyway for -nographic, so you don't have to.

cheers,
   Gerd

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 11:55 ` [Qemu-devel] " Richard W.M. Jones
  2010-01-07 12:10   ` Richard W.M. Jones
@ 2010-01-07 12:34   ` Anthony Liguori
  2010-01-07 12:44     ` Daniel P. Berrange
  1 sibling, 1 reply; 15+ messages in thread
From: Anthony Liguori @ 2010-01-07 12:34 UTC (permalink / raw)
  To: Richard W.M. Jones; +Cc: Blue Swirl, Gerd Hoffmann, qemu-devel

On 01/07/2010 05:55 AM, Richard W.M. Jones wrote:
> On Sun, Dec 13, 2009 at 08:24:54AM +0000, Blue Swirl wrote:
>    
>> I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
>> 998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
>> targets:
>> qemu -serial stdio -monitor stdio
>> chardev: opening backend "stdio" failed
>> qemu: could not open serial device 'stdio': No such file or directory
>>      
> -serial stdio on its own is broken for me (qemu from git).  The error
> is a little bit different, so I don't think this is the same bug:
>
>    chardev: opening backend "stdio" failed
>    qemu: could not open serial device 'stdio': Invalid argument
>
> The full command line is:
>
> $qemudir/x86_64-softmmu/qemu-system-x86_64 \
>      -L $qemudir/pc-bios \
>      -drive file=/tmp/test.img,cache=off,if=ide \
>      -m 500 \
>      -no-reboot \
>      -nographic \
>      -serial stdio \
>    

This is redundant.  -nographic implies -serial stdio.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:10   ` Richard W.M. Jones
  2010-01-07 12:32     ` Gerd Hoffmann
@ 2010-01-07 12:35     ` Anthony Liguori
  1 sibling, 0 replies; 15+ messages in thread
From: Anthony Liguori @ 2010-01-07 12:35 UTC (permalink / raw)
  To: Richard W.M. Jones; +Cc: Blue Swirl, Gerd Hoffmann, qemu-devel

On 01/07/2010 06:10 AM, Richard W.M. Jones wrote:
> On Thu, Jan 07, 2010 at 11:55:05AM +0000, Richard W.M. Jones wrote:
>    
>>    chardev: opening backend "stdio" failed
>>    qemu: could not open serial device 'stdio': Invalid argument
>>      
> Or sometimes:
>
> chardev: opening backend "stdio" failed
> qemu: could not open serial device 'stdio': Success
>
> (!)
>
> So what seems to be happening here is there is an implicit monitor
> being set up which grabs stdio.  Because:
>
>    #define STDIO_MAX_CLIENTS 1
>
> my own -serial stdio option subsequently fails.  This is a regression
> over previous behaviour.  I didn't specify a monitor device, because I
> don't want one, and previous versions of qemu didn't give me one in
> nographic mode.
>    

Your old invocation was technically incorrect but it happened to work.  
It now throws an error.

It's a tough call about whether such things are regressions but in this 
case, I really don't think it is because the old behaviour wasn't 
self-consistent.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:34   ` Anthony Liguori
@ 2010-01-07 12:44     ` Daniel P. Berrange
  2010-01-07 13:23       ` Anthony Liguori
  2010-01-07 13:27       ` Richard W.M. Jones
  0 siblings, 2 replies; 15+ messages in thread
From: Daniel P. Berrange @ 2010-01-07 12:44 UTC (permalink / raw)
  To: Anthony Liguori; +Cc: Blue Swirl, qemu-devel, Richard W.M. Jones, Gerd Hoffmann

On Thu, Jan 07, 2010 at 06:34:13AM -0600, Anthony Liguori wrote:
> On 01/07/2010 05:55 AM, Richard W.M. Jones wrote:
> >On Sun, Dec 13, 2009 at 08:24:54AM +0000, Blue Swirl wrote:
> >   
> >>I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
> >>998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
> >>targets:
> >>qemu -serial stdio -monitor stdio
> >>chardev: opening backend "stdio" failed
> >>qemu: could not open serial device 'stdio': No such file or directory
> >>     
> >-serial stdio on its own is broken for me (qemu from git).  The error
> >is a little bit different, so I don't think this is the same bug:
> >
> >   chardev: opening backend "stdio" failed
> >   qemu: could not open serial device 'stdio': Invalid argument
> >
> >The full command line is:
> >
> >$qemudir/x86_64-softmmu/qemu-system-x86_64 \
> >     -L $qemudir/pc-bios \
> >     -drive file=/tmp/test.img,cache=off,if=ide \
> >     -m 500 \
> >     -no-reboot \
> >     -nographic \
> >     -serial stdio \
> >   
> 
> This is redundant.  -nographic implies -serial stdio.

NB, QEMU 0.12 introduces a new flag '-nodefaults' that can be used to
get rid of this imlied 'serial stdio', and all other implied devices.
It is well worth using this new -nodefaults flag if you're managing
qemu from an app to avoid these surprises

eg this should work as you'd expect it

  qemu -nodefaults -nographic -serial stdio

Regards,
Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:44     ` Daniel P. Berrange
@ 2010-01-07 13:23       ` Anthony Liguori
  2010-01-07 13:27       ` Richard W.M. Jones
  1 sibling, 0 replies; 15+ messages in thread
From: Anthony Liguori @ 2010-01-07 13:23 UTC (permalink / raw)
  To: Daniel P. Berrange
  Cc: Blue Swirl, qemu-devel, Richard W.M. Jones, Gerd Hoffmann

On 01/07/2010 06:44 AM, Daniel P. Berrange wrote:
> NB, QEMU 0.12 introduces a new flag '-nodefaults' that can be used to
> get rid of this imlied 'serial stdio', and all other implied devices.
> It is well worth using this new -nodefaults flag if you're managing
> qemu from an app to avoid these surprises
>
> eg this should work as you'd expect it
>
>    qemu -nodefaults -nographic -serial stdio
>    

-nographic is basically equivalent to -serial mon:stdio,signal=on -vga 
none except it operates on defaults.  Your invocation actually ends up 
being very different as it doesn't multiplex the monitor and it doesn't 
disable ctrl-c.  Basically, your invocation is equivalent to qemu -vga 
none -serial stdio

The "bug" is the original invocation's addition of '-serial stdio'.  
That was basically ignored previously but you could imagine subtle 
changes in semantics (like ctrl-c behavior) that it could and arguably 
should have introduced.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:32     ` Gerd Hoffmann
@ 2010-01-07 13:25       ` Richard W.M. Jones
  2010-01-07 16:01         ` Anthony Liguori
  0 siblings, 1 reply; 15+ messages in thread
From: Richard W.M. Jones @ 2010-01-07 13:25 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: Blue Swirl, qemu-devel

On Thu, Jan 07, 2010 at 01:32:09PM +0100, Gerd Hoffmann wrote:
>   Hi,
>
>> So what seems to be happening here is there is an implicit monitor
>> being set up which grabs stdio.  Because:
>>
>>    #define STDIO_MAX_CLIENTS 1
>>
>> my own -serial stdio option subsequently fails.  This is a regression
>> over previous behaviour.  I didn't specify a monitor device, because I
>> don't want one, and previous versions of qemu didn't give me one in
>> nographic mode.
>
> They gave you a monitor too.  Try typing 'Ctrl-A c' on stdio, and you'll  
> see.  qemu tries to be more clever than you.  Which sucks IMHO.  But  
> getting rid of that without adding regressions seems to be really hard 
> ...
>
> Easiest way to workaround this is to simply not specify '-serial stdio'.  
>  It is the default anyway for -nographic, so you don't have to.

I want to see the output of the serial port on stdio though.  I don't
care at all about the monitor.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
libguestfs lets you edit virtual machines.  Supports shell scripting,
bindings from many languages.  http://et.redhat.com/~rjones/libguestfs/
See what it can do: http://et.redhat.com/~rjones/libguestfs/recipes.html

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 12:44     ` Daniel P. Berrange
  2010-01-07 13:23       ` Anthony Liguori
@ 2010-01-07 13:27       ` Richard W.M. Jones
  1 sibling, 0 replies; 15+ messages in thread
From: Richard W.M. Jones @ 2010-01-07 13:27 UTC (permalink / raw)
  To: Daniel P. Berrange; +Cc: Blue Swirl, Gerd Hoffmann, qemu-devel

On Thu, Jan 07, 2010 at 12:44:17PM +0000, Daniel P. Berrange wrote:
> On Thu, Jan 07, 2010 at 06:34:13AM -0600, Anthony Liguori wrote:
> > On 01/07/2010 05:55 AM, Richard W.M. Jones wrote:
> > >On Sun, Dec 13, 2009 at 08:24:54AM +0000, Blue Swirl wrote:
> > >   
> > >>I guess e1c09175bc00dd8dfb2ad1b26e1858dcdc109b59 or
> > >>998bbd74b9d813b14a3a3b5009a5d5a48c7dce51 broke -serial stdio for all
> > >>targets:
> > >>qemu -serial stdio -monitor stdio
> > >>chardev: opening backend "stdio" failed
> > >>qemu: could not open serial device 'stdio': No such file or directory
> > >>     
> > >-serial stdio on its own is broken for me (qemu from git).  The error
> > >is a little bit different, so I don't think this is the same bug:
> > >
> > >   chardev: opening backend "stdio" failed
> > >   qemu: could not open serial device 'stdio': Invalid argument
> > >
> > >The full command line is:
> > >
> > >$qemudir/x86_64-softmmu/qemu-system-x86_64 \
> > >     -L $qemudir/pc-bios \
> > >     -drive file=/tmp/test.img,cache=off,if=ide \
> > >     -m 500 \
> > >     -no-reboot \
> > >     -nographic \
> > >     -serial stdio \
> > >   
> > 
> > This is redundant.  -nographic implies -serial stdio.
> 
> NB, QEMU 0.12 introduces a new flag '-nodefaults' that can be used to
> get rid of this imlied 'serial stdio', and all other implied devices.
> It is well worth using this new -nodefaults flag if you're managing
> qemu from an app to avoid these surprises
> 
> eg this should work as you'd expect it
> 
>   qemu -nodefaults -nographic -serial stdio

I think this is probably the way to go then.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Qemu-devel] -serial stdio broken
  2010-01-07 13:25       ` Richard W.M. Jones
@ 2010-01-07 16:01         ` Anthony Liguori
  0 siblings, 0 replies; 15+ messages in thread
From: Anthony Liguori @ 2010-01-07 16:01 UTC (permalink / raw)
  To: Richard W.M. Jones; +Cc: Blue Swirl, Gerd Hoffmann, qemu-devel

On 01/07/2010 07:25 AM, Richard W.M. Jones wrote:
> On Thu, Jan 07, 2010 at 01:32:09PM +0100, Gerd Hoffmann wrote:
>    
>>    Hi,
>>
>>      
>>> So what seems to be happening here is there is an implicit monitor
>>> being set up which grabs stdio.  Because:
>>>
>>>     #define STDIO_MAX_CLIENTS 1
>>>
>>> my own -serial stdio option subsequently fails.  This is a regression
>>> over previous behaviour.  I didn't specify a monitor device, because I
>>> don't want one, and previous versions of qemu didn't give me one in
>>> nographic mode.
>>>        
>> They gave you a monitor too.  Try typing 'Ctrl-A c' on stdio, and you'll
>> see.  qemu tries to be more clever than you.  Which sucks IMHO.  But
>> getting rid of that without adding regressions seems to be really hard
>> ...
>>
>> Easiest way to workaround this is to simply not specify '-serial stdio'.
>>   It is the default anyway for -nographic, so you don't have to.
>>      
> I want to see the output of the serial port on stdio though.  I don't
> care at all about the monitor.
>    

-nographic gives you that.

nographic is a terrible name.  It really is, use this mode if you want 
to run something and only interact with it through the serial console.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2010-01-07 16:01 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-13  8:24 [Qemu-devel] -serial stdio broken Blue Swirl
2009-12-13  9:38 ` [Qemu-devel] " Blue Swirl
2009-12-14 10:55   ` Gerd Hoffmann
2009-12-14 16:50     ` Blue Swirl
2009-12-14 17:12       ` Gerd Hoffmann
2010-01-07 11:55 ` [Qemu-devel] " Richard W.M. Jones
2010-01-07 12:10   ` Richard W.M. Jones
2010-01-07 12:32     ` Gerd Hoffmann
2010-01-07 13:25       ` Richard W.M. Jones
2010-01-07 16:01         ` Anthony Liguori
2010-01-07 12:35     ` Anthony Liguori
2010-01-07 12:34   ` Anthony Liguori
2010-01-07 12:44     ` Daniel P. Berrange
2010-01-07 13:23       ` Anthony Liguori
2010-01-07 13:27       ` Richard W.M. Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).