Results 1 to 5 of 5
  1. #1
    qualia is offline Senior Member Respected Member
    Join Date
    Feb 2006
    Location
    Behind your monitor
    Posts
    404

    Default Linux on External Hard Drive

    Is there a way to somehow install Ubuntu on an external HDD?
    I've been trying it for a while, Ubuntu 7.04 (Feisty Fawn) x64 on my external HDD, a Western Digital Passport (60GB).

    The thing is, the install was successful as far as file copying (and partitioning) goes. Then, it installs grub on my main HDD (which I don't want to happen). My idea is that I can just select my EHD as a boot device within BIOS when I wanted to run it. It does appear under the boot device menu.

    Each time I did that, it just says "No operating system found", and when I tried to boot off my main (C:\) HDD, it just says:
    please wait
    Loading grub 1.5...

    (something I can't really remember)
    Error 15 (if my EHD is plugged in)
    Error 21 (if my EHD is NOT plugged in)

    and it just hangs there.

    I managed to get the original boot loader back by using an XP cd (recovery console) and running FIXMBR on C:.

    Oh, while at that, can anyone recommend / show me a good small instant-on linux (or other OS) that can let me view and play my media files? Something like InstantOn from WinDVD. The only thing is I need it on an external HDD.. (I'm not planning to use the Ubuntu for this purpose)

    I'm running a 2GHz T7200 w/ 1GB of RAM, Windows XP Home.

  2. #2
    shautieh's Avatar
    shautieh is offline Senior Member Community Builder
    Join Date
    Mar 2005
    Location
    Skipea
    Posts
    5,340

    Default

    a priori you have to specify yourself to install grub on the external HDD (the live cd of ubuntu should ask you a question about this at the end of the installation)
    You should look if there is a tuto in the official forum of ubuntu

  3. #3
    Volvogga's Avatar
    Volvogga is offline Senior Member Always Around
    Join Date
    Sep 2005
    Location
    MI, USA
    Posts
    2,076

    Default

    I had a big fucking explination of why this is happening, but I lost it all.

    So fuck it.
    Note that installing on an external does not give you DMA, so it will not perform as well.

    Next, you have to install ALL of grub to the external HD in the /boot directory. Stage 1.5 can't access Stage 2 on the External right now as the BIOS is probably cutting it off after you say 'no, I don't want to boot off it'. During install (probably have to do an expert install or something), when it asks about grub, say yes I want to use it, no I don't want to install it to the MBR, and tell it to install it to the external HD (you'll probably have to know the external's path, which will be /dev/sda or /dev/sdb or something... FIND THIS OUT AHEAD OF TIME). After that, you'll be fine.

    You might also be able to use the Live disk of Ubuntu to fix your current install. Really, all you have to do is fix the GRUB install. Look it up on google. All you probably have to do is run 'grub-install -switch <external path>' or something.
    Vol~

    thanks to Silverwmoon!

  4. #4
    qualia is offline Senior Member Respected Member
    Join Date
    Feb 2006
    Location
    Behind your monitor
    Posts
    404

    Default

    Thanks, I've got it working now. I missed the question on where to install grub to =p. I found a guide on the net on how to do it, and which files to edit.

    It worked fine all right, but the thing is, I've set up my BIOS to boot of the cd first, then the EHD. It's all good and well, I can't boot into my EHD directly. I've got to boot to the CD first, choose "Boot from first hard drive" and then it'll boot to grub and run properly.

    If I boot directly to the EHD, it'd just skip it entirely and proceed to boot XP on the internal drive. Any way to get around this..?

  5. #5
    Volvogga's Avatar
    Volvogga is offline Senior Member Always Around
    Join Date
    Sep 2005
    Location
    MI, USA
    Posts
    2,076

    Default

    Allright, I think I see the problem. God damn dynamic booting devices. ><

    Ho'kay, so... here we have the world... err... oh, sorry.
    mmmm yeah, so boot into Ubuntu and get into whatever kind of terminal Ubuntu can handle and you are comfortable with. We're going to do some finagling. Change directory to /boot/grub first of all, now you have to run the grub setup. Enter these commands.
    [code]grub
    *should give you a "grub>" prompt, if it does not, stop and let me know*
    find /boot/grub/stage1 *this will return the device that stage 1 is on. Should come up with hd0 or hd1... you can use this to set your root command properly if your not certain which disk your running off*
    root (hd1,0) *hd1 is second hard disk, first partition. that is assuming your working external HD is /dev/sdb. If it is anything else, then you have to adjust the number acordingly. if it is /dev/sdc, for example, then you need to use root (hd2,0), see?*
    setup (hd1) *no partition numbers are needed for the setup command*[/code]That should for sure install grub to your External HDs' MBR. That will handle stage 1 and 1.5. Stage 2 is where things go to shit though (and why your install to the MBR of the internal HD probably bombed last time). You need to go into grub.conf with a text editor (run vim grub.conf... and make sure you can run basic Vi commands http://www.tuxfiles.org/linuxhelp/vimcheat.html). In here... if there is anything about Windows, just erase it. You should have something like this.
    [code]
    default=0
    timeout=5
    splashimage=(hd1,0)/grub/splash.xpm.gz
    #hiddenmenu

    title Ubuntu
    root (hd1,0)
    kernel /vmlinuz-2.6.20-1.2948 ro root=/dev/MyVolGroup00/LogVol00 rhgb quiet

    initrd /initrd-2.6.20-1.2948.img[/code]What you need to do is change every instance of (hd1) to (hd0).
    This is because the BIOS boots devices dynamicly. When you boot of your CD/DVD ROM, the BIOS says, ok, interal is the first HD, external is the second HD. But when you boot off the external, BIOS changes that.
    So your new grub will read something like this.
    [code]default=0
    timeout=5
    splashimage=(hd0,0)/grub/splash.xpm.gz
    #hiddenmenu

    title Ubuntu
    root (hd0,0)
    kernel /vmlinuz-2.6.20-1.2948 ro root=/dev/MyVolGroup00/LogVol00 rhgb quiet

    initrd /initrd-2.6.20-1.2948.img[/code]After that, booting off the external should work with no problem. If it does, you may reduce the timeout=5 value to 1 or 0, since you have no reason to look at that menu anyway (you already boot off the BIOS).

    EDIT: oooo found a good grub command. Re-read the part about grub commands for using find.
    Vol~

    thanks to Silverwmoon!

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
vBulletin Skin by: ForumThemes.com
Powered by vBulletin® Version 4.2.0
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
SEO by vBSEO 3.6.0 PL2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79