From: Frank L. <len...@pa...> - 2002-09-01 10:00:22
|
on Fri, Aug 30, 2002 at 04:59:53AM -0700, James McMechan wrote about Re: Re= try: [uml-user] UML and Virtual Hosting (Frank Lenaerts): > What I think you really want to use so that screen works better is > "con0=3Dfd:0,fd:1 con=3Dport:${HOST_PORT}" so that the first console stay= s on > the initial file descriptors and all others are sent to the port interfac= e. > This will allow the first screen to continue without stopping, which it > currently does when it completes the pre-init-conosle output, at which po= int > the console(0) output is directed to port:${HOST_PORT} and you no > longer see it. Indeed: this is the thing I want to have. Unfortunately, it does not work for me. When I boot my uml in the first screen window, the boot process stops after starting cron. When I use another screen window and telnet localhost 9011, the boot process in the first screen window continues after which the second screen window presents me with the login. I wonder why I first have to telnet to the uml and why it does not continue the boot process in the first window. --- begin --- frank@mars:/space/uml/test $ ./homer.boot=20 tracing thread pid =3D 16213 Linux version 2.4.18-48um (mdz@mizar) (gcc version 2.95.4 20011002 (Debian = prerelease)) #1 Wed Jul 31 00:09:03 EDT 2002 On node 0 totalpages: 16384 zone(0): 16384 pages. zone(1): 0 pages. zone(2): 0 pages. Kernel command line: eth0=3Dtuntap,,,192.168.2.10 eth1=3Dmcast ubd0=3D/spac= e/uml/test/homer_cow umid=3Dhomer con0=3Dfd:0,fd:1 con=3Dport:9011 mem=3D64= M root=3D/dev/ubd0 Calibrating delay loop... 879.64 BogoMIPS Memory: 62456k available Dentry-cache hash table entries: 8192 (order: 4, 65536 bytes) Inode-cache hash table entries: 4096 (order: 3, 32768 bytes) Mount-cache hash table entries: 1024 (order: 1, 8192 bytes) Buffer-cache hash table entries: 4096 (order: 2, 16384 bytes) Page-cache hash table entries: 16384 (order: 4, 65536 bytes) Checking for host processor cmov support...Yes Checking for host processor xmm support...No Checking that ptrace can change system call numbers...OK Checking that host ptys support output SIGIO...No, enabling workaround Checking that host ptys support SIGIO on close...No, enabling workaround POSIX conformance testing by UNIFIX Linux NET4.0 for Linux 2.4 Based upon Swansea University Computer Society NET3.039 Initializing RT netlink socket Starting kswapd VFS: Diskquotas version dquot_6.4.0 initialized Journalled Block Device driver loaded devfs: v1.10 (20020120) Richard Gooch (rg...@at...) devfs: boot_options: 0x0 pty: 256 Unix98 ptys configured block: 128 slots per queue, batch=3D32 NET4: Linux TCP/IP 1.0 for NET4.0 IP Protocols: ICMP, UDP, TCP IP: routing cache hash table of 512 buckets, 4Kbytes TCP: Hash tables configured (established 4096 bind 4096) NET4: Unix domain sockets 1.0/SMP for Linux NET4.0. Netdevice 0 : TUN/TAP backend - IP =3D 192.168.2.10 Initializing software serial port version 1 Configured mcast device: 239.192.168.1:1102-1 Netdevice 1 : mcast backend multicast adddress: 239.192.168.1:1102, TTL:1 mconsole (version 2) initialized on /home/frank/.uml/homer/mconsole Partition check: ubda: unknown partition table Initializing stdio console driver kjournald starting. Commit interval 5 seconds EXT3-fs: mounted filesystem with ordered data mode. VFS: Mounted root (ext3 filesystem) readonly. INIT: version 2.84 booting Activating swap. Checking root file system... fsck 1.27 (8-Mar-2002) /dev/ubd0: clean, 11141/128000 files, 23273/256000 blocks EXT3 FS 2.4-0.9.17, 10 Jan 2002 on ubd(98,0), internal journal Calculating module dependencies... done. Loading modules: Checking all file systems... fsck 1.27 (8-Mar-2002) Setting kernel variables. Mounting local filesystems... nothing was mounted Running 0dns-down to make sure resolv.conf is ok...done. Setting up IP spoofing protection: rp_filter. Configuring network interfaces: done. Cleaning: /tmp /var/lock /var/run. Initializing random number generator... done. Recovering nvi editor sessions... done. INIT: Entering runlevel: 2 Starting system log daemon: syslogd. Starting kernel log daemon: klogd. Starting internet superserver: inetd. Starting deferred execution scheduler: atd. Starting periodic command scheduler: cron. --- end --- > You also do not need a second screen instance in that screen lets you > have several terminals open at once, you may already realize this but I > could not tell from the message. > Screen does not require X as it can be used for any text console, and with > Steve's options it is fairly easy to keep track of which to connect to. >=20 > >I'm running the UML kernels with "screen -m -d -S $username" which > >lets you attach to the console with "screen -x $username", as someone > >pointed out on this list not long ago. If someone has a problem, they > >can contact me, and I can attach to their "box" to see what's up. >=20 > >Steve > >-- > >st...@si... >=20 > I hope this is helpful, it took a while to for me to decipher what I think > is happening enough to offer a suggestion Your deciphering algorithm works correctly;-) > Also screen allows you to detach from the "Session" and logout with the > screen program still keeping track of the console output and waiting for = the > next connection to display it, which was the use I was interested > in. I don't think screen is the problem here. I have been using screen for quite some time; now I am using it to run uml on a remote machine and to avoid having to setup multiple ssh sessions. > James McMechan >=20 > -- Original Message (Snipped) >=20 > > > You don't have to if you just start UML inside screen. That gives you > the > > > main console without having to figure out what pty UML grabbed. > > > > What do you mean when you say "main console"? The screen I use to > > start the uml instance, always blocks with the message "Initializing > > stdio console driver", even after using a second screen to telnet into > > the uml instance (portal). I suppose this should be a console however, > > but never found out why it "hangs". > > > > > If you assign the other consoles and serial lines to host portals (i.e > > > 'con=3D3Dport:nnnn ssl=3D3Dport:nnnn' with a different nnnn for each > customer=3D > > ), > > > then you can have one screen attached to all of them by running=3D20 > > > 'telnet localhost nnnn' in the other screen windows. > > > > I always start the uml instance with "con=3D3Dport:${HOST_PORT}", but a= lso > > discovered some strange behaviour: when I do a "telnet localhost > > ${HOST_PORT}", the boot process proceeds --- as described in the HOWTO > > --- in the screen where I issue the telnet, but it again "stops" with > > the message "Setting the System Clock using the Hardware Clock as > > reference..."; as uml does not have a hardware clock, I disabled the > > init scripts to set the clock from the hardware clock but now the boot > > process "stops" with the message "Starting periodic command scheduler: > > cron.". Closing the telnet session and connecting it again, finally > > shows the login prompt (both with and without the hwclock stuff). This > > means that "stops" as described above, actually does not stop the uml > > instance, but rather stops the feedback to the terminal. This > > behaviour clearly resembles the problem with the "main console" > > mentioned above i.e. screen window is blocked somehow. As I did not > > find any similar posting, I must be doing something wrong. > > > > FYI: I am running uml 2.4.18.48um-1 (with a rootstrap-ped Debian woody > > image), but I also had the problem with 2.4.18.{29,37}um-1. > > > > > Jeff > > > > --=3D20 > > len...@pa... > > >=20 --=20 len...@pa... Those who do not understand Unix are condemned to reinvent it, poorly." -- Henry Spencer |