How to dual boot 2 linux partitions?
Maybe I haven't dug deep enough to find a solution for my particular problem,
but let me explain the basic story: Slackware 13.0 32-bit is installed on /dev/sda5 with lilo written to that partition. Everything works and I have a nice lilo boot menu (for a WinXP bootable partion). Recently I installed Slack 13.0 64-bit on /dev/sdb5. This also succeeded (apparently). After reboot I was presented with my old boot menu, selected the 32-bit Linux option (/dev/sda5) and after login went to /etc/lilo.conf where I entered a boot stanza for /dev/sdb5 (64-bit linux), and then ran /sbin/lilo. No errors flagged. After reboot there was a 64-bit entry in the boot menu, but when selected it led to kernel panic. Further although I can mount /dev/sdb5 from the 32-bit partition there is nothing in it except lost+found. So the current position is that I can't access my 64-bit linux partition (/dev/sdb5) to change anything in it (even boot: root=/dev/sdb5 at the boot prompt doesn't seem to work). First question is how do I obtain access to /dev/sdb5? Second question is what items do I need in the 32-bit lilo.conf boot stanza so as to be able to boot to that 64 linux partition? Your help welcome. Thanks :) PS: OK I noticed one warning when I ran lilo..... bash-3.1# lilo Warning: LBA32 addressing assumed Added Slack * Added Slack64 Added Win7 Added WinXP One warning was issued. Maybe the problem is with the 32-bit addressing? How do I get lilo to use LBA32 for the 32-bit partition (/dev/sda5) and LBA64 addressing for the 64-bit partition (/dev/sdb5)? |
At the bottom of your new lilo stanza, add this line:
Code:
boot-as = 0x80 |
Hmm, thanks Mlangdin.
Here are my linux boot stanzas: # Linux bootable partition config begins image = /boot/vmlinuz root = /dev/sda5 label = Slack read-only # Partitions should be mounted read-only for checking # Linux bootable partition config ends # Linux bootable partition config begins image = /boot/vmlinuz root = /dev/sdb5 label = Slack64 read-only # Partitions should be mounted read-only for checking boot-as = 0x80 # Linux bootable partition config ends (*****) When I run lilo I get the following error response: bash-3.1# lilo Warning: LBA32 addressing assumed Added Slack * Added Slack64 Syntax error at or above line 46 in file '/etc/lilo.conf' Line 46 is the comment line marked with (*****) |
Well, solved the lilo error with the following 64-bit boot stanza
# Linux bootable partition config begins image = /boot/vmlinuz root = /dev/sdb5 label = Slack64 read-only # Partitions should be mounted read-only for checking addappend="boot-as=0x80" # Linux bootable partition config ends However I still get kernel panic when I boot to it: "Warning: unable to open an initial console. Kernel panic - not syncing: No init found. Try passing an init." What does this mean? No initialrd? How do I fix it? Thanks again.... |
Here is what mine looks like, except for the boot-as option. I don't have a second drive. If you are using an initrd like i am, this should do the trick.
Code:
# Linux Kernel 2.6.37.6 config begins |
Thanks, Mlangdn, for your helpful posts.
I am almost there! I guess the main problem has been that the Slack 32- (/dev/sda5) and 64-bit (/dev/sdb5) installs were not properly done, in particular as regards the initial ram disks which appear to be required for both partitions. While my lilo configuration is essentially the same as yours, I shall record the installation as far I can remember it. (1) Format /dev/sda5 use ext3 fs with bootable flag. Save with fdisk. (2) Install 32-bit Slack (3) Create initrd: mkinitrd -c -k 2.6.29.6 -m ext3 -f ext3 -r /dev/sda5 (4) Create mount point for Slack64 (eg /mnt/sdb5) and include in fstab (5) Set up lilo with 32-bit and 64-bit stanzas: # Linux bootable partition config begins image = /boot/vmlinuz root = /dev/sda5 label = Slack initrd = /boot/initrd.gz append="resume=/dev/sda6" read-only # Partitions should be mounted read-only for checking # Linux bootable partition config ends # Linux bootable partition config begins image = /mnt/sdb5/boot/vmlinuz initrd = /mnt/sdb5/boot/initrd.gz root = /dev/sdb5 label = Slack64 append="root=/dev/sdb5 boot-as=0x80" read-only # Partitions should be mounted read-only for checking # Linux bootable partition config ends (5) Install LILO in current root partition /sbin/lilo. Response: bash-3.1# lilo Warning: LBA32 addressing assumed Warning: The initial RAM disk is too big to fit between the kernel and the 15M-16M memory hole. It will be loaded in the highest memory as though the configuration file specified "large-memory" and it will be assumed that the BIOS supports memory moves above 16M. Added Slack ? * Warning: The initial RAM disk is too big to fit between the kernel and the 15M-16M memory hole. It will be loaded in the highest memory as though the configuration file specified "large-memory" and it will be assumed that the BIOS supports memory moves above 16M. Added Slack64 ? Added Win7 Added WinXP 3 warnings were issued. [Presumably warnings can be fixed by recompiling the kernel] (6) Format /dev/sda5 use ext3 fs with bootable flag. Save with fdisk. (7) Reboot to Slack64 boot DVD and install (8) Make initrd: mkinitrd -c -k 2.6.33.4 -m ext3 -f ext3 -r /dev/sdb5 (9) Do NOT install lilo (10) Reboot. Both Slack (32-bit) and Slack64 (64-bit) will appear in the boot menu. There may be improvements. Suggestions welcome. One minor irritant is that both Slack and Slack64 appear in the boot menu with the U flag, even though both are marked bootable according to fdisk (and they are). Does anyone know why this is so, and how to fix it? BTW I have found another relevant thread: http://www.linuxquestions.org/questi...vector-811302/ Thanks again MLangdn :) |
All times are GMT -5. The time now is 04:17 PM. |