Ubuntu 5.04 on TP42 2nd HDD

Solaris, RedHat, FreeBSD and the like
Post Reply
Message
Author
Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

Ubuntu 5.04 on TP42 2nd HDD

#1 Post by Edward Mendelson » Thu Apr 21, 2005 6:24 pm

This is a quick report on how to install Linux (or at least Ubuntu 5.04) on the second hard disk of a ThinkPad T42; presumably it applies to other distributions and other ThinkPads as well.

I wanted to install Linux on the 2nd hard disk while keeping the original Windows XP setup on the 1st hard disk - AND I wanted the Linux installation to leave my Windows installation and the 1st HDD alone - in other words, install Linux without writing anything new to the Windows HDD. The idea was that I would decide whether to boot to Linux or Windows either by pressing F12 at boot to choose between the two hard disks, or by changing the default boot options in the BIOS.

If anyone else is interested, here's how to do it.

In addition to the 2nd HDD adapter, you'll need a USB CD or DVD drive. The IBM Portable Drive Bay 2000 will NOT work. The installation CD can boot from the Portable Drive Bay, but then the installer can't find the CD again to finish the installation. (At least I could never make it do this.) But a standard USB CD works perfectly (I used an HP DVD Writer in a cheap external USB 2.0 enclosure).

Install Ubuntu in the simplest possible way. I have a spare 10GB disk in the 2nd HDD adapter, and I manually partitioned it into a 8GB partition for Ubuntu and a 2GB partition for a swap drive. If you have more than 512MB in your system don't accept the default partition sizes, because you need a swap drive that's larger than the amount of RAM in your machine in order for hibernation to work.

Let the installer continue with the default setup until you reach the point where it offers to install the GRUB bootloader in the MBR of the 1st hard disk. If you're always going to keep the 2nd HDD installed, it's OK to do this, but if (like me) you don't want to go through GRUB every time you boot to Windows, say No, and instead install it to "/dev/hdc1" (no quotes), which is the first partition of your 2nd HDD.

When the time comes to reboot, either use F11 or the BIOS startup options to boot to the 2nd HDD. GRUB will start up and offer to boot Linux. Don't press Enter to boot, because it won't work. Instead, press "e" to edit the command sequence, and change

root (hd1,0)

to

root (hd0,0)

Then press "b" to boot and you'll boot into Ubuntu. To avoid this manual step, make yourself root and edit the /boot/grub/menu.lst file to change all instances of

root (hd1,0)

to

root (hd0,0)

Save the file. You can now boot correctly into Linux from the GRUB menu.

(In case anyone's interested: here's a quick report on Ubuntu 5.04 on the T42 in general: with a few extra configuration steps, everything works perfectly, including hibernation, suspend, even the volume-control and brightness buttons, complete with visual feedback. More later...)
Last edited by Edward Mendelson on Fri Apr 22, 2005 6:55 am, edited 1 time in total.

baraider
Junior Member
Junior Member
Posts: 464
Joined: Thu Feb 17, 2005 5:05 pm
Location: NYC
Contact:

#2 Post by baraider » Thu Apr 21, 2005 10:35 pm

thanks, this is exactly what i've been looking for...i want to install ubuntu on my second hd...and leave the main hd along. I want dual boot but don't want to put both OS on the same hd.

The only problem is i want to see anyone with t43 that installed ubuntu. I want to see if i'll have any driver problem with it.

Do you have a more detailed guide somewhere that i can bookmark?
Current: T60 2623-D6U, Ideapad S12 (upgraded to XP Pro)
Past: T42

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#3 Post by egibbs » Fri Apr 22, 2005 6:43 am

Just a note that you can also swap out the primary HDD and then do the install from the Ultrabay CD or DVD drive. That way you don't need a USB drive.

I've done it a couple times that way (on a T20) and it works fine. The HDD only takes about a minute to change out (2 if you've never done it before).

After you do the install put the original drive back in and stick the new one in the Ultrabay HDD adapter, then as you said use F12 to select the boot device.

Ed Gibbs

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#4 Post by Edward Mendelson » Fri Apr 22, 2005 6:53 am

