To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here

http://justlinux.com/   Tue, 09-Feb-2010 17:28:15 GMT
         internet.com

Go Back   JustLinux Forums > Community Help: Check the Help Files, then come here to ask! > How I Did It!

How I Did It! Got a How-To/Tutorial/Guide you wrote? Post it here.

Reply
 
Thread Tools Search this Thread Rating: Thread Rating: 7 votes, 5.00 average. Display Modes
  #1  
Old 10-25-2004, 06:15 PM
saikee's Avatar
saikee saikee is offline
moderator
 
Join Date: Jun 2004
Location: Newcastle upon Tyne
Posts: 2,485
How can a Linux user multi boot a new additional Linux?

-------Edited 14/1/06--------------
This is a later thread I wrote that show a lazy way to multi boot with the Grub menu prepared prior to the additional Linux installations. As an example I had 20 empty partitions ready for receiving Linux shown in this thread.
-------------------------------------

Here are simple steps to add additional Linux distros to a bootable system using either Lilo or Grub.

Assumptions:-


(1) A computer already with an existing Linux ( or any number of them) loaded and has its bootloader in the MBR. Let’s assume the bootloader owner Linux reside is Partition hda6
(2) The new Linux when install, say at Partition hda7, replaces the original bootloader causing a panic to the user (instead to the kernel!).
(3) The system now boots with the new Linux in hda7 but not the previous alternatives in hda6.

Steps to restore the previous bootloader and include the new one for booting.

(a) Boot to new Linux in hda7 as usual.
(b) Drop in terminal mode, by clicking terminal or konsole
(c) Log is as the root user (“su” then follow by password)
(d) Replicate the bootloader in root partition (“grub-install /dev/hda7”)
(e) Make a new directory for mounting hda6(“mkdir /mnt/here”)
(f) Mount the previous hda6 there ( “mount /dev/hda6 /mnt/here”)
(g) Change root to hda6 (“chroot /mnt/here”). Now you are in side hda6.
(h) Use desktop to edit hda6’s /boot/grub/menu.lst to include hda7 for booting with lines

Code:
title My Linux in hda7
root (hd0,6)
chainloader +1
(i) Restore hda6’s bootloader in MBR (“grub-install /dev/hda”)
(j) Exit hda6 (“exit”)
(k) Reboot (“reboot”)

The above works if both the old hda6 and new hda7 have Grub as the bootloader.

If the old hda7 uses Lilo then the following replacement is necessary

(d) Replicate the bootloader in root partition (“lilo –b /dev/hda7”)


If the new hda6 uses Lilo then the following replacements are necessary

(h) Edit hda6’s /etc/lilo.conf to include hda7 for booting with lines

Code:
label=”Linux_hda7”
other= /dev/hda7
After /etc/lilo.conf has been saved type "lilo" to update the system.

(i) Restore hda6’s bootloader in MBR (“lilo -b /dev/hda”)



The user can recover his previous bootloader and includes the newly installed Linux in hda7 as another booting choice. That is the method I use to build up more than 20 bootable Linux distros. Lilo and Grub can be mixed together as suggested.

It should be pointed out that the current Lilo appears to have a maximum of 27 bootable entries. Grub can boot over 100 systems.
__________________
Linux user started Jun 2004 - No. 361921
Using a Linux live CD to clone XP
To install Linux and keep Windows MBR untouched
Adding extra Linux & Doing it in a lazy way
A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
Just cloning tips Just booting tips A collection of booting tips

Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

Last edited by saikee; 01-14-2006 at 09:59 PM.
Reply With Quote
  #2  
Old 01-27-2005, 03:06 PM
supertux99 supertux99 is offline
Junior Grasshopper
 
Join Date: Jan 2005
Posts: 2
Question grub-install

Hi there! i really liked this post and decided i'd use this method to try out FC3 and ubuntu (i've been using suse 9.2, my first distro, for the last three weeks).

having installed fc3 alright, i'm using the terminal from within gnome. but when i enter the grub-install line, bash returns that the command is not known. am i supposed to be doing this in the grub shell, or do i just need to find and install the grub-install command?

i'd appreciate any help at all.


cheers
Reply With Quote
  #3  
Old 02-06-2005, 05:01 PM
saikee's Avatar
saikee saikee is offline
moderator
 
Join Date: Jun 2004
Location: Newcastle upon Tyne
Posts: 2,485
Sorry I have been away for 6 to 7 weeks and back to the country only yesterday.

I think "grub-install" needs to be issued as the super-user (see Step c). You can try just the command "grub" too.
__________________
Linux user started Jun 2004 - No. 361921
Using a Linux live CD to clone XP
To install Linux and keep Windows MBR untouched
Adding extra Linux & Doing it in a lazy way
A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
Just cloning tips Just booting tips A collection of booting tips

Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"
Reply With Quote
  #4  
Old 02-14-2005, 11:18 AM
supertux99 supertux99 is offline
Junior Grasshopper
 
Join Date: Jan 2005
Posts: 2
thanks for replying.

I managed to figure it out - the command wasn't installed in a place that in my PATH. (that's the right term, yeah?) anyway, i just gave the absolute reference of the command and it worked. sorted.

by the way, i had another problem for a while. apparently some distros (those with 2.6 kernels, maybe?) don't work with the chainloader +1 line. they need an initrd line instead. or something. i'll check and post what my menu.lst looks like.

thanks.

--

"is it a bird? is it a plane? no, its... its... a penguin in a cape???"
Reply With Quote
  #5  
Old 02-14-2005, 01:48 PM
retsaw retsaw is offline
Registered User
 
Join Date: Apr 2003
Location: UK
Posts: 1,162
Quote:
Originally posted by supertux99
by the way, i had another problem for a while. apparently some distros (those with 2.6 kernels, maybe?) don't work with the chainloader +1 line. they need an initrd line instead. or something. i'll check and post what my menu.lst looks like.
The chainloader +1 option is for loading other bootloaders like lilo, another copy of grub or the bootloader for windows. If another distro installs a bootloader in it's root partition you can point grub to that bootloader and load it using chainloader or you could just boot it directly by using the kernel and initrd options.
Reply With Quote
  #6  
Old 02-14-2005, 08:21 PM
saikee's Avatar
saikee saikee is offline
moderator
 
Join Date: Jun 2004
Location: Newcastle upon Tyne
Posts: 2,485
I second retsaw.

Two methods to boot a Linux:-

(1) directly by calling the kernel and initrd.

(2) indirectly by chainloading using "chainloader +1" in Grub

With the first method one has to specify the exact file names of kernel and initrd.

The second method is a lazy alternative but it requires a bootloader installed in the root partition of every distro. It is the same method Linux boot Windows.

I like second method because it is generic, simple and has never failed me yet. It also retains the boot menu of every distro which could be a nuisance if you don't want to see it everytime you use the distro. The menu can be hidden of course by varying the display time. However it is fun to jump from menu to menu and boot the Linux and Windows from anywhere one wishes.
__________________
Linux user started Jun 2004 - No. 361921
Using a Linux live CD to clone XP
To install Linux and keep Windows MBR untouched
Adding extra Linux & Doing it in a lazy way
A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
Just cloning tips Just booting tips A collection of booting tips

Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"
Reply With Quote
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 01:28 PM.

Help File Library
Security
Filesystems
Tools
Soundcards
Hardware
More



internet.com
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers




internet.commerce
Be a Commerce Partner












Linux is a trademark of Linus Torvalds.

Acceptable Use Policy


The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers

Powered by vBulletin® Version 3.7.5
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.