The Lizard Lounge
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsCommunityThe Lizard Lounge

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old January 13th, 2004, 09:31 PM
FrankieShakes FrankieShakes is offline
Frank The Tank!
Dev Articles Beginner (1000 - 1499 posts)
 
Join Date: Jun 2002
Location: Toronto, Canada
Posts: 1,246 FrankieShakes User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via ICQ to FrankieShakes Send a message via MSN to FrankieShakes
Linux Install (SuSE) on an external USB drive

Hey all!

I need the public's help... I've finally decided to play around with SuSE on my notebook (my main machine)... Only problem is that I have a small hard drive, so I decided to buy an external USB drive.

The problem I'm having now is that I've been unable to setup a dual-boot environment (Win XP and SuSE)... I've read that the bios needs to support booting from external drives, and if I'm not mistaken mine does (in the boot sequence, it has "removable devices" -- so I assume that includes USB drives).

Anyways, I was hoping somebody would have a solution on how I can go about setting up a dual-boot system, and being able to have Linux (any distro that will work will do) on my external drive.

Thanks!
__________________
____________________________________________
Developer Shed Weekly Writer | DevArticles Forum Moderator
Build Your Own KlipFolio Klip With PHP
FrankManno.com - Under Construction
Design Interactive Group - Under Construction

Reply With Quote
  #2  
Old January 20th, 2004, 08:49 AM
nicat23's Avatar
nicat23 nicat23 is offline
Addicted to Chaos..
Dev Articles Novice (500 - 999 posts)
 
Join Date: Jan 2003
Location: Ft. Worth, TX
Posts: 653 nicat23 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 47 m 52 sec
Reputation Power: 0
Send a message via AIM to nicat23 Send a message via Yahoo to nicat23
Frank, I know that you and I talked about this not too long ago.. Did you try using a bootloader like System commander to boot it up? I'm sorry, I can't remember much of what we talked about, we've talked about so much.. lol.. and stress lately has been so high that my memory is shot to hell... I'll scour the net for you and talk with a few of the linux gurus that I know and see if we can find a solution for you

*edit.. added below*

I talked with a few people, and as far as we can tell Linux has no knowledge of USB at all durring its install, so even if you had drivers that would work with your usb drive it is still no gaurantee that it would work with the distrobution of linux.. However I do have it under good faith that any of the BSD distrobutions DO work with USB external drives and will install without an issue because they are aware of USB durring the install (I checked, even windows won't install on an external drive.. tried that yesterday, didn't work..even though my bios would boot from it..) Another solution you COULD try this (though the results can't be backed up because I haven't tried it) install your distrobution of linux and then use something like norton ghost to clone it to the external usb drive and set the drive to boot within your bios.. I know you can't do that with windows, but linux lets you change drives, as long as it has a boot sector, it will boot from that drive

Try that, let me know!! I really wanna know if this will work or not..

Reply With Quote
  #3  
Old January 21st, 2004, 07:13 PM
FrankieShakes FrankieShakes is offline
Frank The Tank!
Dev Articles Beginner (1000 - 1499 posts)
 
Join Date: Jun 2002
Location: Toronto, Canada
Posts: 1,246 FrankieShakes User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via ICQ to FrankieShakes Send a message via MSN to FrankieShakes
Hey Justin,

Thanks for the tips... I'm definitely going to look into them.. As for any of the BSD variants, which would you recommend me using? I'm fairly new to Linux in general, so any advice is appreciated.

A friend of mine gave me a link to a site that had instructions on setting up a dual boot with Windows/Linux... He suggested rather than using GRUB or LILO, I would need to use Window's built-in boot manager, otherwise I'd be out of luck in setting up the two. I don't recall reading anything re: external drives in the article... so I'm afraid I may be out of luck, as you suggested.

Hopefully the BSD variants will get me on my way...

I hadn't thought of using a ghosted image... But I wonder if there would be any further problems with that... Hmm... Where do I even start? I have SuSE installed on my external drive... Would I have to re-install it to my internal drive? If so, I may be out of luck... I don't have much room left on this one... Perhaps, the BSD alternative is my best bet?

Thanks again...

Reply With Quote
  #4  
Old May 22nd, 2005, 11:33 PM
punkrawkpat punkrawkpat is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: Australia
Posts: 4 punkrawkpat User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 30 m 46 sec
Reputation Power: 0
Arrow RE: Linux Install on an external USB Drive