Hmm... when I tried exactly that method a few months ago (with SuSE 92 and Ubuntu 4.10), I couldn't get the drive with Linux to boot after I moved it from being the main disk into the second HDD adapter. I tried various tricks with GRUB, but couldn't get any to work (but I'm not sure I tried the one I described above).

Where did you install GRUB when you did this - in the MBR or the first partition?

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#5 Post by egibbs » Fri Apr 22, 2005 7:04 am

I'm pretty cluseless on Linux so I just accepted the default. I THINK it wanted to make a separate partition for GRUB and I let it, but I could be wrong.

This was on a T20 too - haven't tried it on my T42p though I may do that this weekend.

Ed Gibbs

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#6 Post by Edward Mendelson » Fri Apr 22, 2005 7:21 am

The default in every distro I've seen is to install GRUB in the MBR. I've never seen anything offer to create a special partition for GRUB (the way you had to do for OS/2 BootManager), but I can't claim to have seen more than 0.0000000000002 percent of all Linux distributions.

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#7 Post by egibbs » Fri Apr 22, 2005 8:38 am

Now that I think back I think I may have told it not to install GRUB because I wasn't going to be dual-booting on the same volume, just selecting the boot device with F12. Is that possible? It's been a while and as I said, I was (and am) pretty clueless as to what I am doing. I just know whatever I did worked - I installed Ubuntu (Warty), Suse (9.2 I think) and Fedora that way and they all booted fine once I moved the disk to the Ultrabay.

Hopefully my wife doesn;t have a long honeydo list for this weekend and I'll try it on the T42p. I'm still clueless though.

Ed Gibbs

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#8 Post by Edward Mendelson » Fri Apr 22, 2005 9:10 am

I don't think Linux can boot without a bootloader - so you had to install GRUB or LILO somewhere. Theoretically, you could leave GRUB (and LILO) off the hard disk and boot Linux from a floppy with GRUB (or LILO) on it, but you would certainly remember if you did that!

It seems to be impossible to "just boot into Linux" without a bootloader. Every Linux disk, including the live CDs, has a bootloader on it, almost certainly GRUB or LILO. (Presumably there are others, but I've never heard of any other than these two.)

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#9 Post by egibbs » Fri Apr 22, 2005 9:16 am

As I said, I was operating pretty much blind.

The other thing is that the T20 had a retail XP load on the main HDD without the hidden partition or Pre-Desktop area. That may have made a difference.

I'll let you know what I find out this weekend if I get to it.

Ed Gibbs

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#10 Post by egibbs » Sat Apr 23, 2005 4:25 pm

Ok, I'm sitting here writing this in Firefox running under Ubuntu 5.04, which booted off the 2nd HDD in the Ultrabay on my T42p after being installed from the Ultrabay CD-ROM with the HDD in the primary drive slot.

It did NOT work auotmatically when I moved the drive to the Ultrabay - not at all. Big time kernel panic, etc. No idea why it worked on my T20, and now I'm wondering if it really did or if I had to fix it there as well.

The fix is to edit the /boot/grub/menu.lst file (or hit esc on boot and use the e command) to edit the second line of the normal boot to change hda1 to hdc1. I did not have to change the first line - it already said root (hd0,0).

The reason you need hdc instead of hdb is that the ultrabay is the first device on IDE channel 2, not the second device on IDE channel 1 as you'd think (took a while to figger that one out!).

All seems to work so far, except for fn+f5 to control the power state of the wireless radios. That does not work and I haven't figured out why yet - suggestions welcomed.

Ed Gibbs

baraider
Junior Member
Junior Member
Posts: 464
Joined: Thu Feb 17, 2005 5:05 pm
Location: NYC
Contact:

#11 Post by baraider » Sat Apr 23, 2005 7:16 pm

anyone comment on the battery life under ubuntu?
Current: T60 2623-D6U, Ideapad S12 (upgraded to XP Pro)
Past: T42

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#12 Post by Edward Mendelson » Tue Apr 26, 2005 6:04 am

By the way, one advantage of the two-HDD method of installing Ubuntu and Windows is that you can open one while the other is hibernating, or even hibernate both. No need to shut either one down when restarting the other.

egibbs
Senior Member
Senior Member
Posts: 896
Joined: Tue Apr 27, 2004 6:05 am
Location: New Jersey

#13 Post by egibbs » Tue Apr 26, 2005 6:56 am

Edward Mendelson wrote:By the way, one advantage of the two-HDD method of installing Ubuntu and Windows is that you can open one while the other is hibernating, or even hibernate both. No need to shut either one down when restarting the other.
I was wondering if I could do that. Could you explain EXACTLY how to choose which one to wake up after you hibernate the other?

Ed Gibbs

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#14 Post by Edward Mendelson » Tue Apr 26, 2005 7:05 am

Windows on HDD0, Linux (and Grub) on HDD1.

After hibernating either one, turn on machine. Do one or the other of the following:

1. On boot, press F12, boot either to HDD0 for Windows, or HDD1 for Linux (or, if you have GRUB setup corrrectly, Windows).

OR

2. If (as described above) you default to booting to HDD1, simply choose Linux to wake up hibernating Linux or Windows to wake up hibernating Windows.

Whichever one you choose, just hibernate when shutting down. Doesn't matter if both are hibernated. Each one is woken by its own bootloader.

christopher_wolf
Special Member
Posts: 5741
Joined: Sat Oct 08, 2005 1:24 pm
Location: UC Berkeley, California
Contact:

#15 Post by christopher_wolf » Fri Jan 20, 2006 1:44 am

OK, I will bump this up since I just found out how to do this on my T43

So I installed Ubuntu 5.10 on the main HDD (60GB, 7200RPM) when I swapped it into the belly of the Thinkpad; then I put it into the 2nd HDD adapter. Everything went fine on the install when it was in the primary; but it didn't work when I went to boot....as expected.

The device has to be "sdb1" and *NOT* "sda1" as the command stated; that must be changed if you are to boot off of the 2nd HDD Adapter with Ubuntu.

Windows XP also works fine and boots like it did before.

If you don't want to tell grub to go to sdb1 everytime you boot, you will have to modify that line in the /boot/grub/menu.lst file as mentioned before. It requires only one change to the line where "root=/dev/sda1"; it should read "root=/dev/sdb1"

HTH :)
IBM ThinkPad T43 Model 2668-72U 14.1" SXGA+ 1GB |IBM 701c

~o/
I met someone who looks a lot like you.
She does the things you do.
But she is an IBM.
/~o ---ELO from "Yours Truly 2059"

XTI
Posts: 9
Joined: Sun Jun 26, 2005 8:14 pm

#16 Post by XTI » Mon Jan 23, 2006 7:45 pm

I would give Novell open SuSE 10.0 a try. I had Ubuntu on my T23 and took it off. It does not come with a root account so you need to SUDO root any time you need root access. I found Open SuSe to be so much more user friendly over all. And there were always updates available. One other thing I found with Ubuntu is it took me tons of time to get Sun java installed. When I finally got it working it took out my firefox so I could not connect to the web. Got really frustrated and removed it and put SuSE with KDE on it from a net install. That's where you download a 30 mb file burn to cd and it installs itself with just what it needs from the internet. Better then burning 3 or four cds first. :)

christopher_wolf
Special Member
Posts: 5741
Joined: Sat Oct 08, 2005 1:24 pm
Location: UC Berkeley, California
Contact:

#17 Post by christopher_wolf » Tue Jan 24, 2006 2:40 am

Mmm, I use SuSE 10 on another machine. I gave it a good deal of consideration, but Ubuntu ended up on the 2nd HDD. So far, I have had no problems with it (Java was a breeze, getting all the Thinkpad Keys working, especially the browser keys, was a snap, IBM-ACPI, Fingerprint Reader for GDM logon, the Trackpoint with scroll button and press-to-select, etc). It needed only minor tweaking from a base install and is pretty small; I may also try out some more BSD. :)

