[uml-user] building gentoo stage1 inside a uml
Hey gang, just thought I would post this quick and dirty on how to build gentoo from stage 1 inside of a 2.6.9-bb4 UML. BTW, the bb4 patch seems to be really solid. I haven't run into a single issue with it thus far. Building gentoo from stage 1 inside a UML First create root_fs (creates a 2gig sparse file) dd of=root_fs bs=1024 count=200 seek=0 mkfs.ext3 root_fs mount root_fs mkdir uml mount root_fs uml -o loop unzip stage1 into root_fs cd uml tar xvjf ../stage1-x86-2004.3.tar.bz2 copy mount, route and ifconfig or ip into root_fs. Note that if you are using the iproute2 package you only need to copy ip and mount over. cp `which ifconfig` usr/bin cp `which ip` usr/bin cp `which mount` usr/bin cp `which route` usr/bin unmount uml cd .. umount uml boot uml, this assumes your host IP is 192.168.1.1. You can build the tuntap stuff by hand if you want, but for an install, the net helper is fine. linux ubd0=root_fs mem=128M eth0=tuntap,,,192.168.1.1 rw mount filesystems inside uml mount proc /proc -t proc mount none /dev/pts -t devpts bring up eth0 using ip ip addr add 192.168.1.111/24 brd + dev eth0 ip link set eth0 up ip route add default via 192.168.1.1 OR bring up eth0 using ifconfig ifconfig eth0 192.168.1.111 netmask 255.255.255.0 broadcast 192.168.1.255 up route add default gateway 192.168.1.1 dev eth0 edit make.conf to look like the following CFLAGS="-O2 -mcpu=i686 -fomit-frame-pointer" CHOST="i386-pc-linux-gnu" CXXFLAGS="${CFLAGS}" FEATURES="-sandbox" The -sandbox is very important, if you don't do this you will get a bunch of errors like this one ACCESS DENIED open_wr: /dev/console The short answer is that we dont really need gentoo to sandbox itself since we aren't in a chroot like stage1 expects but are instead in a full on uml. At this point, you can follow the stage1 build directions without modification. I'll make a purdy version soon. Enjoy! Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] building gentoo stage1 inside a uml
Thanks for the tip on NPTL. I will be sure to add it to the clean version that Im working on now. I should have it done by the end of this week at the latest. Yeah, Stage1 assumes that you are in a chroot and that it has no need to mount filesystems or to add routes/interfaces. So you have to copy at least mount and ip over. Once you get that done though, the build goes pretty smooth and doesn't seem to take too much of a performance hit (Im timing a build outside of uml and one inside of uml for comparison now) . The only other issue that I ran into, and that I will document later on, involves console fonts being set at boot opening up like 10 xterms with no gettys running on them. My temp fix is to remove the console font boot script, but I'm sure I just need to configure it, I was just so excited that the build worked I had to post! Once this one is done, Im going to work on a Linux From Scratch build. Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Tue, 7 Dec 2004, Blaisorblade wrote: On Tuesday 07 December 2004 10:13, Jason Clark wrote: Hey gang, just thought I would post this quick and dirty on how to build gentoo from stage 1 inside of a 2.6.9-bb4 UML. BTW, the bb4 patch seems to be really solid. I haven't run into a single issue with it thus far. Ok, it means that the uml-extramask fix was the only needed one... I'm *really* happy with that. Also, remember to promptly report everything as 2.6.10 will contain 2.6.9-bb4 fixes. Also, I'm happy to see that since Roger Sala had experienced various issues when building a Gentoo root_fs. They were very likely related to the previous stability issues of -bb4! Finally, I think that if I get the time, I will start building my own Gentoo root fs, and following your instructions. Building gentoo from stage 1 inside a UML First create root_fs (creates a 2gig sparse file) dd of=root_fs bs=1024 count=200 seek=0 mkfs.ext3 root_fs mount root_fs mkdir uml mount root_fs uml -o loop unzip stage1 into root_fs cd uml tar xvjf ../stage1-x86-2004.3.tar.bz2 copy mount, route and ifconfig or ip into root_fs. Note that if you are using the iproute2 package you only need to copy ip and mount over. cp `which ifconfig` usr/bin cp `which ip` usr/bin cp `which mount` usr/bin cp `which route` usr/bin They are *not* inside the root_fs? Oh, yes... normal Gentoo assumes you configure the network outside the chroot, so they're not needed! unmount uml cd .. umount uml boot uml, this assumes your host IP is 192.168.1.1. You can build the tuntap stuff by hand if you want, but for an install, the net helper is fine. linux ubd0=root_fs mem=128M eth0=tuntap,,,192.168.1.1 rw mount filesystems inside uml mount proc /proc -t proc mount none /dev/pts -t devpts bring up eth0 using ip ip addr add 192.168.1.111/24 brd + dev eth0 ip link set eth0 up ip route add default via 192.168.1.1 OR bring up eth0 using ifconfig ifconfig eth0 192.168.1.111 netmask 255.255.255.0 broadcast 192.168.1.255 up route add default gateway 192.168.1.1 dev eth0 edit make.conf to look like the following CFLAGS="-O2 -mcpu=i686 -fomit-frame-pointer" CHOST="i386-pc-linux-gnu" CXXFLAGS="${CFLAGS}" FEATURES="-sandbox" The -sandbox is very important, if you don't do this you will get a bunch of errors like this one ACCESS DENIED open_wr: /dev/console The short answer is that we dont really need gentoo to sandbox itself since we aren't in a chroot like stage1 expects but are instead in a full on uml. At this point, you can follow the stage1 build directions without modification. I'll make a purdy version soon. Enjoy! I'd like to add a note for who wants to follow this HOWTO: never enable nptl USE flags for glibc in the guest, since UML is NPTL-incompatible... and there is no possibility to get back by renaming /lib/tls! Bye Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- SF email is sponsored by
Re: [uml-user] building gentoo stage1 inside a uml
And here is the cleaner version on gentoo.org. http://forums.gentoo.org/viewtopic.php?p=1852877#1852877 Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Tue, 7 Dec 2004, Jason Clark wrote: Hey gang, just thought I would post this quick and dirty on how to build gentoo from stage 1 inside of a 2.6.9-bb4 UML. BTW, the bb4 patch seems to be really solid. I haven't run into a single issue with it thus far. Building gentoo from stage 1 inside a UML First create root_fs (creates a 2gig sparse file) dd of=root_fs bs=1024 count=200 seek=0 mkfs.ext3 root_fs mount root_fs mkdir uml mount root_fs uml -o loop unzip stage1 into root_fs cd uml tar xvjf ../stage1-x86-2004.3.tar.bz2 copy mount, route and ifconfig or ip into root_fs. Note that if you are using the iproute2 package you only need to copy ip and mount over. cp `which ifconfig` usr/bin cp `which ip` usr/bin cp `which mount` usr/bin cp `which route` usr/bin unmount uml cd .. umount uml boot uml, this assumes your host IP is 192.168.1.1. You can build the tuntap stuff by hand if you want, but for an install, the net helper is fine. linux ubd0=root_fs mem=128M eth0=tuntap,,,192.168.1.1 rw mount filesystems inside uml mount proc /proc -t proc mount none /dev/pts -t devpts bring up eth0 using ip ip addr add 192.168.1.111/24 brd + dev eth0 ip link set eth0 up ip route add default via 192.168.1.1 OR bring up eth0 using ifconfig ifconfig eth0 192.168.1.111 netmask 255.255.255.0 broadcast 192.168.1.255 up route add default gateway 192.168.1.1 dev eth0 edit make.conf to look like the following CFLAGS="-O2 -mcpu=i686 -fomit-frame-pointer" CHOST="i386-pc-linux-gnu" CXXFLAGS="${CFLAGS}" FEATURES="-sandbox" The -sandbox is very important, if you don't do this you will get a bunch of errors like this one ACCESS DENIED open_wr: /dev/console The short answer is that we dont really need gentoo to sandbox itself since we aren't in a chroot like stage1 expects but are instead in a full on uml. At this point, you can follow the stage1 build directions without modification. I'll make a purdy version soon. Enjoy! Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] building gentoo stage1 inside a uml
Cool. Thanks again for the heads up. I was thinking of tackling lfs6 and perhaps hlfs. I have been following it since it started up and I think it just might be a sweet little uml host and guest. Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Tue, 7 Dec 2004, Blaisorblade wrote: On Tuesday 07 December 2004 11:38, Jason Clark wrote: Thanks for the tip on NPTL. I will be sure to add it to the clean version that Im working on now. I should have it done by the end of this week at the latest. Yeah, Stage1 assumes that you are in a chroot and that it has no need to mount filesystems or to add routes/interfaces. So you have to copy at least mount and ip over. Once you get that done though, the build goes pretty smooth and doesn't seem to take too much of a performance hit (Im timing a build outside of uml and one inside of uml for comparison now) . The only other issue that I ran into, and that I will document later on, involves console fonts being set at boot opening up like 10 xterms with no gettys running on them. My temp fix is to remove the console font boot script, but I'm sure I just need to configure it, I was just so excited that the build worked I had to post! Once this one is done, Im going to work on a Linux From Scratch build. Be careful last LFS requires NPTL usage... you might need to go to LFS5, not LFS6... (heard something like that, causing problems with UML). -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] building gentoo stage1 inside a uml
very true, inside a chroot is faster. But building inside a UML sure was fun Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Wed, 8 Dec 2004, [ISO-8859-1] Sven Köhler wrote: Hey gang, just thought I would post this quick and dirty on how to build gentoo from stage 1 inside of a 2.6.9-bb4 UML. BTW, the bb4 patch seems to be really solid. I haven't run into a single issue with it thus far. I have a script that builds a stage1-gentoo inside a chroot on the host. That many times more efficient than building inside UML. I will share that script when it's ready. --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] uml and nptl
as a point of clarification. Is UML incompatible with nptl in a guest OS, a host OS or both? Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] NPTL question
Hey gang, I may have missed the response earlier, but is UML incompatible with NPTL on a Host, Guest or both OS? Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] hanging uml processes after schutdown
What guest/host kernel versions are you running. Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Mon, 13 Dec 2004, Andreas Schuldei wrote: i have two processes left, after shutdown of my uml machine: 5550 pts/8S+ 0:16 /usr/bin/linux (debian) [halt] 5552 pts/8T+ 0:03 [linux] when stracing the processes i see that the first one is doing a waitpid on the second one. the second one i cant strace, not even as root. what can this be? how can i do a clean shutdown? --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Shutdown problems
hmm. very odd. I have not had the same experience with bb4. It's been rock solid on gentoo 2004.3 UMLs. Are the both of you running fedora kernels or are you running vanilla kernels as a host ? Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Tue, 21 Dec 2004 [EMAIL PROTECTED] wrote: i've got problems while shutting down with the bb4 too. Hello I tried it with the bb4 patch on a athlon 1000. But I get a loud crash with a long kernel panic message from the guest kernel which causes that the crashed kernel process is not killable anymore which causes the need of restarting the host system to get rid of this crashed kernel process. It seems the bb4-patch needs a little bit of review to get it stable. Roland --- Yena <[EMAIL PROTECTED]> schrieb: The last patch "bb4" have fixed it. -- Yena --- On Mon, 20 Dec 2004 14:39:52 +0100 (CET), "Roland Kaeser" <[EMAIL PROTECTED]> said: Hello I have a strange problem with the UML on Fedora 2 Host (Kernel 2.6.9 SKAS3-V7) with a guest kernel of "User Mode Linux v2.6.9" (Kernel 2.6.9 Arch um) In this configuration the guest kernel hangs on the last command /sbin/halt and doesnt exits. In case that I wrote a shell script around the startup proceudre which enables the consoles and network interfaces and disables it after the kernel binary exits, this makes it impossible to proper shutdown all the network interfaces and consoles when the uml guest instance has been shut down. Does anybody have an idea? Roland ___ Gesendet von Yahoo! Mail - Jetzt mit 250MB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user -- Yena [EMAIL PROTECTED] ___ Gesendet von Yahoo! Mail - Jetzt mit 250MB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Hint for easy guest builds on Gentoo
Their are two current docs, one in gentoo devel and one that I wrote. The one in gentoo devel details the setup you just described. The one that I wrote details building from inside a UML. The devel docs are obviously much faster, but building from inside a UML sure was fun. I havent tried FC3, but I'll give it a spin. Jason We the willing, led by the unknowning, are doing the impossible, for the ungrateful. We have done so much, for so long, with so little. We are now qualified to do anything with nothing. On Tue, 28 Dec 2004, geoffrey wrote: I have found the easiest way to build a rootfs for guest systems on Gentoo is to make a directory, unpack the stage1 system into the directory, copy over your resolv.conf, chroot into the directory and follow the initial Gentoo build sequence to get a basic system - without adding a kernel or bootloader, of course. When you have done, exit the chroot, tar up the directory from it's root level, then use dd and mkfs to make a rootfs filesystem. Mount your rootfs filesystem on loopback and untar the previous build directory onto it. Voila, a gentoo rootfs! I believe the current usermode docs at the gentoo.org website suggest something similar. Now, does anyone know of a simple way to make an FC3 rootfs? geoffrey --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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://productguide.itmanagersjournal.com/ ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] 2.6.9-bb4 hangs
I have been trying to replicate the 2.6.9-bb4 shutdown hangs that some users have been experiencing. At the same time, I am building a new server at home that has a VERY minimal host os (think just enough to run iptables and uml-tools). The only way I have found to replicate the hang is if /proc is not mounted on the host system. This seems pretty expected to me as /proc is pretty darn important and a lot of things just wont work without it. But those of you that are still having shutdown problems on a 2.6.9-bb4 system, could you please verify that you have /proc mounted and are running as a user that has access to at least read /proc? Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] 2.6.9-bb4 hangs
good point, but it still seems to find the skas patch and continue on its way. Not sure why that is working. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Tue, 4 Jan 2005, roland wrote: Hi ! The only way I have found to replicate the hang is if /proc is not mounted on the host system. Doesn`t this mean, your UML is beig forced to run in TT mode this way ? IIRC, UML checks for /proc/mm on startup - if it finds it, it runs in SKAS-Mode - if not, it runs in TT mode. Probably I`m wrong herejust a quick comment. regards Roland - Original Message - From: "Jason Clark" <[EMAIL PROTECTED]> To: Sent: Tuesday, January 04, 2005 9:22 AM Subject: [uml-user] 2.6.9-bb4 hangs I have been trying to replicate the 2.6.9-bb4 shutdown hangs that some users have been experiencing. At the same time, I am building a new server at home that has a VERY minimal host os (think just enough to run iptables and uml-tools). The only way I have found to replicate the hang is if /proc is not mounted on the host system. This seems pretty expected to me as /proc is pretty darn important and a lot of things just wont work without it. But those of you that are still having shutdown problems on a 2.6.9-bb4 system, could you please verify that you have /proc mounted and are running as a user that has access to at least read /proc? Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] 2.6.9-bb4 hangs
I have been running 2.6.10 on my production stuff for a few weeks and have had no real issues with it. I was only trying to simulate the hang on 2.6.9-bb4 and that was the only way I was able to. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Sat, 8 Jan 2005, Blaisorblade wrote: On Wednesday 05 January 2005 00:58, Jason Clark wrote: good point, but it still seems to find the skas patch and continue on its way. Not sure why that is working. Well, it will find the SKAS patch, but not /proc/mm... and that may make it behave strangely... That said, the problem was solved immediately for SKAS mode, while for TT mode it was much more difficult, even due to various problems in the code implementing ptrace(). From your report, the conclusion is that for TT mode we haven't yet reached the fix... However, please upgrade to the 2.6.10 host... it improves the host behaviour a lot... when you get unkillable thread, that's not something UML can fix, but a problem in the host (I have received confirmations from the kernel guys about this). -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] No sysrq in guest kernel 2.6.9-bb4?
If its not too big of a deal, I would like it back in the UML submenu since uml_mconsole has the ability to use it. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Mon, 10 Jan 2005, Blaisorblade wrote: On Saturday 08 January 2005 14:49, Marco Genise wrote: Hi, i played around with user-mode-linux a while and set up an slackware 10.0 guest on slackware 10.0 host with kernel 2.6.9-skas3-v7. As guest kernel I used 2.4.28 first, but I've got the problem (which is already mentioned here) that guest os doesn't shut down or reboot clearly, with an process with status "T" left. So I tried kernel 2.6.9 with bb4-patch as guest, and it works well with shutdown and reboot, but now I've got another problem: When I try to use sysrq commands via uml_mconsole, I get the following error: "sysrq not compiled in". Yeah, I know, sysrq seems not be compiled in ... ;) But search around a while in mailing-list archives and with google didn't help me to solve this problem. I already tried to insert "CONFIG_MAGIC_SYSRQ=y" in kernel .config manually, but that also didn't work. Does anyone know how to enable sysrq in guest kernel 2.6.9 with bb4-patch? What did I do wrong? Thank you in advance. Marco. Well, good question... you are right, and I'm wondering too about this... until now, what I understood is that this doesn't come from the -bb4 patch, but from an error in a mainline cleanup. ... let me dig a bit... ...Oh, what is this?... ... Found! Try the attached patch. It WorksForMe(tm). The option appears under Kernel Debugging, as for the other archs... do you want it back in the UML config submenu? -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Best way to reboot multi guest server
I have set my UMLs up to have Control+Alt+Delete to be 'shutdown -h now'. I then have a script that, when I exectute a shutdown, first does a 'uml_mconsole $UML' cad for every running guest and then waits for 60 seconds. After 60 seconds, it looks for any remaining running UMLs and, if any remain, waiting another 60 seconds. If after 2 minutes some are still running, that means they are hung and I reboot anyway. Works pretty good, shutdowns take a bit, but I dont have to spend much time in fsck. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Wed, 12 Jan 2005 [EMAIL PROTECTED] wrote: Hi, i have Fedora core 2 Host ( 2.6.9 + skas3-v7 ) with many Guests ( Kernel 2.6.9 bb4 ). What is the best way to do a mass shutdown of all Guests? I ask it because now i can't shut own my Host server wthout a mass corruption of Guests FS. ( I have think about a mconsole with cad command but it reboot the guest .. i need a shutdown command ) Thanks Enrico --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] How to limit CPU load
I have tweaked the cpucap patch so it will apply against 2.6.9, and the cpuutil program so it will work with that patch, but the behaviour seems pretty odd. Is anyone currently running this patch so I can compare notes? Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Fri, 14 Jan 2005, Johannes Formann wrote: <[EMAIL PROTECTED]> wrote: Hi, i would like to limit whe CPU load for the single UML Guest. Look for the cpucap patch, an announce was posted on the list somewhere. regards Johannes --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almosthttp://www.thinkgeek.com/sfshirt ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] cpucap patch
In case anyone is interested, here is the cpucap and cpuutil patches I was talking about. They apply, but Im really not sure about the behaviour and dont have the ability to test on a 2.6.6 kernel until Monday. BTW, this is the first time I have worked with porting forward a kernel patch, so be gentle. CPUutil patch against the june 9th cpuutil release --- util/Makefile 2004-06-09 08:12:16.0 -0500 +++ zutil/Makefile 2005-01-15 17:45:06.0 -0600 @@ -4,10 +4,6 @@ FLAGS=-Wall -O3 2.6: - sed -e 's/NRSETCPUCAP/274/g' cap.c - make cap - -2.6.6: sed -e 's/NRSETCPUCAP/283/g' cap.c make cap cpucap patch against the June 9th cpucap release for linux 2.6.9 --- linux-2.6.9/arch/i386/kernel/entry.S2004-11-16 00:50:04.0 -0600 +++ linux-2.6.9x/arch/i386/kernel/entry.S 2005-01-15 17:16:22.0 -0600 @@ -902,6 +902,7 @@ ENTRY(sys_call_table) .long sys_mq_timedreceive /* 280 */ .long sys_mq_notify .long sys_mq_getsetattr + .long sys_cpucap/* cpucap */ .long sys_ni_syscall/* reserved for kexec */ .long sys_waitid --- linux-2.6.9/include/asm-i386/unistd.h 2004-10-18 16:54:37.0 -0500 +++ linux-2.6.9x/include/asm-i386/unistd.h 2005-01-15 17:17:44.0 -0600 @@ -288,10 +288,11 @@ #define __NR_mq_timedreceive (__NR_mq_open+3) #define __NR_mq_notify (__NR_mq_open+4) #define __NR_mq_getsetattr (__NR_mq_open+5) -#define __NR_sys_kexec_load283 -#define __NR_waitid284 +#define __NR_cpucap 283 +#define __NR_sys_kexec_load284 +#define __NR_waitid285 -#define NR_syscalls 285 +#define NR_syscalls 286 /* user-visible error numbers are in the range -1 - -124: see */ --- linux-2.6.9/include/linux/init_task.h 2004-10-18 16:53:13.0 -0500 +++ linux-2.6.9x/include/linux/init_task.h 2005-01-15 17:18:47.0 -0600 @@ -112,6 +112,9 @@ extern struct group_info init_groups; .proc_lock = SPIN_LOCK_UNLOCKED, \ .switch_lock= SPIN_LOCK_UNLOCKED, \ .journal_info = NULL, \ + .cap_timer = 0,\ + .cap_left = -1, \ + .cap_limit = HZ\ } --- linux-2.6.9/include/linux/sched.h 2004-10-18 16:53:13.0 -0500 +++ linux-2.6.9x/include/linux/sched.h 2005-01-15 17:20:15.0 -0600 @@ -562,6 +562,11 @@ struct task_struct { /* journalling filesystem info */ void *journal_info; +/* cpucap */ + unsigned long cap_timer; + int cap_left; + int cap_limit; + /* VM state */ struct reclaim_state *reclaim_state; @@ -621,6 +626,8 @@ do { if (atomic_dec_and_test(&(tsk)->usa #define PF_SWAPOFF 0x0008 /* I am in swapoff */ #define PF_LESS_THROTTLE 0x0010/* Throttle me less: I clean memory */ #define PF_SYNCWRITE 0x0020 /* I am doing a sync write */ +#define PF_CPUCAP 0x8000 /* cpucap */ + #ifdef CONFIG_SMP extern int set_cpus_allowed(task_t *p, cpumask_t new_mask); --- linux-2.6.9/kernel/sched.c 2004-10-18 16:54:55.0 -0500 +++ linux-2.6.9x/kernel/sched.c 2005-01-15 17:26:32.0 -0600 @@ -1310,6 +1310,7 @@ void fastcall sched_fork(task_t *p) */ local_irq_disable(); p->time_slice = (current->time_slice + 1) >> 1; + p->cap_left = (current->cap_left + 1) >> 1; /* * The remainder of the first timeslice might be recovered by * the parent if the child exits early enough. @@ -1317,7 +1318,9 @@ void fastcall sched_fork(task_t *p) p->first_time_slice = 1; current->time_slice >>= 1; p->timestamp = sched_clock(); - if (unlikely(!current->time_slice)) { + current->cap_left >>= 1; + if (!current->time_slice || + ((p->flags & PF_CPUCAP) && (!current->cap_left))) { /* * This case is rare, it happens when the parent has only * a single jiffy left from its timeslice. Taking the @@ -2447,16 +2450,27 @@ void scheduler_tick(int user_ticks, int } goto out_unlock; } + --p->cap_left; if (!--p->time_slice) { dequeue_task(p, rq->active); set_tsk_need_resched(p); p->prio = effective_prio(p); p->time_slice = task_timeslice(p); p->first_time_slice = 0; + if (p->flags & PF_CPUCAP) { + if (p->cap_left > 0){ + if (p->time_slice > p->cap_left) + p->time_slice = p->cap_left; + } else { + if(p->time_slice > p->cap_limit) + p->time_slice = p->cap_limit; + } + } if (!rq->expired_timestamp) rq->e
Re: [uml-user] cpucap patch
Thank you very much for the suggestions! I was wondering if the order and numbering mattered, now I know. :-) I'll retweak and repost. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Wed, 19 Jan 2005, Blaisorblade wrote: On Saturday 15 January 2005 18:32, Jason Clark wrote: In case anyone is interested, here is the cpucap and cpuutil patches I was talking about. They apply, but Im really not sure about the behaviour and dont have the ability to test on a 2.6.6 kernel until Monday. BTW, this is the first time I have worked with porting forward a kernel patch, so be gentle. CPUutil patch against the june 9th cpuutil release --- util/Makefile 2004-06-09 08:12:16.0 -0500 +++ zutil/Makefile 2005-01-15 17:45:06.0 -0600 @@ -4,10 +4,6 @@ FLAGS=-Wall -O3 2.6: - sed -e 's/NRSETCPUCAP/274/g' cap.c - make cap - -2.6.6: sed -e 's/NRSETCPUCAP/283/g' cap.c make cap It seems ok... NRSETCPUCAP the same thing as __NR_cpucap, i.e. is probably the index in the syscall table for sys_cpucap... but you need probably to modify the patch below, and update this number. See the explaination below. In short, it will likely become 285 (instead of 283). cpucap patch against the June 9th cpucap release for linux 2.6.9 I.e. this is the whole cpucap patch, in your forward port, correct? --- linux-2.6.9/arch/i386/kernel/entry.S 2004-11-16 00:50:04.0 -0600 +++ linux-2.6.9x/arch/i386/kernel/entry.S 2005-01-15 17:16:22.0 -0600 @@ -902,6 +902,7 @@ ENTRY(sys_call_table) .long sys_mq_timedreceive /* 280 */ The "280" means "This is entry no.280". .long sys_mq_notify .long sys_mq_getsetattr + .long sys_cpucap/* cpucap */ So sys_cpucap is at entry 283. .long sys_ni_syscall /* reserved for kexec */ .long sys_waitid --- linux-2.6.9/include/asm-i386/unistd.h 2004-10-18 16:54:37.0 -0500 +++ linux-2.6.9x/include/asm-i386/unistd.h 2005-01-15 17:17:44.0 -0600 @@ -288,10 +288,11 @@ #define __NR_mq_timedreceive (__NR_mq_open+3) #define __NR_mq_notify (__NR_mq_open+4) #define __NR_mq_getsetattr (__NR_mq_open+5) -#define __NR_sys_kexec_load 283 -#define __NR_waitid 284 +#define __NR_cpucap 283 +#define __NR_sys_kexec_load 284 +#define __NR_waitid 285 -#define NR_syscalls 285 +#define NR_syscalls 286 /* user-visible error numbers are in the range -1 - -124: see */ Ok, here (and consequently in the above two pieces) we have a problem - You should not put cpucap before other syscalls, because code using waitid will fail because it calls it as syscall no. 283 and actually calls cpucap(). You need to put cpucap as 285th entry, i.e. below those two syscalls you update. Maybe, since waitid is a recently added syscall (I'm not sure of this at all) you won't actually run into software using it, but since you're claiming odd behaviour this could be the cause. For the rest of the code, I don't have suggestions to give... -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] UML tuntap throughput problem
Look for the libpcap ringbuffer patch if you are having too many dropped packets. generic libpcap starts dropping packets at about 50mb per second, with the ringbuffer patch (should be able to find it on google) it scales much higher. Jason The place where you made your stand never mattered. Only that you were there... And still on your feet. On Mon, 31 Jan 2005, Nuutti Kotivuori wrote: Jeff Dike wrote: [EMAIL PROTECTED] said: Something somewhere is buffering a few packets, and dropping the rest. When the transfer rate goes high enough and there's no physical interface to create delay, the buffer gets full and the majority of packets are discarded. However, no dropped counters rise on any of the interfaces, nor are any kernel messages printed from uml or the host. Or, there's a locking bug somewhere that stalls the transfer for a while every now and then. If either of these it true, you should be able to track it down by tcpdumping both inside and outside the UML and looking at timestamps for a given packet or seeing which interface is dropping packets. The problem with the dumping is that since the problems only occur at high transfer speeds, and there's three places to dump from (both virtual machines and host) - all my attempts to get a complete trace of what is happening has been daunted by kernel dropping packets to be tcpdumped since the tcpdump processes have not been able to read them fast enough. I will try again though, with a bit more preparation. -- Naked --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Fwd: RE: [uml-devel] UML remote GUI problems
Did you set tightvnc up to use port 5900 as well? On Thu, 3 Feb 2005, Blaisorblade wrote: I'm forwarding this to the list because I've not the time to look at every UML user issue, and especially not now. I hope someone else can help you. -- Forwarded Message -- Subject: RE: [uml-devel] UML remote GUI problems Date: Thursday 03 February 2005 20:24 From: Greg Furlong <[EMAIL PROTECTED]> To: Blaisorblade <[EMAIL PROTECTED]> I have sshd running on the Linux machine and then i tried to run port forwarding through putty on port 5900. I then ran the command export DISPLAY=host-ip. I then used tightVNC to connect to the ip address that i had assigned while setting up the port forwarding. I keep getting an error Failed to server address. Did you type the address correctly. Regards = Original Message From Blaisorblade <[EMAIL PROTECTED]> = On Friday 28 January 2005 17:30, Greg Furlong wrote: I am a final year student taking a degree in Computing at Dublin Institute of Technology - Ireland. In my final year project I am doing a project using User Mode Linux. My project has set out to research the capabilities of User Mode Linux in a teaching environment. So far I have set up a server and now have users logging on from a terminal. They use a COW file so as not to corrupt the file system. Next I want to investigate and test the capabilities of User Mode Linux over a network using a Graphical User Interface. The problem that I am having is that I am finding it difficult to set up the GUI system. I was wondering if anybody could give me some pointers in the right direction Without knowing which are your difficulties? It's difficult. or could tell me of a tutorial on how to set it up. I have already looked at the user mode Linux website on sourceforge but have been unable to successfully complete the GUI instructions. What's the problem? You must install Xnest inside your guest system... it will then be able to forward connection to another X system (on which you have to authorize TCP connections from the UML system). Then it should work, more or less. I am running Red Hat Linux 9 2.4.20-8 User mode Linux Patch 2.4.27-1 Remote Terminal Putty On windows? well, there are also Xservers on Windows (the cygwin one for instance)... -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade -- This message has been scanned for content and viruses by the DIT Information Services MailScanner Service, and is believed to be clean. http://www.dit.ie -- This message has been scanned for content and viruses by the DIT Information Services MailScanner Service, and is believed to be clean. http://www.dit.ie --- --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Re: User-mode-linux-user digest, Vol 1 #1890 - 8 msgs
Do you have anything like iptables running? What has a tcpdump shown you? On Fri, 4 Feb 2005, Greg Furlong wrote: i have set up vnc to use port 5900 user-mode-linux-user@lists.sourceforge.net wrote: _ Sign up for eircom broadband now and get a free two month trial.* Phone 1850 73 00 73 or visit http://home.eircom.net/broadbandoffer --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] freeing memory in /tmp
Hey gang, I am having some problems with 2.6.9-bs6 guest umls not freeing memory in /tmp when they are shutdown. I know that this has been addressed on the mailing list in regards to killing a uml and the memory not getting freed, but I couldnt find anything about a proper shutdown having the same issue. Can anyone comment? --- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Fwd: RE: [uml-devel] UML remote GUI problems
The easiest method would be to just set the VNC server on the guest to listen on a specific port, then use iptables to forward requests from your physical interface on the host to the guest. Be sure to have your routing working correctly between the guest/host/you otherwise this won't work. I am running 6 guests on 1 host, 4 of which face the internet and that is how I provide services, by just forwarding ports from the hosts into the guests. On Tue, 22 Feb 2005, Blaisorblade wrote: I'm forwarding this to the list as I've no time to answer, sorry. -- Forwarded Message -- Subject: RE: [uml-devel] UML remote GUI problems Date: Wednesday 16 February 2005 20:12 From: Greg Furlong <[EMAIL PROTECTED]> To: Blaisorblade <[EMAIL PROTECTED]> Hey I just wanted to ask you if what I am doing is possible to do. To recap what I am trying to do is to have a host machine and set up tun/tap networking between the host and a number of UMLs I then want to be able to remotely access the UML using something like VNC or some other remote desk top viewer. What I dont understand about connecting to the UML is that when i connect to my host machine useing VNC I use the hosts IP address but if I wanted to connect to the UML then I would need to use its IP address but the problem is that it is a virtual IP address. I understand that the host is acting as a router so port forwarding would need to be set up to forward the connection to the UML but how would I could I set up the port forwarding on the fly. Thanks = Original Message From Blaisorblade <[EMAIL PROTECTED]> = On Friday 28 January 2005 17:30, Greg Furlong wrote: I am a final year student taking a degree in Computing at Dublin Institute of Technology - Ireland. In my final year project I am doing a project using User Mode Linux. My project has set out to research the capabilities of User Mode Linux in a teaching environment. So far I have set up a server and now have users logging on from a terminal. They use a COW file so as not to corrupt the file system. Next I want to investigate and test the capabilities of User Mode Linux over a network using a Graphical User Interface. The problem that I am having is that I am finding it difficult to set up the GUI system. I was wondering if anybody could give me some pointers in the right direction Without knowing which are your difficulties? It's difficult. or could tell me of a tutorial on how to set it up. I have already looked at the user mode Linux website on sourceforge but have been unable to successfully complete the GUI instructions. What's the problem? You must install Xnest inside your guest system... it will then be able to forward connection to another X system (on which you have to authorize TCP connections from the UML system). Then it should work, more or less. I am running Red Hat Linux 9 2.4.20-8 User mode Linux Patch 2.4.27-1 Remote Terminal Putty On windows? well, there are also Xservers on Windows (the cygwin one for instance)... -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade -- This message has been scanned for content and viruses by the DIT Information Services MailScanner Service, and is believed to be clean. http://www.dit.ie -- This message has been scanned for content and viruses by the DIT Information Services MailScanner Service, and is believed to be clean. http://www.dit.ie --- --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] odd swapping issue
I have recently seen an increase in traffic to one of my sites that is hosted using UML. Previously, I had allocated 128Megs of RAM and 1 gig of swap to each UML, but I never got close to touching the swap file. It always remained at 0% usage. With the traffic spike, I have noticed that I will drop all the way down to 200k of free RAM on a guest uml, but the swapfile is still never touched. I see it activated at boot, running `free` shows the swap file as being there, but the guest UML just doesn't want to use it. Can anyone shed some light on what makes my guest machines swap shy? Im running 2.6.10 skas3v7 as the host and 2.6.9bs6 guests. --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] odd swapping issue
I'll hammer it a bit harder and see if I can get it to release those last few pages into swap. Thanks. On Sun, 27 Feb 2005, Paul Warren wrote: On Fri, Feb 25, 2005 at 05:06:46PM -0600, Jason Clark wrote: I have recently seen an increase in traffic to one of my sites that is hosted using UML. Previously, I had allocated 128Megs of RAM and 1 gig of swap to each UML, but I never got close to touching the swap file. It always remained at 0% usage. With the traffic spike, I have noticed that I will drop all the way down to 200k of free RAM on a guest uml, but the swapfile is still never touched. When you say 200k of free RAM, which figure are you reading? It is normal for Linux to use up all available RAM under normal usage, as it will retain a cache of disk pages. It will throw these away if there is a real need for the RAM. For this reason, free will claim close to 100% memory usage long before it actually hits swap. Paul --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] odd swapping issue
Thank you very much Paul, I guess I just wasn't hitting my machines as hard as I thought. Swap did it's job and paged out. Thanks again! On Mon, 28 Feb 2005, Paul Warren wrote: On Sun, Feb 27, 2005 at 05:05:35PM -0600, Jason Clark wrote: I'll hammer it a bit harder and see if I can get it to release those last few pages into swap. Thanks. Well, if you're trying to prove that it will actually swap, then a simple C program of the form: int main(int argc, char** argv) { calloc(100,1024*1024); sleep(100); return 0; } Will attempt to allocate 100MB of RAM. The second line of output from "free" will give you a much better indication of how much RAM is available before it will start swapping. Paul On Sun, 27 Feb 2005, Paul Warren wrote: On Fri, Feb 25, 2005 at 05:06:46PM -0600, Jason Clark wrote: I have recently seen an increase in traffic to one of my sites that is hosted using UML. Previously, I had allocated 128Megs of RAM and 1 gig of swap to each UML, but I never got close to touching the swap file. It always remained at 0% usage. With the traffic spike, I have noticed that I will drop all the way down to 200k of free RAM on a guest uml, but the swapfile is still never touched. When you say 200k of free RAM, which figure are you reading? It is normal for Linux to use up all available RAM under normal usage, as it will retain a cache of disk pages. It will throw these away if there is a real need for the RAM. For this reason, free will claim close to 100% memory usage long before it actually hits swap. Paul --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] Count them off
Hey gang, The list has been fairly quiet lately, so I thought I would pose a question. Let's hear what you use UML for. What are you doing with it? I'm running on a Sempron 2200 with LVM and software RAID on my host system. I have 5 guests up and running. Apache web server listening on the internet qmail mail server listening on the internet samba file server listening on my lan squid proxy server listening on my lan nocatauth listening on the wireless network So how about you guys? --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] mem parameter
How much space do you have available in /tmp ? -- -- Jason When pigs fly, they fly first class. On Fri, 11 Mar 2005, Jean-Michel Caricand wrote: Hi, I have 4go on my server. Only 800 mo are use. When I launch a uml instance with mem=256M param that work fine. But when launch a uml instance with mem=512M, I get this message : SegFault Why ? Thank. --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] mem parameter
And I assume that of that 1 gig, at least 512M are free? -- -- Jason When pigs fly, they fly first class. On Fri, 11 Mar 2005, Jean-Michel Caricand wrote: Le vendredi 11 Mars 2005 14:51, Jason Clark a écrit : How much space do you have available in /tmp ? Hi Jason, I have 1go in /tmp --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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_ide95&alloc_id396&op=click ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] UML and SWSUSP2
Hey guys, just as an FYI, 2.6.9-skas3-v7 hosts running 2.6.9-bb4 guests works very well with software suspend 2. After suspending my laptop and then bringing it back online, my UML was still happily serving webpages. Thought you might like to know. -- Jason When pigs fly, they fly first class. --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
RE: [uml-user] current root images
I have written instructions on the gentoo forums on how to build inside a guest kernel from stage 1. LinuxFromScratch 5.2 works wells as a UML, but 6 does not (NPTL troubles). -- Jason When pigs fly, they fly first class. On Fri, 8 Apr 2005, Anthony Brock wrote: You might also try some of the ones listed at on the wiki: http://uml.harlowhill.com/index.php/UMLRootFilesystems However, these are also somewhat dated. If you find others, please add them to this site. Tony -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Scott Granados Sent: Friday, April 08, 2005 12:39 AM To: user-mode-linux-user@lists.sourceforge.net Subject: [uml-user] current root images Hi, I wonder if anyone has available any more current root images. The ones on the uml site are helpful but out of date a bit. I'd be interested possibly in new redhat or centos or slackware images. I've not figured out the process to make my own yet and had it work. Thanks --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] multicast networking
Hey guys, Im using a 2.6.9 guest on a 2.6.9 host to do a proof of concept for work using zebra for bgp. I have two guests up using multicast for their eth1 interfaces and tuntaps for their eth0 interfaces. It seems that the only way I can get multicast to work though is if my physical eth0 on my host machine is up and has an IP address. My tap devices show up as being multicast capable, but if I try to use one of those, the guests don't think that a multicast capable device is present. Likewise, if my physical interface on my host loses its IP or if even the cable comes unplugged, my guests cant use the multicast backend. Is their anyway to get umls talking to each other without having to route them (since Im using bgp between guests, I cant route) and without having to multicast across a physical interface? -- Jason When pigs fly, they fly first class. --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] multicast redux
to clarify, I am trying to avoid using the switch daemon as I need this as transparent to the host as possible. -- Jason When pigs fly, they fly first class. --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Emulating physical machines using UML?
You can use UML for this, but you will need a pretty massive box in order to simulate hundreds of machines. With a gig of RAM, I can usually have not more then 10 UMLs running (64meg a piece). For what you are wanting though, you would be better served looking into something like smartbits -- Jason When pigs fly, they fly first class. On Fri, 22 Apr 2005, Ragnar Lonn wrote: Hello all, I'm new to UML, although I've looked at it a little earlier. I have a pretty tricky problem that I'm wondering whether UML could help me with or if I should look somewhere else for a solution. I realize this question might be kind of difficult to answer but it's worth a shot at least. I am presently trying to setup a system that simulates a number of physical machines using a single machine. (We want to do this in order to test Internet access hardware) We have to emulate hundreds of home users connecting their PC's, VoIP or multicast receiver (video streaming) equipment to the network, acquiring IP addresses and transmitting and receiving network traffic. We would like to do this *without* having to use hundreds of actual, physical machines. What we have done so far is to, under Linux, set up 24 VLAN interfaces on a PC. These VLAN interfaces have been given unique MAC addresses. Then we connect the PC's ethernet interface to the uplink of a VLAN switch which gives us 24 downlink ports that can be connected to our access hardware. The access hardware will believe each port connects to a separate physical machine while in fact we use a single machine behind a VLAN setup to emulate 24 machines. The problem is that to make traffic exit through the right (virtual) interface we have to use source routing on the PC. If we e.g. have VLAN interface eth1.101 setup with MAC address 02:04:06:08:0a:0c and IP address 1.2.3.4 we also set up a source route for 1.2.3.4 using Linux iproute. We tell the OS to route all traffic from 1.2.3.4 to the gateway the client 1.2.3.4 should be using and to send the traffic through interface eth2.101. So far so good. As long as the various applications we use to generate and consume network traffic are able to bind to a specific local interface/address (1.2.3.4) on the PC, their traffic will exit through the right virtual interface, resulting in the packets getting sent from MAC address 02:04:06:08:0a:0c and being tagged with the right VLAN tag, making the VLAN switch route the packets to the right downstream port into the access hardware on the other side. But...we have run into a Linux kernel limitation. We need to setup one routing table (using iproute) for every virtual VLAN interface we're using, like this: # Add source route rule, telling the OS to use routing table 101 to route # traffic originating from 1.2.3.4 ip rule add from 1.2.3.4 lookup 101 # Add default route to table 101 ip route add default via 1.2.3.254 dev eth2.101 table 101 The problem here is that there can only be ~250 routing tables configured on the machine. This means that we can only emulate ~250 separate client machines (boxes with their own MAC addresses) on a single PC. We would like to emulate about 1000 separate client machines on one PC. My question is - can we do this using UML and if so, how? Also, if anyone has any suggestions on alternative ways of doing this (on any platform), I'd be happy to receive them. Regards, /Ragnar --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- 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-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] stranger network problem.
did your host IP change? did you setup proxy arp or are you using iptables to NAT? -- Jason When pigs fly, they fly first class. On Wed, 27 Apr 2005, Jack wrote: hi, i met i stranger network problem umls use tuntap network , and it works ok. but after some times from the out side ,can't ping or ssh or ftp it, then from the host ping the uml,and it replys after that ,from the outside can ping it and ftp and so on. what 's the problem . very headache. someone helps me . thanks jack --- SF.Net email is sponsored by: Tell us your software development plans! Take this survey and enter to win a one-year sub to SourceForge.net Plus IDC's 2005 look-ahead and a copy of this survey Click here to start! http://www.idcswdc.com/cgi-bin/survey?id=105hix ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- SF.Net email is sponsored by: Tell us your software development plans! Take this survey and enter to win a one-year sub to SourceForge.net Plus IDC's 2005 look-ahead and a copy of this survey Click here to start! http://www.idcswdc.com/cgi-bin/survey?id=105hix ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] Stinghorn Virtual Linux based on UserModeLinux
FOr what its worth, I have started working on a distro called HydraLinux that will use UML "heads" to provide services. Im still working out the finer points and getting an alpha to work on my machine at home. I'll update and post code to www.hydralinux.com once I have something that isn't too humiliating to post. -- Jason When pigs fly, they fly first class. On Fri, 6 May 2005 [EMAIL PROTECTED] wrote: Hello, just for your information - there is a commercially "branded" UML out now (don`t know for how long, but I came across stinghorn today): http://www.stinghorn.com/opensource/ I thought it was worth mentioning, because there is no reference to "stinghorn" on the website or in the ML archives. regards roland --- This SF.Net email is sponsored by: NEC IT Guy Games. Get your fingers limbered up and give it your best shot. 4 great events, 4 opportunities to win big! Highest score wins.NEC IT Guy Games. Play to win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20 ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] LiveCD and UML
SHould be possible using COW files. Create your bootable CD, then create a COW file that exists on the CD. Then, mount a partion as tmpfs and place your RW file there. You will have to create the RW file at every boot obviously. I wonder if you could just mount /dev/rd/0 as ubd0. That would be pretty neat. -- Jason When pigs fly, they fly first class. On Fri, 6 May 2005, Jean-Michel Caricand wrote: Hi, I need to create livecd with UML (one host and one guest). Is it possible ? Thank. --- This SF.Net email is sponsored by: NEC IT Guy Games. Get your fingers limbered up and give it your best shot. 4 great events, 4 opportunities to win big! Highest score wins.NEC IT Guy Games. Play to win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20 ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- This SF.Net email is sponsored by: NEC IT Guy Games. Get your fingers limbered up and give it your best shot. 4 great events, 4 opportunities to win big! Highest score wins.NEC IT Guy Games. Play to win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20 ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] Building LinuxFromScratch 6.x for UML
Hey gang, if you follow the latest LFS books and try to run UML, it won't work. LFS 6x has moved to NPTL, and as we all know, UML and NPTL don't play well together. You can make two changes to the default book, both in regards to building glibc, to get a LFS 6x box that uses linuxthreads instead of NPTL. In the first glibc build for the static system, change the configure command to the following. ../glibc-2.3.4/configure --prefix=/tools --with-headers=/tools/include --with-bintuls=/tools/bin --without-cvs --disable-profile --disable-debug --without-gd --enable-add-ons=linuxthreads --with-tls --without-__thread --enable-kernel=2.4 And in the second build for the finished system, change the command again to the following. ../glibc-2.3.4/configure --prefix=/usr --without-cvs --disable-profile --disable-debug --without-gd --enable-add-ons=linuxthreads --with-tls --without-__thread --enable-kernel=2.4 Other then that, you can follow the book like usual. Enjoy. -- Jason When pigs fly, they fly first class. --- This SF.Net email is sponsored by the 'Do More With Dual!' webinar happening July 14 at 8am PDT/11am EDT. We invite you to explore the latest in dual core and dual graphics technology at this free one hour event hosted by HP, AMD, and NVIDIA. To register visit http://www.hp.com/go/dualwebinar ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] UML using 100% CPU after mounting root filesystem
silly question, but I had a similar issue (cpu and ram) when my guest was running an FSCK. Are you running an fsck or is it idle? -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Wed, 20 Jul 2005, Ruaidhri Power wrote: I've just upgraded UML, and came across this problem: when starting the guest, output stops after "VFS: Mounted root (ext3 filesystem) readonly." - at that point the guest takes 100% CPU, consuming both user and system time. The host is Debian sarge, running vanilla 2.6.12 with the skas-2.6.12-v8.2 patch. The guest is vanilla 2.6.12 with Paolo's 2.6.12-bs7 patch, though I've verified the problem still occurs without that patch. I can post the host and guest's .configs if needed. The problem occurs on my own images which previously worked on older UML versions, and I've also tried one of the images from the Sourceforge site. Has anyone any idea why this is happening? If not, how should I go about debugging it to help the UML developers? The complication is that this is a headless box. I've added `debug' to the kernel command line, but I don't get an xterm with gdb in. Yes, xterm and gdb are installed and I've run xlogo to test that X11 forwarding is working. Running gdb as `gdb linux' doesn't seem to work because I keep receiving SIGTRAPs. I've heard debugging in skas mode is hard, any pointers here? Thanks in advance for any help you can give. Guest output follows: [EMAIL PROTECTED]:~$ linux ubd1=swap eth0=tuntap,,,x.x.x.29 mem=768M Checking for /proc/mm...found Checking for the skas3 patch in the host...found Checking PROT_EXEC mmap in /tmp...OK Kernel virtual memory size shrunk to 32505856 bytes Linux version 2.6.12-bs7 ([EMAIL PROTECTED]) (gcc version 3.3.5 (Debian 1:3.3.5-13)) #1 Wed Jul 20 12:32:41 IST 2005 Built 1 zonelists Kernel command line: ubd1=swap eth0=tuntap,,,x.x.x.29 mem=768M root=98:0 PID hash table entries: 2048 (order: 11, 32768 bytes) Dentry cache hash table entries: 65536 (order: 6, 262144 bytes) Inode-cache hash table entries: 32768 (order: 5, 131072 bytes) Memory: 467200k available Mount-cache hash table entries: 512 Checking for host processor cmov support...Yes Checking for host processor xmm support...No Checking that ptrace can change system call numbers...OK Checking syscall emulation patch for ptrace...OK Checking advanced syscall emulation patch for ptrace...OK Checking that host ptys support output SIGIO...Yes Checking that host ptys support SIGIO on close...No, enabling workaround Checking for /dev/anon on the host...Not available (open failed with errno 2) NET: Registered protocol family 16 mconsole (version 2) initialized on /home/ruaidhri/.uml/2JjIYf/mconsole Netdevice 0 : TUN/TAP backend - IP = x.x.x.29 highmem bounce pool size: 64 pages devfs: 2004-01-31 Richard Gooch ([EMAIL PROTECTED]) devfs: boot_options: 0x0 io scheduler noop registered io scheduler anticipatory registered io scheduler deadline registered io scheduler cfq registered loop: loaded (max 8 devices) tun: Universal TUN/TAP device driver, 1.6 tun: (C) 1999-2004 Max Krasnyansky <[EMAIL PROTECTED]> NET: Registered protocol family 2 IP: routing cache hash table of 8192 buckets, 64Kbytes TCP established hash table entries: 131072 (order: 8, 1048576 bytes) TCP bind hash table entries: 65536 (order: 6, 262144 bytes) TCP: Hash tables configured (established 131072 bind 65536) ip_tables: (C) 2000-2002 Netfilter core team NET: Registered protocol family 1 NET: Registered protocol family 10 IPv6 over IPv4 tunneling driver ip6_tables: (C) 2000-2002 Netfilter core team NET: Registered protocol family 17 Initialized stdio console driver Console initialized on /dev/tty0 Initializing software serial port version 1 /dev/ubd/disc0: unknown partition table /dev/ubd/disc1: unknown partition table kjournald starting. Commit interval 5 seconds EXT3-fs: mounted filesystem with ordered data mode. VFS: Mounted root (ext3 filesystem) readonly. --- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
[uml-user] COW files and block devices
I have been using linux software RAID block devices as my files for my UML hosts. Instead of using linux ubd0=file.fs I use linux ubd0=/dev/md0 The performance increase is outstanding, but I have run into one small snag. I am trying to migrate over to using COW files on a fresh server, but I cant figure out how to use block devices instead of files. I have tried a couple of things. mount /dev/md0 as /mnt/backing/ and put a backing file (rootfs.ro)in that dir. the dir is mounted readonly and then I try to start a UML like this linux ubd0=/dev/md1,/mnt/backing/rootfs.ro I've tried creating the backing file on the md0 device itself and tried starting a UML like this linux ubd0=/dev/md1,/dev/md0 (remembering md0 is my backing "file") Neither of these seem to work, just get a kernel panic about not being able to find a rootfs. THe backing file will boot on its own as will the md0 device, but I cant seem to get the cow file relationship working. Any thoughts or am I just wasting time? -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] COW files and block devices
Here is the output trying to use /dev/md1 as my cow file and /mnt/cow/rootfs.cow as my backing file [EMAIL PROTECTED]:/mnt# linux ubd0=/dev/md1,/mnt/cow/rootfs.cow ... [42949373.53] Console initialized on /dev/tty0 [42949373.53] Initializing software serial port version 1 [42949373.57] Failed to read COW header from COW file "/dev/md1", errno = 22 [42949373.57] Failed to open '/dev/md1', errno = 22 [42949373.57] VFS: Cannot open root device "98:0" or unknown-block(98,0) [42949373.57] Please append a correct "root=" boot option [42949373.57] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(98,0) [42949373.57] [42949373.57] EIP: 0073:[] CPU: 0 Not tainted ESP: 007b:b7e5afb0 EFLAGS: 0246 ... I get the same results trying to use a block device. Attemping a uml_mkcow with md1 as my cow and md2 as my backing file generates the following [EMAIL PROTECTED]:/mnt# uml_mkcow /dev/md1 /dev/md2 open COW file: File exists [EMAIL PROTECTED]:/mnt# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 write_cow_header: Invalid argument -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Wed, 3 Aug 2005, Jeff Dike wrote: On Wed, Aug 03, 2005 at 02:23:58PM -0500, Jason Clark wrote: Neither of these seem to work, just get a kernel panic about not being able to find a rootfs. THe backing file will boot on its own as will the md0 device, but I cant seem to get the cow file relationship working. Any thoughts or am I just wasting time? What's the console output? Jeff --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] COW files and block devices
md1 and md2 are both 5 gig. md2 will eventually be much smaller. Changing lseek to lseek64 in cow_sys.h results in the same error. [EMAIL PROTECTED]:~# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 write_cow_header: Invalid argument Here is the results of the same command after adding the printf to cow.c [EMAIL PROTECTED]:~/tools# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 bitmap_offset_out -1080912056, data_offset_out -1080912064 write_cow_header: Invalid argument For what it is worth, I have been using umls with block devices (md's and LVMs included) for some time, I just can't seem to get the cow stuff working. -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Thu, 4 Aug 2005, Blaisorblade wrote: On Wednesday 03 August 2005 23:01, Jason Clark wrote: Here is the output trying to use /dev/md1 as my cow file and /mnt/cow/rootfs.cow as my backing file [EMAIL PROTECTED]:/mnt# linux ubd0=/dev/md1,/mnt/cow/rootfs.cow ... [42949373.53] Console initialized on /dev/tty0 [42949373.53] Initializing software serial port version 1 [42949373.57] Failed to read COW header from COW file "/dev/md1", errno = 22 [42949373.57] Failed to open '/dev/md1', errno = 22 [42949373.57] VFS: Cannot open root device "98:0" or unknown-block(98,0) [42949373.57] Please append a correct "root=" boot option [42949373.57] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(98,0) [42949373.57] [42949373.57] EIP: 0073:[] CPU: 0 Not tainted ESP: 007b:b7e5afb0 EFLAGS: 0246 ... I get the same results trying to use a block device. Attemping a uml_mkcow with md1 as my cow and md2 as my backing file generates the following [EMAIL PROTECTED]:/mnt# uml_mkcow /dev/md1 /dev/md2 open COW file: File exists [EMAIL PROTECTED]:/mnt# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 write_cow_header: Invalid argument Let me guess - your md1 file is *big* (more than 2G), right? Or it isn't set up well (but I leave that as an exercise to the reader). I think I found that for uml_utilities: tools/moo/cow_sys.h -> cow_seek_file, replace lseek with lseek64 and recompile - I guess the offset got truncated. For the UML kernel, unless it's unreasonably old, that should not be the problem, although something on those lines may have happened... Inside cow.c:init_cow_file, where the first error is printed, can you add a debug "printf" statement for the offset to check it's reasonable, and do a strace on the thing to see if the problem. Another hypotesis (which is strange for me, but just off the top of my head): has UML problems because HD can't be sparse files? lseek should work as well, but who knows... --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] COW files and block devices
will do, thanks for the pointers. -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Fri, 5 Aug 2005, Blaisorblade wrote: On Thursday 04 August 2005 22:02, Jason Clark wrote: md1 and md2 are both 5 gig. md2 will eventually be much smaller. Guess it won't, it must be 5G long. On normal files you can use sparse ones, not on block devices... and if that seems stupid, yeah, COW files were designed for sparse files... dunno whether adding an indirection table for sector (saying "sector no. A is at location B in the file") would hurt performance. Changing lseek to lseek64 in cow_sys.h results in the same error. [EMAIL PROTECTED]:~# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 write_cow_header: Invalid argument Here is the results of the same command after adding the printf to cow.c [EMAIL PROTECTED]:~/tools# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 bitmap_offset_out -1080912056, data_offset_out -1080912064 Ok, bitmap_offset_out is set with this just a bit above: *bitmap_offset_out = ROUND_UP(sizeof(struct cow_header_v3), alignment); and alignment is the result of sysconf(_SC_PAGESIZE), i.e. should be 4096. So there's definitely something bitrotting there... Jason, I'm really busy, so do you think you can work on that? There must be some overflow somewhere with sign calculation (we are using unsigned long's somewhere, even if the value shouldn't overflow anyway). lseek arguments are signed int/long's (because you can seek from the end)... write_cow_header: Invalid argument For what it is worth, I have been using umls with block devices (md's and LVMs included) for some time, I just can't seem to get the cow stuff working. --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] COW files and block devices
BTW, Im a bonehead and forgot to derefernce the pointer for those offset vars. The actual values are below. Im looking into it. [EMAIL PROTECTED]:~/tools/moo# ./uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 bitmap_offset_out 8192, data_offset_out 1232896 write_cow_header: Invalid argumen -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Fri, 5 Aug 2005, Blaisorblade wrote: On Thursday 04 August 2005 22:02, Jason Clark wrote: md1 and md2 are both 5 gig. md2 will eventually be much smaller. Guess it won't, it must be 5G long. On normal files you can use sparse ones, not on block devices... and if that seems stupid, yeah, COW files were designed for sparse files... dunno whether adding an indirection table for sector (saying "sector no. A is at location B in the file") would hurt performance. Changing lseek to lseek64 in cow_sys.h results in the same error. [EMAIL PROTECTED]:~# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 write_cow_header: Invalid argument Here is the results of the same command after adding the printf to cow.c [EMAIL PROTECTED]:~/tools# uml_mkcow -f /dev/md1 /dev/md2 cow bitmap lseek failed : errno = 22 bitmap_offset_out -1080912056, data_offset_out -1080912064 Ok, bitmap_offset_out is set with this just a bit above: *bitmap_offset_out = ROUND_UP(sizeof(struct cow_header_v3), alignment); and alignment is the result of sysconf(_SC_PAGESIZE), i.e. should be 4096. So there's definitely something bitrotting there... Jason, I'm really busy, so do you think you can work on that? There must be some overflow somewhere with sign calculation (we are using unsigned long's somewhere, even if the value shouldn't overflow anyway). lseek arguments are signed int/long's (because you can seek from the end)... write_cow_header: Invalid argument For what it is worth, I have been using umls with block devices (md's and LVMs included) for some time, I just can't seem to get the cow stuff working. --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] CPU time
Search the mailing lists for cpucap. I had reposted a patch that someone else had done that would apply to 2.6.8 I believe that actually limits the % of CPU that a process can use and not just the time it can be running. Buggy, no guarentees, not supported and I can't even really remember how it worked, but you might have some luck with it. -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Wed, 17 Aug 2005, Gordon Russell wrote: On 17/08/05, Jean-Michel Caricand <[EMAIL PROTECTED]> wrote: I want to limit CPU time for a guest instance. What is the best method ? ulimit would limit total CPU time if thats what you are after. I run a programme in the background which monitors all the instances and renices them dynamically. Heavy users get niced heavily. It uses a simple ruleset so that heavy users who are reniced can be reniced back to normal again if their usage returns to normal. This works well in my network (50+ instances over 4 machines). The code is integrated into my site, so I cannot send you the code, but it was quite easy to write. This gives "fair usage" to the instances, without an arbitrary CPU time limit. G. --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user
Re: [uml-user] performance of block devices resp. filesystems
I run on real block devices (in my case, linux software RAID 1 devices) for each of my umls. Im currently running 4 UMLS on a box, each with their own RAID 1 md device. Works out pretty well, the performance is good and the host system doesnt get anywhere near as bogged down when a guest does an IO intense job. -- Jason The place where you made your stand never mattered. Only that you were there.. And still on your feet. On Sat, 20 Aug 2005, Markus Hochholdinger wrote: Hi, can anybody tell me which is the best performing fs for a running uml? How much of the performce of the disks can i get through to the uml? I tried ubd files on a ext3 filesystem on the host. But the performance was very bad. Then i tried nfs and it performs better and it has the advantages i need. So my thinking is, that ubd to a real partition should be fastest. Second perhaps is nfs to the host. hostfs, as i read on this mailing list, would be third (but i think hostfs is no really usable fs as / because of the file permissions). Fourth would be ubd to a file on the host. Have i overlooked one? What do you think? I'm planning to migrate a couple of old machines to multiple uml machines on one host. So i prefer nfs over ubd, because with nfs i can "automatically" give disk space to the uml who needs it and don't have to fiddle with partition sizes and resizing fs. Has anyone better solutions for my scenario? PS: Today is the day i made performace tests of my filesystems. On the host i get 40-50MB/s, in the uml i get with sync nfs 2MB/s and with async nfs 8-10MB/s. And now my exciting things i will do with uml seems to go far away... --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ User-mode-linux-user mailing list User-mode-linux-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user