How to Dual Boot Puppy on VectorLinux Box loading with LILO?

Booting, installing, newbie
Post Reply
Message
Author
kcin
Posts: 102
Joined: Wed 28 Sep 2005, 14:47
Location: Oakland CA

How to Dual Boot Puppy on VectorLinux Box loading with LILO?

#1 Post by kcin »

Hello to all,

With help from this forum I just finished setting up Puppy to dual boot on my Windows Machine from the Windows Boot Loader, using GRLDR (Thanks again for that assistance)

Now I want to do almost the same thing on my dedicated Vector System, which has only Vectorlinux booting from LILO. Is there another version of GRLDR to do this? ... Or even better, is it possible to boot to Puppy directly from LILO itself?

Best Regards,

kcin

Rich
Posts: 278
Joined: Wed 04 May 2005, 19:00
Location: Middlesbrough - UK

#2 Post by Rich »

would this be running from the live CD?? or a hard disk install?

Guest

#3 Post by Guest »

This would be for a hard disk install. The cd boots all by itself with no problem.

What I want to do is iinstall Puppy to the hard drive on an ext2 partition in Vectorlinus (so I don't have to even bother with inserting the CD), and then be able to select either Vector or Puppy from Vector's LILO Menu. I don't know if I can do that straight from LILO somehow, or if I have to install something like GRLDR like I did on the Window Dual Boot System, and reference that from LILO... Either way, I have no idea whether that can even be done, much less how to do it.

I'm wondering if a linux version of GRLDR is available, and if I can use that and set it up much like the Windows dual boot, or whether there is a way to configure LILO itself to boot Puppy directly.

Regards,

kcin

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#4 Post by MU »

You should have a file /etc/lilo.conf in Vectorlinux.

Add Puppy there, take the existing entry as example.

this might work:

Code: Select all

image=/boot/vmlinuzpuppy
	label="Puppy"
	root=/dev/hda8
	initrd=/imagepuppy.gz
	append=""
	read-only
You must copy /boot/vmlinuz from the Puppy-Partition to where the vmlinuz from vectorlinux is.
You must copy /boot/image.gz from the Puppy-Partition to where the initrd.img from vectorlinux is.

/dev/hda8 must be changed to Puppys partition.

The files from Vector may be named diferent, I don't have vector...


Then run /sbin/lilo as root to update the lilo-configuration (different to grub this additional step is required).

Create a rescue-disk to boot your system before doing it, in case I gave you wrong advice, I did not use lilo since many years.

Mark

kcin
Posts: 102
Joined: Wed 28 Sep 2005, 14:47
Location: Oakland CA

#5 Post by kcin »

Thank you Mark! I'll try that and let you know what happens.

kcin

kcin
Posts: 102
Joined: Wed 28 Sep 2005, 14:47
Location: Oakland CA

Results of Attempt #1 to boot Puppy from LILO

#6 Post by kcin »

Hello Mark and all

ok, here is what happened when I tried this:

1) First I copieds Image.gz to / in Vector and renamed it to imagePUP.gz, and also copied Puppy's vmlinuz to / in Vector and renamed it vmlinuzPUP.

I also altered your code:
image=/boot/vmlinuzpuppy
label="Puppy"
root=/dev/hda8
initrd=/imagepuppy.gz
append=""
read-only
... to read:

image=/vmlinuzPUP
label= Puppy
root=/dev/hda2
initrd=/imagePUP.gz
append=""
read-only

... added this to lilo.conf, and ran /sbin/lilo to update LILO

Funny thing was... this ended up loading Puppy into RAM, but booting into Vector.

After some thought, I realized, that Puppy's root was in RAM now, not hda2, so I altered this line:

root=/dev/hda2

...to

root=/dev/ram

However, this failed with this error:
Mounting usbfs:mount Mounting none on /proc/usb/failed: No such file or directory
...Pausing for 60 seconds...
[/quote]

...so then, then looking in Vector's /dev directory, I realized Vector didn't have a "ram" device. It did however have a "ram0" device, so I substitued that instead, so now I had:

root=/dev/ram0

This got me a little further in that now, Puppy at least started to load, but it failed with this error message:

Puppy was unable to load the file usr_cram.fs. This file is the entire /usr folder, as a compressed, read-only f.s., and it's absences means that X cannot be started, but you will at least get the command prompt.

Press ENTER to continue:
..pressing ENTER gave me:
CANNOT MOUNT HOME DEVICE ( the rest ot this long message scrolls by too fast to copy)
... I then realized I hadn't copied usr_cram.fs to the HD along with image.gz and vmlinuz so I rebooted into Puppy from CD and copied it over to Vector's root.

