LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-06-2007, 02:27 PM   #1
creon
LQ Newbie
 
Registered: May 2007
Posts: 18

Rep: Reputation: 0
how to boot fedora from usb hdd - complicated


Hello,
I know there are a lot of stuff on the internet on this, and i tried all of them. But my situation is a little more complicated. I havewindows xp and fedora core 6 running on my pc and i installed fedora 7 on my usb-hdd (packard bell-500G). There are 2 windows and 3 linux partitions on the local hdd and 3 linux partitions on the usb -hdd. Here is how my fdisk -l looks like:

[root@localhost ~]# fdisk -l

Disk /dev/hda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 1657 13309821 7 HPFS/NTFS
/dev/hda2 1658 1670 104422+ 83 Linux
/dev/hda3 3188 9728 52540582+ f W95 Ext'd (LBA)
/dev/hda4 1671 3187 12185302+ 83 Linux
/dev/hda5 3188 9728 52540551 7 HPFS/NTFS

Partition table entries are not in disk order

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 3200 25599577+ 83 Linux
/dev/sda3 3201 3331 1052257+ 82 Linux swap / Solaris

I used the instructions on http://www.simonf.com/usb/ to create custom initrd called usbinitrd.img. And configured my grub.conf like this:

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd1,0)
# kernel /vmlinuz-version ro root=/dev/sdb2
# initrd /initrd-version.img
#boot=/dev/sdb1
default=0
timeout=5
splashimage=(hd0,1)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.21-1.3194.fc7)
root (hd0,1)
kernel /vmlinuz-2.6.21-1.3194.fc7 ro root=LABEL=/1 rhgb quiet
initrd /usbinitrd.img

I then edit my bios settings to boot from usb hdd and reboot the pc. İt counts memory and then stucks at the screen just before loading grub. It writes "GRUB" and there is a flashing cursor but grub doesnt start. Please tell me what to do about it. Thanx.
 
Old 06-06-2007, 02:43 PM   #2
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
You can use the same /boot as you used for Fedora 6. Just copy the necessary files to that directory, and edit the grub.conf file to include a Fedora 7 entry.
 
Old 06-06-2007, 02:50 PM   #3
creon
LQ Newbie
 
Registered: May 2007
Posts: 18

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by forrestt
You can use the same /boot as you used for Fedora 6. Just copy the necessary files to that directory, and edit the grub.conf file to include a Fedora 7 entry.
thnx for the reply. sorry i'm quiet new to the stuff , i didnt really understand, can you explain how to do that? how will i use the same boot? which files are necessary? what must grub.conf look like then?

Last edited by creon; 06-06-2007 at 02:53 PM.
 
Old 06-06-2007, 03:01 PM   #4
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
You have a /boot on your USB drive. It should have the files that you need for booting. Copy all the files with version numbers to the Fedora 6 /boot directory (on my install of Fedora 7 I have:
Code:
# ls /boot
config-2.6.21-1.3194.fc7      lost+found
grub                          System.map-2.6.21-1.3194.fc7
initrd-2.6.21-1.3194.fc7.img  vmlinuz-2.6.21-1.3194.fc7
you will only need the config, initrd, System.map, and vmlinuz files copied over.

Then edit your /etc/grub.conf on the Fedora 6 install to include the lines:
Code:
title Fedora-base (2.6.21-1.3194.fc7)
        root (hd0,0)
        kernel /vmlinuz-2.6.21-1.3194.fc7 ro root=[CHANGE_THIS] rhgb quiet
        initrd /initrd-2.6.21-1.3194.fc7.img
Change the [CHANGE_THIS] to point to the device file of your USB /root filesystem.

You will also need to change your /etc/fstab on the Fedora 7 install to have /boot point to the same /boot as you have on Fedora 6 (just copy the line over).

You should be able to make all these changes while booted into Fedora 6 with your USB drive mounted.

Last edited by forrestt; 06-06-2007 at 03:08 PM.
 
Old 06-06-2007, 03:05 PM   #5
creon
LQ Newbie
 
Registered: May 2007
Posts: 18

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by forrestt
You have a /boot on your USB drive. It should have the files that you need for booting. Copy all the files with version numbers to the Fedora 6 /boot directory (on my install of Fedora 7 I have:
Code:
# ls /boot
config-2.6.21-1.3194.fc7      lost+found
grub                          System.map-2.6.21-1.3194.fc7
initrd-2.6.21-1.3194.fc7.img  vmlinuz-2.6.21-1.3194.fc7
you will only need the config, initrd, System.map, and vmlinuz file copied over.

Then edit your /etc/grub.conf on the Fedora 6 install to include the lines:
Code:
title Fedora-base (2.6.21-1.3194.fc7)
        root (hd0,0)
        kernel /vmlinuz-2.6.21-1.3194.fc7 ro root=[CHANGE_THIS] rhgb quiet
        initrd /initrd-2.6.21-1.3194.fc7.img
Change the [CHANGE_THIS] to point to the device file of your USB /root filesystem.

You will also need to change your /etc/fstab on the Fedora 7 install to have /boot point to the same /boot as you have on Fedora 6 (just copy the line over)
Thank you very much, i'll try that now.
 
Old 06-06-2007, 03:19 PM   #6
creon
LQ Newbie
 
Registered: May 2007
Posts: 18

Original Poster
Rep: Reputation: 0
Well there is one more question now? Are you sure root partition is (hd0,0)? On the device.map the usb hdd is (sdb) (hd1) and i have three partitions sdb1 is boot and sdb2 is root, what should i write? (hd1,1)?
 
Old 06-06-2007, 03:34 PM   #7
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
Sorry, I missed that. No, it will be whatever it is listed as in the /etc/grub.conf on your Fedora 7 install.

You will also need to be careful about what other USB drives you install or have installed as adding or removing them might change that.
 
Old 06-06-2007, 04:30 PM   #8
creon
LQ Newbie
 
Registered: May 2007
Posts: 18

Original Poster
Rep: Reputation: 0
thnx a lot i did as you say and it works. thnx
 
Old 06-06-2007, 04:35 PM   #9
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
Glad I could help. Was starting to get worried that I was steering you wrong.
 
  


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
Fedora - Problems Mounting NTFS USB HDD kdm2002 Linux - Hardware 2 01-31-2006 04:44 PM
Dual boot XP(internal IDE HDD) Debian(external USB-IDE HDD) using boot.ini PolarDog Linux - Laptop and Netbook 2 07-01-2005 09:50 PM
Loadlin to boot up usb hdd? NobleSilkFairy Linux - Newbie 1 04-14-2005 08:50 AM
boot from USB HDD, no MOBO usb boot support magiconexxx Linux - Hardware 0 11-03-2004 12:38 AM
need help boot from usb-hdd shadow.blue Linux - General 4 04-25-2004 08:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:08 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