linux-um archives
 help / color / mirror / Atom feed
From: Paolo Giarrusso <p.giarrusso@gmail.com>
To: user-mode-linux-devel@lists.sourceforge.net
Cc: "David Fernández" <david@dit.upm.es>
Subject: Re: [uml-devel] (Workarounded) Hanging using 'iptables -L' in UML vm booted with con0=pts
Date: Tue, 18 Sep 2007 17:06:18 +0200	[thread overview]
Message-ID: <200709181706.22905.p.giarrusso@gmail.com> (raw)
In-Reply-To: <46E9A824.3010808@cttc.es>


[-- Attachment #1.1: Type: text/plain, Size: 3480 bytes --]

On giovedì 13 settembre 2007, Fermín Galán Márquez wrote:
> Hi,
>
> After some more debugging I think I've solved the problem (at least :)
> An explanation follows.
>
> First, although apparently it seemed that the modules causing the
> problem were the ones related with networking (as David Fernández said
> in his mail) that assumption was wrong. In fact, the modules causing the
> problem are the ones that print some message in the "kernel message
> buffer" (I don't know what is the right name, but I'm referring to the
> message log that appears when the dmesg command is used) when modprobe
> load them. For example, ip_tables prints something like "ip_tables: (C)
> 2000-2006 Netfilter Core Team".

> The solution to the problem is using con1 instead of con0, I mean:
>
> ./linux ubd0=/tmp/root_fs_debug con=null con1=pts uml_dir=/tmp umid=run
>
> instead of
>
> ./linux ubd0=/tmp/root_fs_debug con=null con1=pts uml_dir=/tmp umid=run

This was con0=pts, I checked your other mail. Right?

> In that case you can 'iptables -L' works without problems.

> Why? When the module is loaded it prints its message not only in the
> internal kernel message buffer but also in con0 (this can be checked
> running simply "./linux ubd0=/tmp/root_fs_debug", without con=
> redirectors). When con0 is redirected to null (con0=null) there is no
> problem, but if con0 is redirected to a pts (con0=pts) I guess that, in
> the moment of printing the message, some problem occurs with the output
> (as Jeff suggest in its mail) thus causing the vm hang.

> This explains also why putting the module in /etc/modules works. The
> loading of the list of modules in /etc/modules is performed before UML
> assign virtual console to pts devices (the sequence can be checked
> observing the booting log).

> I think that my solution is more a workaround that a definitive
> solution. Why when con0 is assigned to a pts modules can not (because of
> it hangs the vm) print its message but when it is assigned to null it
> works? Is there a bug in the UML kernel that need to be fixed? Or maybe
> the bug is in modprobe? I leave the question open for the experts in the
> UML internals... :)
The problem does not lie in modprobe nor iptables - it is the behaviour of the 
system console wrt. the pts driver.

The only really strange thing is the 100% cpu usage - like if the operation 
were retried in a loop. And, well, there is a loop there - CATCH_EINTR (which 
I added)!

Now, what's unexpected is getting EINTR on that operation. That's really 
strange. However, I'll leave debugging to Jeff. If he cannot reproduce the 
problem he'll ask you more, I guess.

> Regarding the tests suggested by Paolo:
> > Please try logging in via SSH and reproducing the problem and the
> > stacktrace, and also removing con=null - also have you double checked
> > con=null is ok (maybe it was con=none, I'm not sure). I'm not sure screen
> > is perfectly safe to use (it should be).
>
> Do you really need that I perform these test or considers the report
> above is enough? If it's really needed I can do them, but it would take
> me some time (and maybe now it isn't a good idea because of they won't
> provide additional useful information :)

No, I just needed a proof that the problem was indeed with the output on a 
pts.

Thank you for you help
-- 
"Doh!" (cit.), I've made another mistake!
Paolo Giarrusso, aka Blaisorblade

[-- Attachment #1.2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

[-- Attachment #2: Type: text/plain, Size: 228 bytes --]

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

[-- Attachment #3: Type: text/plain, Size: 194 bytes --]

_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

  reply	other threads:[~2007-09-18 15:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <46DDAD83.4030004@cttc.es>
     [not found] ` <20070904214521.GB5417@c2.user-mode-linux.org>
     [not found]   ` <296838.33596.qm@web52009.mail.re2.yahoo.com>
2007-09-10 15:59     ` [uml-devel] [uml-user] Hanging using 'iptables -L' in UML vm booted with con0=pts Jeff Dike
2007-09-11 14:06       ` Blaisorblade
     [not found]   ` <46DE8F70.4070404@cttc.es>
     [not found]     ` <20070910160238.GC14112@c2.user-mode-linux.org>
     [not found]       ` <46E71F58.6050301@cttc.es>
     [not found]         ` <46E85FA0.9040405@cttc.es>
2007-09-12 20:30           ` Jeff Dike
2007-09-13  0:59             ` Fermín Galán Márquez
2007-09-13 17:08               ` Blaisorblade
2007-09-13 21:14                 ` [uml-devel] (Solved) " Fermín Galán Márquez
2007-09-18 15:06                   ` Paolo Giarrusso [this message]
2007-09-19 19:42                     ` [uml-devel] (Workarounded) " Fermín Galán Márquez
2007-10-10 14:21                       ` David Fernández

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=200709181706.22905.p.giarrusso@gmail.com \
    --to=p.giarrusso@gmail.com \
    --cc=david@dit.upm.es \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox