View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 9 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Fri Nov 04, 2005 8:06 pm 
Offline
Joined: Wed Feb 18, 2004 9:07 pm
Posts: 89
I've had bad experiences in upgrading to new releases. I know that it's my fault, due to poor hardware/mobo choices, but I've had lousy luck with every R5a release I've attempted.

While R4V5 is working fine (perfectly!) for me right now, R5A22 has released to rave reviews. I'm a tinkerer. I've got to try it out.

So...

I got it in my head that I could create a "testing" root partition. My default boot system now looks like this:
Code:
/dev/hda1     /
/dev/hda2     swap
/dev/hda3     (not mounted)
/dev/hda4     /myth
/dev/lvm      /myth/tv


(I moved /cache from /dev/hda3 to /myth to allow the use of /dev/hda3 as my alternate, testing root partition.)

I then mounted /dev/hda3, mirrored /dev/hda1 to /dev/hda3 via rsync, and edited lilo.conf to allow for a second boot option:

Code:
image=/boot/vmlinuz-2.4.25-chw
        root=/dev/hda1
        label=Linux
        initrd=/boot/initrd.gz
        read-only

image=/boot/vmlinuz-2.4.25-chw
        root=/dev/hda3
        label=mirror
        initrd=/boot/initrd.gz
        read-only



I've also modified /dev/hda3/etc/fstab to mount /dev/hda3 at /

I then issue
Code:
lilo -v
and reboot. The lilo selection menu comes up, I select mirror, and it boots. but...
Code:
root@mythbox:/ # df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/hda1              3901052   2022980   1680476  55% /
/dev/root.old             2182       342      1840  16% /initrd
/dev/hda4            181388640  40653576 140735064  23% /myth
/dev/vg/myth         490096632 247306404 242790228  51% /myth/tv


No matter what I try, I can't get the system to boot up with /dev/hda3 mounted as /

Am I overlooking something simple in my attempt to boot from /dev/hda3?

And perhaps more importantly - if I do succeed in my quest, will I be able to install R5A22 to /dev/hda3 for testing, while retaining the ability to boot R4V5 off /dev/hda1 if things don't work out?

_________________
R5Fxx

Home-Brewed Mythic Dragon Clone
200GB WD IDE /myth
2x250GB WD IDE (lvm) /myth/tv


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 3:52 am 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
I'll have a crack at this soon and post my findings :)

"/dev/vg/myth" mounted on /myth/tv

whats that all about?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 6:49 am 
Offline
Joined: Wed Feb 18, 2004 9:07 pm
Posts: 89
Quote:
"/dev/vg/myth" mounted on /myth/tv

what's that all about?


I added two 250 GB drives, used LVM to create a 500GB volume group, then mounted the vg at /myth/tv. My original 200GB drive has a 180 GB hda4 partition, mounted at /myth (the default.)

This gives me 180 GB for video storage - I also use this partition as the incremental backup device for the other computers in my house (/myth/backup). I've also now got a HUGE storage device for the livetv cache (/myth/cache) -- not that I'd ever need that much cache.

I've got some more detailed diagnostics in another post in this forum http://mysettopbox.tv/phpBB2/viewtopic.php?t=6806&highlight=

Note that with the modifications I've done, everything still works -- that is, nothing's broken. My original intent, dual boot, just isn't happening.

_________________
R5Fxx