Battery life is pretty good; with some tweaks, I have around the same battery time I get in Windows XP.

Later on, I will put BSD on here; I have only used BSD on Workstations/Desktops, never on a Thinkpad...But I do want to put it on.
IBM ThinkPad T43 Model 2668-72U 14.1" SXGA+ 1GB |IBM 701c

~o/
I met someone who looks a lot like you.
She does the things you do.
But she is an IBM.
/~o ---ELO from "Yours Truly 2059"

mikel
Posts: 1
Joined: Wed Apr 19, 2006 4:13 am
Location: Brighton, UK
Contact:

#18 Post by mikel » Thu Apr 20, 2006 3:03 am

christopher_wolf wrote: So I installed Ubuntu 5.10 on the main HDD (60GB, 7200RPM) when I swapped it into the belly of the Thinkpad; then I put it into the 2nd HDD adapter. Everything went fine on the install when it was in the primary; but it didn't work when I went to boot....as expected.

The device has to be "sdb1" and *NOT* "sda1" as the command stated; that must be changed if you are to boot off of the 2nd HDD Adapter with Ubuntu.
I am trying to configure a similar setup on my T60. Ubuntu boots fine from the main HDD bay, but from the 2nd HDD adapter, it fails. Editing the boot command, to use "sdb1" doesn't resolve the problem .. the device is not present. Other variations suggested in the thread also failed.

How can I determine what unix device the drive is available at?
Any help appreciated :)

christopher_wolf
Special Member
Posts: 5741
Joined: Sat Oct 08, 2005 1:24 pm
Location: UC Berkeley, California
Contact:

#19 Post by christopher_wolf » Thu Apr 20, 2006 2:57 pm

You need to see what device it is called. You can, if you want, root around in the GRUB command line and see what it is called.

I find that pretty interesting though. On just about all Thinkpads I have seen and used, the 2nd HDD, or any device through the IDE in the Ultrabay, is the first device on the second IDE channel. Unless they have changed the controller setup for it a good amount, I don't know how this could go that awry.