Let me start by saying that not only is it possible to install and run linux from an external USB drive, I am doing it right now. To date I have successfully installed Suse, Fedora and Ubuntu on an external drive, as well as having Frugalware and PCLinuxOS on my internal HDD, all available through boot options in GRUB.

You would be right in assuming that if your BIOS has USB boot support, there shouldnt be a problem at all. The thing with Linux is that most distributions don't have USB support loaded into the kernel during the boot phase, so you will generally come across such errors as the root drive not being found, etc etc etc.

You can easily overcome this by creating an INITRD Ramdisk that will force the kernel to preload USB support during boot.

In the case of suse, you do this by:

1. Install Suse to the USB device (/sda, or sdb etc) - make sure you select to have the grub bootloader installed on the USB drive too, and not the Master drive.
2. Boot from the CD into Rescue mode
3. Issue the following commands:

'mkdir /mnt/sysimage'
'mount /dev/sdaX /mnt/sysimage'
'chroot /mnt/sysimage'
NOTE: sdaX refers to the partition u installed Suse on and the mapping of the USB drive (could be /sdb or similar too).

4. Use VI to edit the following file - /etc/sysconfig/kernel'
5. Add the following into the quotes at the line that has: INITRD_MODULES=" "
ehci-hcd
ohci-hcd
uhci-hcd
sd_mod
usb-storage


THIS LINE SHOULD NOW LOOK LIKE THIS:

INITRD_MODULES="reiserfs ehci-hcd ohci-hcd uhci-hcd usb-storage sd_mod"

6. Issue the following commands:

'mount -tproc none /proc'
'mkinitrd'

7. Add the kernel and initrd image to the boot grub loader on the master boot record (NOTE: for the initrd line, just add initrd (hd1,6)/boot/initrd - where hd1,6 is relevant to your partition setup)

A typical default Suse 9.2 install grub line for this setup would look like below (be sure to substitute according to your configuration):

title Suse 9.2 (USB)
kernel (hd1,1)/boot/vmlinuz-2.6.8-24-smp ro root=/dev/sda2
initrd (hd1,1)/boot/initrd

8. REBOOT!!!

The steps for other distros are a bit different, but the purpose of the exercise is the same. If u need help with another distro, I can provide individual steps for that too.

Reply With Quote
  #5  
Old May 31st, 2005, 03:36 PM
anarkist anarkist is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2005
Posts: 1 anarkist User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 23 m 40 sec
Reputation Power: 0
Will this work with Mandriva LE2005?

Hi,
I recently got hold of a Mandriva LE2005 DVD and want to install it to my Western Digital 200GB external drive. I am a complete Linux n00bie and I am terribly scared to screw up my new laptop (Dell Inspiron 6000). I would still like to try. I checked my bios and I'm pretty positive that my laptop can boot from an external USB device. I have a few questions.
1.What are the corresponding changes that need to be done for a Mandriva install which are different than a Suse9.2 install?
2. Do i need to reformat my external HD? I have some data and backups for my internal HD on there which I dont wanna delete. Can I install onto a logical partition without erasing the entire disk?
3. I booted using the dvd and it detects my external hd, but not my internal hd which has Windows XP. Is that normal?
thanks a lot
-Jack

UPDATE:
I succesfully installed Mandriva on a logical partition on my external hard drive. But when I try to edit the kernel file in /etc/sysconfig/kernel, I can't do it. Basically there is no such file and vi just makes a new file which is blank. There is an entry 'installkernel' though. I tried 'installkernel 2.6.11' and it does something, but I still don't see the kernel file in there to edit. I can't boot to the external hard drive, as it says 'errot loading OS'. Any help would be appreciated.
-Jack

Quote:
Originally Posted by punkrawkpat
Let me start by saying that not only is it possible to install and run linux from an external USB drive, I am doing it right now. To date I have successfully installed Suse, Fedora and Ubuntu on an external drive, as well as having Frugalware and PCLinuxOS on my internal HDD, all available through boot options in GRUB.

You would be right in assuming that if your BIOS has USB boot support, there shouldnt be a problem at all. The thing with Linux is that most distributions don't have USB support loaded into the kernel during the boot phase, so you will generally come across such errors as the root drive not being found, etc etc etc.

You can easily overcome this by creating an INITRD Ramdisk that will force the kernel to preload USB support during boot.

In the case of suse, you do this by:

1. Install Suse to the USB device (/sda, or sdb etc) - make sure you select to have the grub bootloader installed on the USB drive too, and not the Master drive.
2. Boot from the CD into Rescue mode
3. Issue the following commands:

'mkdir /mnt/sysimage'
'mount /dev/sdaX /mnt/sysimage'
'chroot /mnt/sysimage'
NOTE: sdaX refers to the partition u installed Suse on and the mapping of the USB drive (could be /sdb or similar too).

4. Use VI to edit the following file - /etc/sysconfig/kernel'
5. Add the following into the quotes at the line that has: INITRD_MODULES=" "
ehci-hcd
ohci-hcd
uhci-hcd
sd_mod
usb-storage


THIS LINE SHOULD NOW LOOK LIKE THIS:

INITRD_MODULES="reiserfs ehci-hcd ohci-hcd uhci-hcd usb-storage sd_mod"

6. Issue the following commands:

'mount -tproc none /proc'
'mkinitrd'

7. Add the kernel and initrd image to the boot grub loader on the master boot record (NOTE: for the initrd line, just add initrd (hd1,6)/boot/initrd - where hd1,6 is relevant to your partition setup)

A typical default Suse 9.2 install grub line for this setup would look like below (be sure to substitute according to your configuration):

title Suse 9.2 (USB)
kernel (hd1,1)/boot/vmlinuz-2.6.8-24-smp ro root=/dev/sda2
initrd (hd1,1)/boot/initrd

8. REBOOT!!!

The steps for other distros are a bit different, but the purpose of the exercise is the same. If u need help with another distro, I can provide individual steps for that too.

Last edited by anarkist : June 1st, 2005 at 11:26 PM. Reason: Installed Mandriva succesfully. Cant edit kernel.

Reply With Quote
  #6  
Old June 26th, 2005, 03:14 PM
mcis2005 mcis2005 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jun 2005
Posts: 2 mcis2005 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 m 51 sec
Reputation Power: 0
How to first get Linux installer to recognize the USB drive?

Hi,
You stated as step #1 to install Suse to the USB drive.
My problem is actually how to get this accomplished. When I run Linux 4 AS installer, it does not recognized my Western Digital USB drive. It just sees my internal drive (which has Windows XP partition). How do I get the Linux installer to see my new USD Western Digital hard drive.
Thanks.
_____________

Quote:
Originally Posted by punkrawkpat
Let me start by saying that not only is it possible to install and run linux from an external USB drive, I am doing it right now. To date I have successfully installed Suse, Fedora and Ubuntu on an external drive, as well as having Frugalware and PCLinuxOS on my internal HDD, all available through boot options in GRUB.

You would be right in assuming that if your BIOS has USB boot support, there shouldnt be a problem at all. The thing with Linux is that most distributions don't have USB support loaded into the kernel during the boot phase, so you will generally come across such errors as the root drive not being found, etc etc etc.

You can easily overcome this by creating an INITRD Ramdisk that will force the kernel to preload USB support during boot.

In the case of suse, you do this by:

1. Install Suse to the USB device (/sda, or sdb etc) - make sure you select to have the grub bootloader installed on the USB drive too, and not the Master drive.
2. Boot from the CD into Rescue mode
3. Issue the following commands:

'mkdir /mnt/sysimage'
'mount /dev/sdaX /mnt/sysimage'
'chroot /mnt/sysimage'
NOTE: sdaX refers to the partition u installed Suse on and the mapping of the USB drive (could be /sdb or similar too).

4. Use VI to edit the following file - /etc/sysconfig/kernel'
5. Add the following into the quotes at the line that has: INITRD_MODULES=" "
ehci-hcd
ohci-hcd
uhci-hcd
sd_mod
usb-storage


THIS LINE SHOULD NOW LOOK LIKE THIS:

INITRD_MODULES="reiserfs ehci-hcd ohci-hcd uhci-hcd usb-storage sd_mod"

6. Issue the following commands:

'mount -tproc none /proc'
'mkinitrd'

7. Add the kernel and initrd image to the boot grub loader on the master boot record (NOTE: for the initrd line, just add initrd (hd1,6)/boot/initrd - where hd1,6 is relevant to your partition setup)

A typical default Suse 9.2 install grub line for this setup would look like below (be sure to substitute according to your configuration):

title Suse 9.2 (USB)
kernel (hd1,1)/boot/vmlinuz-2.6.8-24-smp ro root=/dev/sda2
initrd (hd1,1)/boot/initrd

8. REBOOT!!!