Home-Brewed Mythic Dragon Clone
200GB WD IDE /myth
2x250GB WD IDE (lvm) /myth/tv


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 7:53 am 
Offline
Joined: Tue Sep 27, 2005 12:32 pm
Posts: 104
I THINK the problem can be that your machine boots using initrd.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 1:26 pm 
Offline
Joined: Wed Feb 18, 2004 9:07 pm
Posts: 89
I'll admit that I don't know enough about the boot process to understand what initrd is or does. I'll even admit that I've researched it (at http://www.tldp.org/LDP/Linux-Filesystem-Hierarchy/html/initrd.html for example) and I still have no clue what initrd does. I can read the words, it simply makes no sense to me.

Are you sating that there could be something hard-coded in KnoppMyth's initrd that I need to change (create a new initrd) to allow mount of root at hda3?

==========
[edit]
I just did some poking around in initrd, which is still mounted. Everything in /initrd/etc looks clean -- there's no mention of hda1 or root in there.

However...

/initrd/linuxrc contains:

Code:
mount -t /ext3 /dev/hda1 /mnt
/static/pivot_root /mnt /mnt/initrd


So... if I create another initrd, modify this file to refer to hda3, then specify this file in lilo.conf, I could have this licked. Does that look right to you?


Found instructions for building initrd: http://www.faqs.org/docs/evms/x3834.html

_________________
R5Fxx

Home-Brewed Mythic Dragon Clone
200GB WD IDE /myth
2x250GB WD IDE (lvm) /myth/tv


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 3:25 pm 
Offline
Joined: Tue Nov 08, 2005 7:31 am
Posts: 195
Location: Secret Lair
Quote:
I still have no clue what initrd does

Think of it as a virtual floppy disk to load drivers from or maybe as the kernel's "backpack". Booting is done at a very, very low level with a very small amount of code. The only disk access available asking the BIOS to read specific disk blocks into memory. Thus if you need anything that isn't built into the kernel image (like modules) you need to have a "RAM disk" image that contains it, which can be loaded by the same low level mechanism. There are too many reasons for not building the drivers directly into the kernel to go into here. It's better to have a mechanism which lets you pack the things you'll need in a seperate bundle. Part of what running lilo does is to generate the appropriate list of blocks for the kernel and RAM disk. However all of those blocks need to be in the same partition (You can't grab your backpack to get your bus pass if it's across town).


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 5:07 pm 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
If initrd is the problem, you could try removing "initrd=/boot/initrd.gz" from the mirror section in ur lilo.conf.

Or would you need to recompile the kernel without the ramdisk aswell?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 7:52 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
I just dug back through my old multi-boot setups. With /dev/hda1 as / Set up a permanent mount for /dev/hda3 on /mirror in your /etc/fstab like this:
Code:
/dev/hda1  /  ext3 defaults,errors=remount-ro  0  1
/dev/hda3  /mirror  ext3 defaults,errors=remount-ro  0  1

fix your lilo.conf to look like this:
Code:
image=/boot/vmlinuz-2.4.25-chw
        root=/dev/hda1
        label=hda1-Linux
        initrd=/boot/initrd.gz
        read-only

image=/mirror/boot/vmlinuz-2.4.25-chw
        root=/dev/hda3
        label=hda3-Linux
        initrd=/mirror/boot/initrd.gz
        read-only

Then run lilo. You should now be able to boot to the alternate image. Once you can do that, do the reverse setup. The /etc/fstab on hda3 should mount hda1 as mirror and the lilo.conf should have the files for hda1 labelled Linux coming from there, as shown here:
Code:
/dev/hda3  /  ext3 defaults,errors=remount-ro  0  1
/dev/hda1  /mirror  ext3 defaults,errors=remount-ro  0  1

Code:
image=/mirror/boot/vmlinuz-2.4.25-chw
        root=/dev/hda1
        label=hda1-Linux
        initrd=/mirror/boot/initrd.gz
        read-only

image=/boot/vmlinuz-2.4.25-chw
        root=/dev/hda3
        label=hda3-Linux
        initrd=/boot/initrd.gz
        read-only

Note that you do not need to run lilo again this setup is for the future when you may need to run lilo from this image.
BTW - As they were your labels were going to get confusing, so I'd recommend calling them "hda1-Linux" and "hda3-Linux" as shown above instead of "Linux" and "mirror".


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 14, 2005 8:39 pm 
Offline
Joined: Wed Feb 18, 2004 9:07 pm
Posts: 89
Thanks for taking the time to lay all of this out.

I'll have time this weekend to give it a go - I'll post back with my findings.

_________________
R5Fxx

Home-Brewed Mythic Dragon Clone
200GB WD IDE /myth
2x250GB WD IDE (lvm) /myth/tv


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu