PDA

View Full Version : 3.4/2.6.6 Poor Man's (to/fromhd) install; boot with USB?



j.drake
07-08-2004, 04:41 PM
I was waiting for a new release to do a debian hd install, but got impatient, so I figured I'd at least do a poor man's install in the meantime. Trouble is, that 3.4 apparently boots in a different fashion, so probably 85% or more of the information I get from the WIKI or by searching is absolutely worthless for 3.4. As far as I can tell, you can totally disregard any advice or instructions written prior to May 2004, when 3.4 was released.

Since there may be others interested in this, I'm going to summarize the process in the next five paragraphs. For those of you willing to help me with my problem, skip the next five paragraphs. I'll tell you when to stop scrolling.

For those who haven't looked into this, a poor man's install is pretty much the same as running off of a live CD, but it's faster, and potentially more convenient, plus, it frees up your CD or DVD drive for other things, such as burning a disk - can't do that with live CD unless you have another drive. Of course you still have to do a persistent home (PH) and save your configuration in order to install applications or keep your printer definition between sessions, but that's easy. Obviously, a HD install is better, but some people aren't ready to take on the hassle of debugging a HD install (even some very experienced linux users are spending countless hours on this forum looking to patch one problem or another), and, in my case, I share my home PC with a spouse who cannot understand the "necessity" of "jacking around" with linux in the first place, when Windows does everything we really need, especially if LILO hoses the MBR, and we can't get into the apps she needs in Windows while I fumble around looking for a fix. But what really persuaded me, was that I was reading about Klik, and read that probono, himself, uses a "poor man's" install. I figured that if he can do what he does with a PMI, it certainly won't limit my sorry butt. So, for now, I'm running off of a HD image of 3.4 2004-05-17, and booting with the CD.

There is no necessity to partition your media, but I had partitions left over from a dual boot of Mandrake on a second HD, including a swap partition, an ext2 partition that I was using for my persistent home (PH), and a FAT32 partition that I use for data, so that I can access data from either Knoppix or Windows. For anyone interested, the Debian site has a great tutorial on partitioning. http://www.debian.org/releases/stable/i386/ch-partitioning.en.html You could even do this on something other than a HD, if it's large enough, so once 1 gig thumbdrives drop in price you could conceivably carry your whole Knoppix system, installed apps and data in your pocket to use in any PC you encounter.

Think about where you want your persistent home to be, and whether you want it as a file or a partition, and whether you want to save your poor man's to the same partition as your PH. The reason for this is that if you put your PH as a partition, the setup will format that partition, so it's pointless to install Knoppix to that location before you set up your PH. If you don't want to partition, just save your PH as a file wherever you like. Running Knoppix off of CD, click the penguin icon on the toolbar, and click Configure. From there, you can see the links to set up a persistent home, and to save your configuration. Do the PH now (then the save configuration if you want), log off and restart.