The steps for other distros are a bit different, but the purpose of the exercise is the same. If u need help with another distro, I can provide individual steps for that too.

Reply With Quote
  #7  
Old June 26th, 2005, 08:03 PM
mcis2005 mcis2005 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jun 2005
Posts: 2 mcis2005 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 m 51 sec
Reputation Power: 0
Steps for RedHat Linux 4

I have managed to get my USB Western Digital drive recognized by using "linux expert" mode. Now, I need the steps to be able to boot up. The steps you provided are for SuSE; could you provide me with the steps for RedHat Linux 4 (I'm using Enterprise AS, kernel 2.6).
----------

Quote:
Originally Posted by mcis2005
Hi,
You stated as step #1 to install Suse to the USB drive.
My problem is actually how to get this accomplished. When I run Linux 4 AS installer, it does not recognized my Western Digital USB drive. It just sees my internal drive (which has Windows XP partition). How do I get the Linux installer to see my new USD Western Digital hard drive.
Thanks.
_____________

Reply With Quote
  #8  
Old July 3rd, 2005, 11:40 AM
Hannes Hannes is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2005
Posts: 1 Hannes User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 10 sec
Reputation Power: 0
Question Question to Step 7

Hi,

first of all:Thanks for this great information.

Everything works fine for me, except for step 7.
The way I partitioned my harddrive:
sda1 /boot
sda2 /swap
sda3 /

When adding this to GRUB:
kernel (hd0,0)/boot/vmlinuz root=/dev/sda3
initrd (hd0,0)/boot/initrd

Linux doesn't boot automatically.
What have I done wrong?
Do I have to adjust the part "hd..."?

Cheers,
Hannes



Quote:
Originally Posted by punkrawkpat
Let me start by saying that not only is it possible to install and run linux from an external USB drive, I am doing it right now. To date I have successfully installed Suse, Fedora and Ubuntu on an external drive, as well as having Frugalware and PCLinuxOS on my internal HDD, all available through boot options in GRUB.

You would be right in assuming that if your BIOS has USB boot support, there shouldnt be a problem at all. The thing with Linux is that most distributions don't have USB support loaded into the kernel during the boot phase, so you will generally come across such errors as the root drive not being found, etc etc etc.

You can easily overcome this by creating an INITRD Ramdisk that will force the kernel to preload USB support during boot.

In the case of suse, you do this by:

1. Install Suse to the USB device (/sda, or sdb etc) - make sure you select to have the grub bootloader installed on the USB drive too, and not the Master drive.
2. Boot from the CD into Rescue mode
3. Issue the following commands:

'mkdir /mnt/sysimage'
'mount /dev/sdaX /mnt/sysimage'
'chroot /mnt/sysimage'
NOTE: sdaX refers to the partition u installed Suse on and the mapping of the USB drive (could be /sdb or similar too).

4. Use VI to edit the following file - /etc/sysconfig/kernel'
5. Add the following into the quotes at the line that has: INITRD_MODULES=" "
ehci-hcd
ohci-hcd
uhci-hcd
sd_mod
usb-storage


THIS LINE SHOULD NOW LOOK LIKE THIS:

INITRD_MODULES="reiserfs ehci-hcd ohci-hcd uhci-hcd usb-storage sd_mod"

6. Issue the following commands:

'mount -tproc none /proc'
'mkinitrd'

7. Add the kernel and initrd image to the boot grub loader on the master boot record (NOTE: for the initrd line, just add initrd (hd1,6)/boot/initrd - where hd1,6 is relevant to your partition setup)

A typical default Suse 9.2 install grub line for this setup would look like below (be sure to substitute according to your configuration):

title Suse 9.2 (USB)
kernel (hd1,1)/boot/vmlinuz-2.6.8-24-smp ro root=/dev/sda2
initrd (hd1,1)/boot/initrd

8. REBOOT!!!

The steps for other distros are a bit different, but the purpose of the exercise is the same. If u need help with another distro, I can provide individual steps for that too.

Reply With Quote
  #9  
Old July 29th, 2005, 10:22 AM
Scruff Scruff is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2005
Posts: 1 Scruff User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 m 52 sec
Reputation Power: 0
One more complication...

Hi punkrawkpat:

I'm new to this forum, but google led me to your perl of wisdom:

Quote:
Originally Posted by punkrawkpat
Let me start ...
I can provide individual steps for that too.


I will try your suggestion over the weekend, but I've got an additional twist that I wanted to pick your brain about. I'm using Suse 9.3 pro, so your post should work fine to boot to my USB drive. However, my laptop only has usb1 ports, and to get usb2, I have to use a cardbus adapter. When I boot using the Live DVD, the usb2 drive is recognized, but I need to boot from that drive instead, and it isn't recognized during the boot.

So, in addition to adding usb support, I think I need to add PCMCIA support. Suse tech support bailed on this and referred me to the pay support. The question is - how do I add pcmcia supprt (before USB support) to the boot?

Hoping against hope,

Michael (aka Scruff)

Reply With Quote
  #10  
Old August 3rd, 2005, 04:41 AM
jalbersdorfer jalbersdorfer is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Location: in Germany, Bavaria
Posts: 5 jalbersdorfer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 28 m 41 sec
Reputation Power: 0
Hi, I installed SuSe 9.3 Personal successfully on my external Harddrive /dev/sda1.
after configuring initrd and grub, grub will boot fine, until to a point where the output is like this:

Quote:
waiting for device sda1 to appear ...


device appears, output displays Head, sectors, etc...
a few lines below output displays some information about the SCSI device (lun 00, etc)
another few lines later it will hang.

(I'll put the whole output of console later into this forum. --- no time now, have to work) ... but maybe someone knows right now about this problem.

I'd be pleased for any help.

edited --inserted exact log--
Quote:
Waiting for device /dev/sda1 to appear: .... Vendor: SAMSUNG Model: MP0804H Type: Direct-Access ANSI SCSI revision: 00
SCSI device sda: 156301488 512-byte hdwr sectors (80026MB)
sda: assuming drive cache: write through
SCSI device sda: 156301488 512-byte hdwr sectors (80026MB)
sda: assuming drive cache: write through
sda: sda1 sda2 <sda5>
Attached scsi desk sda at scsi0, channel 0, lun 0
.not found -- exiting to /bin/sh
sh: can#t access tty: job control turned off
$_ <-- blinking cursor (system hangs)


P.S. I typed this off from console... how can I get these messages out easier? is there a file? can I pipe this output to a file?

thanks for help in advance.

____________
@4th Aug:
so much people out there, and no body can help me?
a colleague - a linux crack - means, that my problem is SuSe specific. Any Ideas? - come on.

Last edited by jalbersdorfer : August 4th, 2005 at 10:00 AM. Reason: update

Reply With Quote
  #11  
Old August 9th, 2005, 03:46 PM
jh041166 jh041166 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 1 jh041166 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 31 m 53 sec
Reputation Power: 0
Hi, i got my computer to boot off the external usb hard drive doing what you said. My only problem is that when my external hard drive is not connected i can not get GRUB to load or windows to load. The computer attemps to load grub but comes up with "error 21". How can i get my notebook to boot windows when i dont have the external drive connected?

Thanks for all of your help, i could have never gotten this working otherwise.

Jon

Reply With Quote
  #12  
Old August 11th, 2005, 05:16 PM
seantorgerson seantorgerson is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 1 seantorgerson User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 m 18 sec
Reputation Power: 0
I found this to be an EXCELLENT guide to getting SuSe installed on my USB drive.

The only issue I had was in getting the initrd part done... and then I remembered that I had created a seperate boot partition (/dev/sda1 mount point of /boot). In order to get it to work I had to mount that before issuing the mkinitrd command.

Thanks again for the post

Reply With Quote
  #13  
Old September 13th, 2005, 05:55 AM
franzvino franzvino is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Sep 2005
Posts: 1 franzvino User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 m 2 sec
Reputation Power: 0
Doesn't work suse 9.1 & Hd USB

Hi!
sorry, i'm newbbies.
i've read entire guides but my installation doesn't work!!!
1. Partition
sda1 /
sda2 swap
2. grub is on usb hd (sda)
3. grub's menu.lst:
title suse
kernel (hd1,0)/boot/vmlinuz-2.6.4-52-default ro /root=/dev/sda1
initrd (hd1,0)/boot/initrd-2.6.4-52-default

title Win
root (hd0,0)
chainloader +1
boot

4. When i reboot, my pc, after bios screen, show black screen with the writes "GRUB" on the top left, and freeze!!!


HELP HELP
thank for everthing help
Goodbye Franz




___________________________

My pc configuration
Toshiba Satellite M30x-113 with 512 Mb ram & 40 Gb Hd
Hd Usb 20 Gb

Reply With Quote
  #14  
Old January 3rd, 2006, 08:38 AM