Also, if I recall correctly, the Ultrabay in the T60 is still PATA and not SATA...That could cause an issue.
IBM ThinkPad T43 Model 2668-72U 14.1" SXGA+ 1GB |IBM 701c

~o/
I met someone who looks a lot like you.
She does the things you do.
But she is an IBM.
/~o ---ELO from "Yours Truly 2059"

alfio
Junior Member
Junior Member
Posts: 326
Joined: Tue Feb 21, 2006 11:43 pm
Location: bloomington, in

#20 Post by alfio » Sun Jul 22, 2007 11:36 pm

i just followed the instructions posted above to successfully (and finally!) get my HDs / OSs working like i want them to.

one thing that i thought would happen that hasn't quite worked out is that i can no longer see the 2nd HDD (the one running linux) from windows - is that supposed to happen? (i can, however, see the XP HDD from linux)


alfio

egalvan
Posts: 47
Joined: Sun May 27, 2007 12:51 pm
Location: Brownsville, TX

#21 Post by egalvan » Wed Jul 25, 2007 2:43 pm

alfio wrote:
one thing that i thought would happen that hasn't quite worked out is that i can no longer see the 2nd HDD (the one running linux) from windows - is that supposed to happen? (i can, however, see the XP HDD from linux)


alfio
It's a Windows "feature", Windows supports only Windows.
That said, there is a Windows driver to let you use Linux ext2 partitions.

http://www.fs-driver.org/

I use this to read my common /data partition on my dual-boot t60p 120g drive.
Yes, I wish it had full ext3 support, but this is a good start..


Then there is this NTFS driver for Linux...

http://www.linux-ntfs.org/

Modern kernels have this by default, but I don't use this feature.
IBM TP T40 | 2GB RAM | 14.1" XGA |
100GB 7K100 | | 1.6 Dothan (donated to life-long friend)

IBM TP T60P | 2GB RAM | 15.4" IPS-SXGA |
120GB | T7200 | (thank you Brent Presley)

Volker
Junior Member
Junior Member
Posts: 482
Joined: Fri Oct 01, 2004 10:21 am
Location: Dublin, Ireland
Contact:

#22 Post by Volker » Wed Jul 25, 2007 4:19 pm

The ultrabay used to be /dev/hdc*, but with libata it is now /dev/sdb*

One caveat for all those that mount the windows partition in linux and/or the linux partition in windows (using 3rd party drivers): If you want to hibernate you must unmount that partition first. Otherwise the hibernated OS will not be happy when you resume and something is changed on the file system.

alfio
Junior Member
Junior Member
Posts: 326
Joined: Tue Feb 21, 2006 11:43 pm
Location: bloomington, in

#23 Post by alfio » Wed Jul 25, 2007 8:39 pm

oops

i guess i spoke too soon. although i was able to get xubuntu to boot off the 2nd HDD adapter, as soon as i installed Debian things got all messed up. or rather, as soon as i moved into the 2nd HDD spot because both OSs run fine when installed as the primary HD.

any ideas?

alfio

Volker
Junior Member
Junior Member
Posts: 482
Joined: Fri Oct 01, 2004 10:21 am
Location: Dublin, Ireland
Contact:

#24 Post by Volker » Thu Jul 26, 2007 10:52 am

alfio wrote: as soon as i installed Debian things got all messed up. or rather, as soon as i moved into the 2nd HDD spot because both OSs run fine when installed as the primary HD.
Since you do not provide any details I can only guess, but one probable cause is that /etc/fstab can use device names (like /dev/hda1) or partition labels (e.g. LABEL="root"). Clearly, the device names change if you put the hdd into the ultrabay slot, so it can only work if fstab uses partition labels. This is done differently in different distributions.

lightweight
Sophomore Member
Posts: 234
Joined: Sat Jun 30, 2007 10:56 pm
Location: L. A.

#25 Post by lightweight » Fri Jul 27, 2007 4:27 am

"How can I determine what unix device the drive is available at?
Any help appreciated"

grub> cat /etc/fstab

"as soon as i installed Debian things got all messed up."

Heh. What does this mean? :) Where is GRUB? What errors do you receive?
Have: x60s ultralight 1705-CTO, Debian SiD, Linux 2.6.25-2 | x61s ultralight 7668-CTO, Debian SiD/Experimental, Linux 2.6.27-git5 | Model M 1391401, white label, 07-17-91
Had: x22, Debian Testing/SiD, Linux 2.6.18-22

Post Reply
  • Similar Topics
    Replies
    Views
    Last post

Return to “Linux Questions”

Who is online

Users browsing this forum: No registered users and 3 guests