Boot the CD with whatever cheatcodes you use, but include the following cheatcode as well (I'll use hdb5 as the example for where I want the HD install located - NOTE: this is NOT THE SAME THING as the ISO file you downloaded, but you can put it in the same location if you wish): "tohd=/dev/hdb5/". So, if you created your persistent home at the hdb5 partition, your boot might look like this: "knoppix26 home=/dev/hdb5 myconfig=scan tohd=/dev/hdb5", or if you saved your PH as a file and didn't partition, it might be: "knoppix26 home=scan myconfig=scan tohd=/dev/hdb5 The boot process will copy the image there and continue booting off the CD. Check to make sure that your configuration was saved and that your persistent home set up OK. If not, try setting them up again now. If you want to create boot floppies now (what's the point - it's slower than booting from CD, and you have a CD anyway,right?) you can do so from the same penguin icon on the toolbar. Two floppies are needed. Log off and restart.

This time, you want to restart and append the cheatcode "fromhd=/dev/hdb5". For example, "knoppix26 home=scan myconfig=scan fromhd=/dev/hdb5". It should now be a lot faster, and you can remove the CD until the next time you boot.

OK, Here's where I need help.


I would like to do the following:

Phase 1: I would like to boot from a USB key, in my case, it's /dev/sda1/. There is a lot of info on the WIKI and this forum about doing that with previous versions, but I couldn't find anything relevant to version 3.4. I think bootfloppies are pointless.

Phase 2: I would like to integrate my cheatcodes into this boot image if possible. The idea being that if I want Windows running, I simply leave out the USB key and boot with the stock Windows XP bootloader. When I want Knoppix, I simply plug in the USB key, reboot, go get a beer, and when I come back from the kitchen, my knoppix 3.4/2.6 desktop is up and
waiting for me, printer file installed and apps in my PH available to me. IOW, I want to integrate the following cheatcode line"knoppix26 home=/dev/hdb5 myconfig=scan bootfrom=/dev/hdb5".

Phase 3: When I can afford a 1 GB USB thumbdrive or larger (probably much larger), I want to integrate the Knoppix image, PH, configuration file and data into the thumbdrive as well, so that I can have access to my entire system, apps, preferences and data available to me from any x86 PC I can find with a USB port.

If you guys can help me with one or more of these issues, I'll be happy to update the WIKI with all of this, so that new users will have something comprehensive to work from in setting this up

TIA,

jd

j.drake
07-09-2004, 04:04 PM
Hey, this post on another thread looks promising

http://www.knoppix.net/forum/viewtopic.php?p=53131#53131

Any other ideas?

Eco2geek, if you're tuning in, I'm not sure I understand . . . :?

Thanks for any help

jd

c123
07-10-2004, 02:28 PM
I would like to do the following:

Phase 1: I would like to boot from a USB key, in my case, it's /dev/sda1/. There is a lot of info on the WIKI and this forum about doing that with previous versions, but I couldn't find anything relevant to version 3.4. I think bootfloppies are pointless.
If your BIOS allows you to boot from USB (more recent BIOSes do, mine don't) then you should be OK. If not, you will either have to use a bootloader (lilo/grub etc) or use the CD to boot.



Phase 2: I would like to integrate my cheatcodes into this boot image if possible. The idea being that if I want Windows running, I simply leave out the USB key and boot with the stock Windows XP bootloader. When I want Knoppix, I simply plug in the USB key, reboot, go get a beer, and when I come back from the kitchen, my knoppix 3.4/2.6 desktop is up and
waiting for me, printer file installed and apps in my PH available to me. IOW, I want to integrate the following cheatcode line"knoppix26 home=/dev/hdb5 myconfig=scan bootfrom=/dev/hdb5".
A while agao I installed Knoppix to HD, and installed lilo. I confgiured it so that if I did not choose otherwise, Windows XP would auto load (the default was to auto load Linux, but I share a computer with my girlfriend who also prefers something "that just works", this for her = Windows).
Anyway, what you want is possible AFAIK, but first you have to answer question 1 - can you boot from USB or not?



Phase 3: When I can afford a 1 GB USB thumbdrive or larger (probably much larger), I want to integrate the Knoppix image, PH, configuration file and data into the thumbdrive as well, so that I can have access to my entire system, apps, preferences and data available to me from any x86 PC I can find with a USB port.
You will only be able to do this on newer PCs that support booting from USB, and only if you have access to the BIOS. Otherwise, to do what you want to do you'll have to boot with a CD (using a "bootfrom" argument, or booting to run level 2 and manually pivoting the root).



If you guys can help me with one or more of these issues, I'll be happy to update the WIKI with all of this, so that new users will have something comprehensive to work from in setting this up

TIA,

jd
If I had morte time I too would have a bash at the wiki, but alas...

FWIW I use Knoppix on a semi-broken laptop (no internal HDD) connected to a firewire hard drive, so I've looked into this booting thing (but my knowledge is pretty specific/limited).

HTH

p.s. consider checking out the knoppix mailing list, info on there is p[retty up-to-date.

j.drake
07-11-2004, 01:05 AM
Thanks, c123. My BIOS definitely allows booting from USB- BIOS considers it to be another "hard drive", so the boot order is currently:

1. Floppy

2. CDs
a. DVD reader
b. DVD+R/RW

3. HDs
a. USB key, [sda1/FAT32]
b. hda, including C:[hda2/NTFS] and D:[hda1/FAT32](factory recovery partition only)
c. hdb, including G:[hdb1/FAT32], [hdb5/ext2], [hdb6/linux swap]

So the USB is queued up to boot before Windows (C:). In fact, I tried to follow the directions for a debian loader with syslinux (d-i.pascal.at), but it didn't work, so I have to take out the USB if I want to boot Windows, or I get a Debian boot error and it kernel panics all over my ass (I've since deleted those files). No doubt it's possible, as the method of doing a pre-version 3.4 USB poor man's is well documented. Problem is that version 3.4 and beyond boots in a different fashion, which is why the boot floppy script now creates 2 boot floppies instead of one, and the old process doesn't work any more (something about 3.4 lacking the boot.img, mkfloppy and rawrite2.exe files on the 3.4 CD, IIRC). I think I read that 3.4 uses isolinux.

jd

probono
08-08-2004, 11:55 PM
Hi j.drake,
I read with pleasure that you want to run a poor man's install. I use mine for about half a year now exclusively as my main system and since hat have had exactly zero hassle with the OS any more :-) Using a persistent home, I have customized every aspect of the OS you can imagine. I can absolutely recommend it, especially if you like to play around with the system and with unknown software a lot (as I like to do).
As for the boot, why don't you consider a boot loader? I prefer GRUB, you can set it up so that it boots Windows automatically after 1 second if you don't press a key at the boot. Also, it's extremely easy in GRUB to append the kernel options.
I gave up on booting USB devices, probably my hardware is too old.
probono

j.drake
08-09-2004, 09:17 PM
Well, like I said, it was your experience that ultimately persuaded me. With it and what you've done with Klik, I'm quite satisfied.

Have to admit, though, I am curious about APT. OTOH, if serverside Klik is widely adopted, I can see very little advantage in a HD install, IMO

Thanks again,
jd

sicks
08-29-2004, 07:51 AM
So can anybody give me some tips on how to boot from the usb keydrive? I got my whole poormans install w/ persistant home up and runnning, i'd rather just carry around a usb keydrive instead of a cd to boot from.