On Thursday 03 March 2005 01:43 pm, Jeff Dike wrote:
> [EMAIL PROTECTED] said:
> > Well, just in case your job was too easy, here's one more.  Using the
> > "quiet" option shows a couple of lines being printed out by printf
> > that should be printed out by printk (so they'll _shut_up_ when you
> > ask it to).
>
> Those are printfs for a reason.  Early boot mesages (before the kernel is
> actually running) won't be seen if they are printk-d and the thing crashes
> before the console is initialized.  The messages will be stuck in the
> printk buffer, and you will be none the wiser.
>
> So, they can be made quiet if you really want, but that's not the way.

I suspected there was a reason, nice to know what it is.  It would be nice if 
they could be made quiet, because I'm in the process of doing a gross hack to 
run an independent process wrapped in UML.

Basically, my nefarious scheme is to add the squashfs patch to UML, append a 
squashfs image to the end of the  UML executable, and have a cpio ramfs init 
script search through /proc/self/exe for the 32 bytes that were at the start 
of the squashfs (which includes a 4 byte magic signature thingy) to determine 
offset to pass to "losetup -o $OFFSET /dev/loop0 /proc/self/exe", and then 
mount /dev/loop0 / and run the executable I want out of that filesystem.

And there's a cheap and dirty way to get a self contained program running 
under UML.  (I hope to actually have an example working this evening using 
2.6.11.)

The down side is that UML (even with the quiet option) just won't shut up 
about its init stuff.  Hence me looking into cleaning that up...

>                               Jeff

Rob


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

Reply via email to