PDA

View Full Version : Knoppix under Windows - help Linux appeal to wider audience



chris-uk
12-27-2004, 10:27 PM
http://home.btconnect.com/chrisandcarolyn/santaspecial.pngis unretouched, and is what happens when MS Windows 'autoruns' my modified games-knoppix CD. The same CD boots the way a Knoppix always does, as well.
This is done by adding the contents of http://home.btconnect.com/chrisandcarolyn/qemu-knoppix.zip to the files from the games-knoppix CD from http://games-knoppix.unix-ag.uni-kl.de/, and running the 'mkisofs' command to complete the remaster.
The same works for the proper 3.7 Knoppix.
:D
http://home.btconnect.com/chrisandcarolyn/santaspecial.png

chris-uk
12-27-2004, 10:39 PM
My sources for this are
'qemu' http://fabrice.bellard.free.fr/qemu/ leading to http://www.h7.dion.ne.jp/~qemu-win/
Boot diskette image from Morphix-game 0.4.1 http://www.morphix.org/

and you have to 'mount -o loop' the boot diskette to rebuild it to include the kernel and ramdisk (and replace the 'logo.16' file with something more reasonable if you know how, etc) .

I don't have enough web space (at least, not enough that could survive someone downloading an iso) to make the whole image available. If you can, please do so.

It's possible to do the same for Knoppix 3.7 ; actually, the 'autorun' file in the zip is really for this one, it shows the index.html as well as playing the Knoppix. For me, this overflowed the capacity of the CD, so I took off the 2.6 kernel and initrd, and things fitted.

Virtual networking works properly, I think, so web browsing with a virtual Konqueror is OK.

chris-uk
12-28-2004, 10:06 PM
I used this command to rebuild the 'iso'

#!/bin/bash
mkisofs -pad -l -r -J -v -V "KNOPPIX" -b \
boot/isolinux/isolinux.bin -c \
boot/isolinux/boot.cat -no-emul-boot \
-boot-load-size 4 -boot-info-table -hide-rr-moved \
-o knx/nick.iso files

where 'files' was the directory containing the unzipped files plus all the files and directories copied from the original CD.

aay
12-30-2004, 05:33 AM
Chris,

What's the performance like with this? I got Damn Small Linux running within a Linux install using qemu, but it was quite processor intensive and wasn't of much practical use for me. I'm just wondering how this compares.

Thanks

Adam

chris-uk
12-31-2004, 08:45 PM
On my 4-way hyperthreaded 3GHz XEON ? Pretty good.

Seriously, OK for demo/learning use. 'xsnow' not too bad, on my 1.8GHz uniprocessor. You can run it with a less-pretty window manager than KDE and it goes faster.

chris-uk
01-03-2005, 11:37 AM
The boot-under-Windows ISO and its md5sum are here http://www.ibiblio.org/pub/linux/Incoming/ at the moment.

Particle
01-07-2005, 05:00 AM
This is definately interesting if nothing else. It runs pretty good on my 2.5GHz AMD after I kill xsnow. The only thing is that the emulation is very processor intensive and causes loading even the simplest of programs (like Mozilla) to take a small eon. It's still very cool though =]

chris-uk
01-09-2005, 09:35 AM
I have put revised kits at http://home.btconnect.com/chrisandcarolyn/gk3701.zip and http://home.btconnect.com/chrisandcarolyn/gk3702.zip for the St Nicholas' Day and Three Kings' Day editions respectively.

The boot sequence is cleaned up; otherwise pretty much the same as before.

Enjoy ! :D

chris-uk
01-12-2005, 12:57 AM
Here's Knoppix 3.7 running under Windows
http://home.btconnect.com/chrisandcarolyn/k37qemu.png
and here's the kit to do it http://home.btconnect.com/chrisandcarolyn/k37qkit.zip .
I had to take the Linux 2.6 kernel and ramdisk off the iso, because otherwise there was then too much to fit on a CD.
A DVD would have worked, no problem. :D

