Monday, 27 October 2008

Kubuntu 8.04 on Toshiba Portege R100

Preamble:

I've just got my Toshiba Portege R100 laptop dual booting Win XP and Kubunutu-8.04. This was all done keeping the original XP install. All the issues encountered are equally applicable to Ubuntu and probably any recent distro.

I've complied these notes partly for my own benefit and partly to help anyone else attempting something similar. I've been a Linux user at work for a year, but this was my first Linux install and I decided a wanted an interesting challenge. It wasn't so bad and only took me a weekend because I was ultra cautious and also wanted to play with things (see what didn't work, below)

There are other notes online on how to do this on the web for other distros but since the machine is slightly old now I think so are most of the notes. The newer distros make some of the issues previously encountered easier to solve.

This was an interesting challenge because the machine has no floppy drive or CD ROM drive. The machine should be bootable from an USB floppy (and USB CD if updated to bios 1.06) but I possess neither. I also wanted to preserve the preinstalled Windows XP professional, installed on the only partition on the only HDD.

Step by Step - The useful summary:

1) Resize Hard Drive with Partition magic (justification in details below) - might be possible with Parted Magic but couldn't make it work.

2) Install Kubuntu iso image and grub4dos to C:\ (All taken care of by Unetbootin)

3) Boot LiveCD Kubuntu, things mostly work out of box - including wireless but res stuck at 800 x 640

4) Install Kubuntu from LiveCD iso:
Partitions: a) WinXP NTFS b) Kubuntu EXT3 c) swap d) Shared data NTFS. Sizes as you prefer.

5) I think the install must at this point overwrite your MBR with grub but it worked fine for me and then booted fine into my new Kubuntu.

6) Configure X to give me 1024 x 800 with this /etc/X11/xorg.conf (needs a sudo cp)

7) Fix the problem associated with changing the brightness of the LCD screen:
a) cd /boot/grub/ and use sudo pico menu.lst to add vga=791 to the line # defoptions=quiet splash (no need to uncomment)
b) sudo update-grub
8) Install all relevant laptop / hal / power / toshiba utilities from the package manager.

Everything works well, wireless, sound, hibernate, suspend, display full res, hotkeys, power mangement. Not yet tested, external displays - I believe VESA may be better for this option in which case use driver "vesa" in the xorg.conf device section and # comment the shadow FB option.

For the paranoid:

8) Install the System Rescue CD to C:\ with Unetbootin.
9) Copy the Linux drive from windows (Partition Magic?) to external USB.
10) Image the windows drive from Linux using partimag to external USB.

It may now also be possible to add parted magic in GRUB as another OS to boot from the spare partition, but we have already used partition magic once.

The detailed (longwinded) story:

************* Things that didn't work (or I was too lazy to try further) *****************

Note: Parted Magic (another linux live distro) and Partition Magic (Windows propriety software) are different things.

My first thought was to try and netboot the machine but this would have required installing a separate Linux distro on my Desktop, and then configuring a DCHP server and TFTP server which all seemed a lot.

The next idea was to try and make the machine boot from a USB pendrive. But since the bios only supports USB floppy and CDROM boot, you have to make the USB key appear to be one of these, USB-FDD or USB-CDROM as oppose to USB-ZIP. My attempts to create a bootable USB failed, other than for an MSDOS boot disk done with the HP pendrive utility which only worked on the desktop anyway. Attempts to write images to USB keys with Netbootin all failed to boot the Linux kernel, as did following the instructions on parted magic website exactly. I was not hardcore enough to go for the Hex editor... There are ideas that could have been explored here, but I was getting the feeling it would never work. I assumed the bios on both my desktop and the laptop cannot support the filesystem, or I possess the wrong type of USB key.

The last avenue left to explore was using Unetbootin to write an iso image to the HDD which it can then boot from there using grub4dos and the windows bootloader. It all works very nicely. Since this does not modify the MBR of the windows drive and only has to replace boot.ini, I was less nervous about using this method.

But before I made any more modifications to the windows installation, I wanted create an image of the drive. I used Unetbootin to write the iso of Parted Magic to the HDD. This got most of the way through booting but would not load the GUI (splashy complains about something). SystemRescueCD which contains Gparted booted fine, with GUI, but would not let me unmount the C:\ drive it was running from, hence no repartitioning could take place. Perhaps it should be possible with Parted Magic to load to Ram, unmount the drive then partition it but I was too lazy to try doing all this without the GUI. I think this cannot be done from inside Windows if the drive is in use (haven't tried Nero Ghost?. Partition Magic does it during windows boot but could not connect to my USB HDD. So I never managed to make the drive image I had wanted to at this stage.

Once grub4dos is installed It may also be possible to load USB devices from the grub commmand line and install / image / partion from there, but I only thought of this later.

************ What did Work: ************

So I resorted to the scary step of letting Partition Magic resize my windows drive without first being able to take an image (although I could of couse make normal windows backups). This worked but doing it with the non proprietary Parted Magic would have of course been preferable.

Back in windows with a smaller drive C:\, I then again used the impressively simple but effective Unetbootin to write the kubunutu-8.04 Live iso image to C:\ and booted it. The Live option worked well enough, so I installed from there. Most things worked out of the box, including wireless, but the resolution max was stuck at 800 x 640. This was fixed after reading a number of the previous installs above and cobblinging together my own xorg.conf (see above).

All that remained was to fix a problem which occured when the LCD brightness was changed (either manually or by pluggin / unpluggin AC power) and described above. Finally, installing relevant hal / toshiba / power managment packages was easy and now everything seems to work fine.

As a testament, I wrote this in notepad on XP then rebooted to kubuntu to get the xorg.conf file for your delectation.

4 comments:

pigling said...

Hi,
your post is an great information since the Trident driver is not supported well after Ubuntu 7.04. I installed 6.06 on my R100 and the display was OK. After I changed to 8.04, the X config can't auto detect the display well and the screen resize. Your xorg.conf is very helpful for me. But another issue is reboot problem. Before I solve the resolution issue the reboot can work well. HOWEVER, NOW HDD SEEMS STOP RUNNING AFTER LOG OFF.Any comments? Thanks.

henghengheng said...

flash drive does not detect problems at primary. Visit. http://www.utilitiessoftware.org/flash-drive-does-not-detect.

floppydriveto said...

Hi, very nice post about floppy Dirive.Upgrade Floppy Drive to USB with Floppy to USB to use USB as floppy. These devices enable old machines to use USB as floppy.

FC said...
This comment has been removed by a blog administrator.