However, it didn't help as it still was not found on bootup from LILO. After some more research on Barry's site, I found out that Puppy looks for usr_cram.fs in /mnt/home, not / (Vector's root), so I created a /mnt/home directory in Vector and moved usr_cram.fs in there, but this still did not work.

After further thought, I realized that Puppy's /mnt/home is Vector's root, so I was right to begin with as far as where I had put it, so I went back to try to read more of the quickly scrolling messages on boot...

On closer scrutiny of the boot messages (which were scrolling by almost too quickly to read) I also noticed that it appeared that "ram0" was being unmounted , so then I figured something was not ok about using "ram0" device in place of "ram" device... so then I booted into Puppy from CD and copied it's "ram"device to Vector's /dev directory, changed "root=/dev/ram0" back to "root=/dev/ram" in lilo.conf and tried it again.

It still didn't work, but this time I got a "Kernel Panic" crash and lockup with this message
VFS unable to mount root fs on 01:01
Clearly, I'm out of my depth here...

Can anyone suggest a next step?

Best Regards,

kcin

User avatar
danleff
Posts: 294
Joined: Sun 08 May 2005, 13:11
Location: Albany, NY
Contact:

#7 Post by danleff »

I don't think that you want to use the root of Vector to boot Puppy's root filesystem.

What's happening, is that you are booting and using Vector's root, not Puppy's. If hda2 is the root of Vector. The installation of Vector is a little more complicated and this would account for the errors that you are getting.

If I am not mistaken, MU suggested changing the root= variable to the partition that Puppy is on. It sounds like you are trying just to use Vector's partition for this.

If you have room on the hard drive, why not make room for Puppy and do a type 2 installation and boot to that partition using Lilo?
I love it when a plan comes together

--Hannibal Smith

GuestToo
Puppy Master
Posts: 4083
Joined: Wed 04 May 2005, 18:11

#8 Post by GuestToo »

assuming you have VL installed on hda2 (why not hda1?)

boot VL
copy vmlinuz, image.gz, and usr_cram.fs to /

that's it ... Puppy is installed

now you have to add a few lines to /etc/lilo.conf to configure the boot loader

my Grub menu.lst looks something like this:

Code: Select all

title = Puppy Linux
rootnoverify (hd0,0)
kernel /vmlinuz root=/dev/ram0 PFILE=pup001-none-262144 PHOME=hda1
initrd /image.gz
so you could add something like this to lilo.conf

Code: Select all

image=/vmlinuz
label= Puppy
root=/dev/ram0
initrd=/image.gz
append="PFILE=pup001-none-262144 PHOME=hda2"
read-only
then run lilo as root

what this does, is copies the kernel /vmlinuz (use the correct path to the file as VL sees it) to ram and executes it, and copies /image.gz (/bin, /sbin, /lib) to ram, and executes /sbin/init ... which starts Puppy

Puppy will use a pup001 file (/root, /etc, /root/.usr) on hda2, and will look for usr_cram.fs where pup001 is, and mount it

your VL partition, hda2, will be mounted as /mnt/home

you can change the size of the PFILE ... or you might be able to set it up to use VL's partition directly, but be careful if you try that, you don't want Puppy's files writing over VL's files

sometimes it works better if you put the stuff in append= after vmlinuz, like this:
image=/vmlinuz PFILE=pup001-none-262144 PHOME=hda2

noip
Posts: 93
Joined: Fri 07 Oct 2005, 00:45
Location: Sydney

#9 Post by noip »

Hi,

I wrote a detailed list of instructions on multi booting puppy and vector linux using lilo on the older forums. If you search there under "lilo" you'll find the whole lot laid out exactly.

Hope this helps.

GS.

PS.. Here's the link

http://puppy.mypunbb.com/viewtopic.php?id=15

User avatar
danleff
Posts: 294
Joined: Sun 08 May 2005, 13:11
Location: Albany, NY
Contact:

#10 Post by danleff »

Nice GuestToo! My Lilo skills are rusty.

noip, your link is dead. Did you save the how-to? It probably should go on the new forum, or on the wiki. I remember the post.
I love it when a plan comes together

--Hannibal Smith

noip
Posts: 93
Joined: Fri 07 Oct 2005, 00:45
Location: Sydney

#11 Post by noip »

Here it is, copied from the old board...


I have LILO working on a machine with:

/dev/hda1 Vector Linux
/dev/hda2 Swap
/dev/hda3 Puppy

Boot loader on MBR

In this case, LILO is installed in Vector Linux.

First:
Ensure that /dev/hda3 is mounted in the Vector Linux fstab. In my case, the entry is something on the lines of:
/dev/hda3 /mnt/linux defaults 0 2

(on second thought, you may be able to get away with just temporarily mounting the puppy partition)

Second:
copy the puppy kernel to
/boot/vmlinuz in the
puppy partition .. /dev/hda3 in my case.

Third:
Edit the lilo.conf in Vector with the Puppy section .. having the critical item:

image= /mnt/linux/boot/vmlinuz
root= /dev/hda3

WHY?

The LILO program must be able to see things from its perspective when you execute "LILO" to place the boot loader on the MBR. It must be able to understand which /boot/vmlinuz you are talking about at the time LILO is updated.

If you have
image = /boot/vmlinuz
then LILO says - that points to the Vector Linux boot directory on /dev/hda1 and the VL kernel.

If you have
image= /mnt/linux/boot/vmlinuz
then LILO says - that points to the puppy kernel on /dev/hda3 - I know this because the partition is mounted and I can see it.


Rgds

Geoff.

User avatar
danleff
Posts: 294
Joined: Sun 08 May 2005, 13:11
Location: Albany, NY
Contact:

#12 Post by danleff »

noip, do you want me to add this to the wiki? Of course, you can if you wish.
I love it when a plan comes together

--Hannibal Smith

noip
Posts: 93
Joined: Fri 07 Oct 2005, 00:45
Location: Sydney

#13 Post by noip »

Please, do, Thankyou. (although I seem to remember someone else saying they were going to do it when I originally posted it, but then it may not have happened.)

Guess I'll have to get to and learn how to use a wiki.

Thanks again.

GS

ftgs

kcin
Posts: 102
Joined: Wed 28 Sep 2005, 14:47
Location: Oakland CA

#14 Post by kcin »

danleff, guesttoo, noip, and all,

Thanks much for all your input!

I've made progress, but still have problems...

I added the string "PFILE=pup001-none-262144 PHOME=hda2"

...to the append argument as was suggested:

append = "PFILE=pup001-none-262144 PHOME=hda2"

and although I still got an error on the way, this did get Puppy to boot into the GUI. Problem was though, no mouse. It's a USB mouse, and if you recall, one of the errors I was getting had to do with the USB.

I went back and had to boot about 15 times to read the quicky scrolling error messages in bits and pieces. ( is there a way to pause that for easier reading?.. or a way to log it and retrieve it later?)

Anyway, since my mouse is usb and the usb device is failing to load, that seems to be the crux of the problem. Here is what I was able to piece together from the error messages:
(it is only partial, there are several more lines I could not get, and these I did get repeat several times with other numbers)
...
attempt to access beyond end of device
01:00 rw0 want 13290 limit 12288
reading lib/modules/2.4.29/ modules.parportmap input-output error
Failed to load usb driver module

mounting usbfs.mount failed Mounting none on proc/bus/usb failed. No such file or directory.
failed

pausing for 60 seconds

...then it boots into the GUI but with no mouse, and I don't know what else may be not loading as well.

...I thought maybe I needed to increase the size of the ramdisk since... -I thought maybe the reason that the USB module was not loading was that there was perhaps insufficient space to load all the needed modules, so I increased the "262144" in the PHOME string to "524288," and also copied pup001 to pup1 and changed that setting in lilo.conf too. ... but I was grasping at straws, not really understanding what was wrong; it had no effect.

So, does seeing these error messages give anyone any idea what is happening here?

I wonder what is the difference between how LILO is loading this stuff and how it usually loads.

The one piece of code from the grub config that I don't see duplicated in any way in the LILO version is the "rootnoverify (hd0,0)" directive. Is it possible that may have anything to do with this issue?

Best Regards

kcin

GuestToo
Puppy Master
Posts: 4083
Joined: Wed 04 May 2005, 18:11

#15 Post by GuestToo »

Grub and Lilo are slightly different

in lilo, image=/vmlinuz means "load the kernel file /vmlinuz in ram" ... /vmlinuz is where Vector Linux thinks the file is when you run the lilo command ... when lilo runs at boot, it doesn't uderstand file systems, or partitions, it only understands sectors on the hard drive ... running lilo puts the sector numbers of that particular file in the lilo boot program ... if you move vmlinuz so that it uses other sectors on the hard drive, lilo will stop working and you will have to reinstall it

grub does understand file systems, and folders, and partitions
rootnoverify (hd0,0)
kernel /vmlinuz root=/dev/ram0

means, "grub, when you boot, look on the first partition of the first drive, find the file /vmlinuz, and load in in ram" ... rootnoverify tells grub to look for files on the first partition of the first drive ... lilo is not smart enough to do this, all lilo can do is get the data from the hard drive sectors it was told to use

the difference is, lilo is referring to file names as Vector Linux sees them ... grub is referring to file names as grub will see them when grub is booting

the PHOME size is the size of the pup001 file (you can name the pup001 file anything you like) ... it is not the size of the ram drive ... i think you set the ram disk size by putting something like ramdisk_size=40960 in the append= section of lilo.conf (use the correct number, of course, that is probably not the correct size to use)

Guest

#16 Post by Guest »

guestToo,

Adding the ramdisk_size directive to the the "append" directive finally solved the problem.

The statement now reads:

append = "PFILE=pup001-none-524288 PHOME=hda ramdisk_size= 65536"


...and Puppy now boots from LILO.

I don't know if the size has to be that big... I just grabbed an even binary power of 2 that I though would be sufficient ( the machine has 256 MB ram so there is plenty).


Perhaps later, I'll adjust it downward and see what the minimum is, and post results for any interested party, but for now, I'm just glad to have solved this issue - Thanks again for all your help.

Best Regards,

kcin

User avatar
danleff
Posts: 294
Joined: Sun 08 May 2005, 13:11
Location: Albany, NY
Contact:

#17 Post by danleff »

noip, Ian did previously add your lilo instructions to the how-to wiki, located here.
I love it when a plan comes together

--Hannibal Smith

Post Reply