chris-uk
01-29-2005, 08:45 AM
I'm a little short of web space. If anyone would like to take the 'qemu kits' from http://home.btconnect.com/chrisandcarolyn/ and host them somewhere proper, that would be fine by me. (The kit for GamesKnoppix 3.7-0.2 is gone already. It's easy enough to rebuild from the 3.7-0.1 version)

chris-uk
02-04-2005, 11:34 PM
There's a torrent for 'UNESCO Linux for Windows' (freeduc-cd 1.4 from http://www.ofset.org/ on SourceForge, with a QEMU 0.6.1-2 kit added) available at http://linuxtracker.org/torrents-details.php?id=14 :D

chris-uk
02-06-2005, 12:20 AM
GamesKnoppix St. Nicholas' Day with Windows kit is at http://linuxtracker.org/torrents-details.php?id=36

UNESCO Linux with Windows kit (freeduc-cd 1.4 from http://www.ofset.org) is at http://linuxtracker.org/torrents-details.php?id=14

:D

pureone
02-07-2005, 02:41 PM
none of the linux tracker links work :(

i would like to download a iso of this "knoppix under windows" just to see what its like. i would like to know how much cpu it uses as well.

chris-uk
02-11-2005, 12:27 AM
Torrents should all be there now; http://home.btconnect.com/chrisandcarolyn/torrents/ has a list of what I put up, or you could visit http://linuxtracker.org/ and look for what you want.

It uses lots of CPU, and runs quite slowly (depending on how fast a machine you have). But for many purposes it is tolerable. Most of the science lessons on 'knosciences' are not cpu intensive at all; but the image rendering on celestia leaves a little to be desired.
And it's quicker to get a 'ssh' on a windows box by putting one of these CDs in and bringing up an xterm and using ssh, rather than installing cygwin or putty. And has the benefit that on the far end, you can 'xterm' and it will pop up a window back through the ssh secure tunnel. One up on putty.

"Try before you buy" is not really the word; more "look before you leap". Definitely good enough for looking.

If you want to build them yourself, take a look at http://www.ofset.org:8080/freeduc-doc/11 for some pointers

Doublezz
02-23-2005, 03:35 PM
Chris,

Thanks for putting up the torrent files :) , I downloaded the Knoppix 3.7 qemu .iso file and burned it to a CD. The file seems to be fine but qemu does not boot under windows, only a normal knoppix bootup at powerup worked. I tried it first on a Win98 s/e 256K RAM P4 machine without any response, even double clicking qemu-knoppix.bat as well as trying to manually enter the command lines indicated and I only got error messages. I then tried it on a WinXP Pro 256K RAM P4 box and got index.html but then a system error shows up and that was as far as I could go. Again no luck with the .bat files and trying to manually enter the command lines for qemu.exe only opened up a window with more error messages :( . Without wanting to sit down yet to read all the doc for qemu ... is there something obvious I am doing wrong here? Does is sound like my iso download was bad? Any suggestions would be greatly appreciated.

Doublezz - puzzled!

chris-uk
02-23-2005, 05:32 PM
What drive letter is your CD ? There is some code in qemu*/qemu-knoppix.bat which needs to find the CD drive letter. and only works if the drive letter is D,E,F,G,H,I,J, or K (I think. Can't check right now). If that's the problem, copy all the files from the CD to a directory; make the obvious change to the 'bat' file; and make a new CD. (Or issue a 'subst' command. Gave me quite a surprise when I did that by accident.) The new CD should 'boot' under Windows but not 'real'; to do the 'dual-capable' one you need the right 'mkisofs' command. Knoppix documentation will show it.

Another possibility is that you have an old version of Windows. I have seen success with XP, but failure with ME and 95. I have not tried others. I presume it's something about the compilers that were used to build 'qemu' producing code that will only work on newer versions of Windows. Mind you, "Got to upgrade to XP in order to run Linux" is not going to get much sympathy :D

Kanotix-for-Windows is constructed differently, and should 'boot' under Windows whatever drive letter you use. You can derive a Kanotix which boots 'real' by looking for the '.iso' file in the root directory of the CD. I like Kanotix.

If that doesn't fix it, copy the files from the ISO to disk and poke around with the QEMU documentation (in the qemu* directory, or qemu's web site) and adjust things until they run. If all else fails, there's always the source ... though I didn't need to recompile anything to make these isos. Just packaging. Honest. QEMU is good.

Cut and paste the commands and error messages here. Maybe I'll be able to help,or someone else will be able to help both of us.

If you can leave BitTorrent connected, it helps me. I have only 32 kbyte/second of uplink bandwidth, and rather a lot of ISOs to seed.

http://home.btconnect.com/chrisandcarolyn/kanotix-for-windows.png

chris-uk
02-23-2005, 05:38 PM
I've set up 'qemu' so that it tries to emulate a machine with 1 Gbyte of memory. Your Windows box needs to be able to allocate a 'swap' file of at least 1 Gbyte in size, for this to work. (Unless you have that much RAM, of course). If you can't allow that much swap, you'll need to change the parameter in the 'qemu' command ... you can drop it down to 128Mbyte or so ... but on the principle that it's faster for Windows to swap things in from disk, rather than qemu and knoppix swap them in from CD, the larger emulated memory the better.

Doublezz
02-28-2005, 07:28 PM
First I must thank Chris-UK for his help and also a CoMike at http://www.dad-answers.com/qemu-forum/viewtopic.php?t=112 for his post or I would never have succeeded ... however I must say it was due more good luck than to thorough detailed instructions that weren't provided for real QEMU newbies like myself either in the QEMU on-line documentation or the forum posts.

Chris' Knoppix_qemu iso torrent that I downloaded and tried everywhich way but up would not work for me. Maybe bad data ??? or something else ... whatever I next tried to read the online QEMU documentation which was even less helpful. It was only with some luck and a post by CoMike above that I got Knoppix under windows to boot up in qemu. Here is what I did for anyone elses interest ...

My goal now to get a simple knoppix cd working under Qemu on my Win98 machine. I first downloaded the windows installer for qemu from http://ftp.club-internet.fr/mirrors/ftp.freeoszoo.org//qemu/win32/release/

After pouring through the online qemu documentation at http://fabrice.bellard.free.fr/qemu/user-doc.html and trying a lot of things with little success, I read that CoMike said that you must "create a hard disk image with qemu-img". But how ... it would have been helpful if he had given a command line without requiring us newbies to read the "c:\<qemu directory>\qemu-img.exe help" to find out. To CoMikes credit, he told us we needed to do this whereas the Qemu on-line documentation at http://fabrice.bellard.free.fr/qemu/qemu-doc.html did not seem to explain this at all!

Trying now to get a Knoppix v3.7 iso image to load in qemu ... and since the KNOPPIX_V3.7-2004-12-08-EN.iso being 700MB in size I created the following knoppix.img in my qemu directory at the DOS prompt:
c:\<qemu directory>\qemu-img.exe create knoppix.img 800M
(where the <qemu directory> is the local qemu folder on my c drive. I had no idea what size to use so I made it a little bigger than my iso file size)

The next problem was discovering that apparently on Windows one cannot load a Live-CD into QEMU. (I say discover since CoMike indicated this in his last post (see above link) though Chris-UK will no doubt dispute this. I wasted a lot of energy trying to get my LIVE CD to load into QEMU. Nowhere did the on-line documentation indicate that this was not possible. In fact Chris-UK indicates that he not only did this but also has provided us with an online torrent of a remastered Knoppix Live CD which he says will boot automatically into QEMU under windows. I downloaded his iso, burned it to a CD and was unable to get it to work at all. (If you want to try it go to http://home.btconnect.com/chrisandcarolyn/torrents/ to download his CD) I wasted a lot of time on not getting that to work. Though I do not doubt it may indeed work, there is little good documentation that explains thoroughly how, or I am simply missing some obvious insight.

Anyway I was playing around with CoMike's sample command line and by accident had the KNOPPIX_V3.7-2004-12-08-EN.iso in my <qemu directory> (I had tried it I don't know how many times without the iso in my <qemu directory> without success as nobody told me this is where I must put the iso image), when the following line suddenly worked :-) !!!! at my DOS prompt:
c:\<qemu directory>\qemu.exe -L bios -hda knoppix.img -cdrom KNOPPIX_V3.7-2004-12-08-EN.iso -boot d

While ecstatically happy ... I was trying to understand the command line
Why is "-L bios" not documented in the Qemu on-line documentation ???? as elsewhere I had seen examples of "-L ." and so on that just didn't work for me. Furthermore why is the "-cdrom" argument not "-hda". Again I could not find answers to this in the online doc. Only CoMike used this example. Like a real dummy I thought this meant the iso-image-file was to be loaded from a cdrom. This is not the case as I discovered by removing the CDROM during the Qemu bootup sequences. Furthermore while the online doc does mention the "-boot d" argument, it does not indicate this is to load a CDROM iso under windows ... in fact the on-line doc says almost nothing about loading anything under Windows. To be fair the Qemu site does say that Qemu under windows is in extreme alpha testing stage ... so I shouldn't expect documentation for this but I would be nice to know this instead of spending hours reading the documentation only to find '-cdrom file" in a brief line that seems to indicate where to find a <disk-image-file> rather than a <iso-image-file> as CoMike indicated.

Anyway the upshot is that when giving advice like CoMike's suggested commands:
qemu.exe -L [biospath] -hda [disk-image-file] -cdrom [iso-image-file] -boot d
Example:
qemu.exe -L bios -hda susehd.img -cdrom suse.iso -boot d

... it would really be nice to explain the obvious for the benefit of dummies like myself who spent lots of time trying to interpret it with many failed attempts. For instance what is the <biospath> <disk-image-file> <iso-image-file>, its purpose ... location ... etc. so that unnecessary confusion and wasted time is avoided. I thank both Chris-UK and CoMike for all their help ... even though writing for dummies like myself :-) is not an easy task for anyone who assumes the obvious is indeed obvious. Perhaps I have also succumbed in someway to this error in my own post ... let me know if I have utterly confused anyone and not explained all my steps clearly.

I will add that while the whole exercise was frustrating ... when I did get it working ... the ecstasy quickly gave way to dissappointment when I learned that under windows QEMU emulates at 5-10 times slower than normal use which on my machine was virtually useless while waiting forever just to load and to execute commands. The QEMU accelorator technology http://fabrice.bellard.free.fr/qemu/qemu-accel.html which drops the speed loss to 1-2 times isn't ready for Windows yet :-(

Doublezz.

chris-uk
03-01-2005, 07:00 PM
There's some problems I'm aware of
1) If you have rather a lot of devices, then the sequence at the beginning of qemu*/qemu-knoppix.bat won't find your CD and things won't work. I'm not a Windows programmer;if someone could take a look and come up with a better way, please post it here.
2) If your machine can't make 1 GB of swap space available, things won't work. It is possble to reduce the size requirement, but then you get slower speed. Again look in the qemu*/qemu-knoppix.bat .
3) I have found it to work on WindowsXP, and not work on Windows95. Others have said it does not work on Windows ME. Looks like we have a 'mixed' result on Windows 98. Don't know why, possibly how 'qemu' is built.

QEMU can boot in 2 modes ...
1) You get it to boot a 'boot diskette' or 'boot cd', and then run the files off the CD.
2) You get it to boot a 700MB 'boot CD' iso file.

Mode (1) is needed to construct a CD which can boot 'real' and 'virtual'; this is how I left the Knoppix37-for-Windows set up. It looks like you converted things to mode (2), fine, but you get a CD which only 'boots' under Windows. Or an ISO file which runs Linux under Windows without a CD, which can be useful too.

I take the point about speed. It's enough for some purposes ... like learning, running an 'xterm' and a 'ssh', NFS-mounting and using an editor. And as PCs get faster, it will get faster too.

Sorry about how long it takes to download. My broadband is going flat-out (11 CDs and a DVD ... the DVD requesters know it will take the best part of a week, but at least they get a Live Linux DVD at the end of it even if the 'Linux-under-Windows' is slow)

If you want to make a better CD, or reconnect to the 'torrent' so that others can download it faster, that's fine too. I'd say 'thanks' for either ...

You'd probably get thanks for writing better documentation for QEMU, as well :D

Chris.