LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-22-2011, 06:49 AM   #1
wootletootle
Member
 
Registered: Jul 2002
Location: New Zealand
Distribution: slackware
Posts: 81

Rep: Reputation: 15
Smile 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)?

Last edited by wootletootle; 04-22-2011 at 06:58 AM.
 
Old 04-22-2011, 06:56 AM   #2
mlangdn
Senior Member
 
Registered: Mar 2005
Location: Kentucky
Distribution: Slackware64-current
Posts: 1,845

Rep: Reputation: 452Reputation: 452Reputation: 452Reputation: 452Reputation: 452
At the bottom of your new lilo stanza, add this line:

Code:
boot-as = 0x80
Re-run lilo
 
Old 04-22-2011, 07:07 AM   #3
wootletootle
Member
 
Registered: Jul 2002
Location: New Zealand
Distribution: slackware
Posts: 81

Original Poster
Rep: Reputation: 15
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 (*****)
 
Old 04-22-2011, 07:33 AM   #4
wootletootle
Member
 
Registered: Jul 2002
Location: New Zealand
Distribution: slackware
Posts: 81

Original Poster
Rep: Reputation: 15
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....
 
Old 04-22-2011, 09:30 AM   #5
mlangdn
Senior Member
 
Registered: Mar 2005
Location: Kentucky
Distribution: Slackware64-current
Posts: 1,845

Rep: Reputation: 452Reputation: 452Reputation: 452Reputation: 452Reputation: 452
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
image = /boot/vmlinuz-generic-2.6.37.6
initrd = /boot/initrd.gz
  label = Slackware
  root = /dev/sda7
  read-only
# Linux Kernel 2.6.37.6 config ends
# Linux Kernel for Slackware64-current begins
image = /mnt/Slackware/boot/vmlinuz-generic-2.6.37.6
  initrd = /mnt/Slackware/boot/initrd.gz
  root = /dev/sda5
  label = SlackTest
  read-only
# Linux Kernel for Slackware64-current ends
 
1 members found this post helpful.
Old 04-25-2011, 03:59 AM   #6
wootletootle
Member
 
Registered: Jul 2002
Location: New Zealand
Distribution: slackware
Posts: 81

Original Poster
Rep: Reputation: 15
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

Last edited by wootletootle; 04-25-2011 at 06:40 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] How to dual boot Linux (CentOS 5.3) and Windows 7 on 2 partitions. purerage34 Linux - Newbie 7 01-14-2010 12:52 AM
[SOLVED] How to restore XP partitions after removing Linux from dual boot? lupgaru Linux - Software 4 12-31-2009 08:31 AM
Solved: Dual boot, deleted /boot and all linux partitions, system boots to grub> cuco76 Linux - Software 0 01-06-2009 05:27 PM
Setting up dual linux boot partitions - How do I? gcebulka Red Hat 1 12-12-2005 04:13 PM
Partitions for Dual Boot XP/Linux? brucewbrannan Linux - Newbie 2 05-12-2003 10:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:27 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration