Triple booting WinXP, Ubuntu and RHEL – an experience
This post is my experience, good and not-so-good, on my first stab into triple booting on a laptop.
Ok, I started with WinXP obviously since the OS always overwrites the MBR entirely and hence a bad choice as a second or third OS. I created one system partition for WinXP OS+apps and one user partition for what we care most about. Both are NTFS. Also, I don’t have any plans to move to Vista in the shorter term also.
Next, I choose to install RHEL5. The reason is that, RHEL5 is a more mature and slow-moving linux distribution and has typical life-cycle of about 2 years between major releases. Compared with this, Ubuntu’s objective is to bring to the end-user latest, greatest software every 6 months. Since I normally move to the latest Ubuntu version by default, I thought having RHEL in first as second OS is a good decision.
So, I installed RHEL with a /boot, /, /home, swap partitions and checked that everything was in order with the root and a normal user accounts. So far, so good…
Now, my first question…
Although, Linux distributions have for a long time are good at recognizing windows and setting up properly the boot loader, they are not so good at recognizing another Linux distribution. From my experience so far, a second Linux distribution has never been able to recognize another Linux distribution and the user had to choose either to rewrite the boot loader and add in the first Linux distribution or choose not to install the boot loader from the second Linux distribution and then add in the second Linux distribution in the boot loader. Either way, user had to tweak with grub.conf to put a new stanza to make the missing Linux distribution work !!
With this task in my to-do list, I installed Ubuntu 7.04 on a separate /boot, / partitions but decided to share the /home and swap partitions with the RHEL installation. I thought this was the best way to converse space and also to share data since they contain only user data.
My first good shock…
Once Ubuntu was installed and on first boot the grub boot loader showed under “other operating systems”… WindowsXP and RHEL.
My first expression was that, oh my god, he is doing it by default and playing a fair game. I was very relieved and had a good sense of feeling flowing through me, “Linux is almost in the desktop space”… it was like the words “a small step for a man, a giant step for mankind”… re-written as “a small step for ubuntu, a giant step for linux distributions”
As part of the ubuntu installation, I choose to use the same username that was created in the RHEL installation. It should be noted here that, under ubuntu the first account by default is given ’sudo’ access where as ’sudo’ access is disabled by default in RHEL distribution and the users are normal users. I am also using the same home directory as well.
Now, I continued booting into Ubuntu…
My first not-so-good experience.
The login into gnome caused some errors and logged me out of the system in 10 seconds. I logged in using ctrl+alt+f1 and figured out that my home directory did not belong to me any more! After a little investigation, I found that Ubuntu names its users from UID 500 whereas RHEL used UID from 1000 onwards. Since, I was using the same home directory, when I installed Ubuntu it did not replace the home directory nor any of the configuration files in it that was created by RHEL installation. To make things easy, I moved the UIDs of RHEL distro to be that of Ubuntu distro. I created a few more users under RHEL and observed that RHEL continued the sequence of Ubuntu UIDs.
After the fix-up I checked that I am able to login and completed the pending updates which proved that my ’sudo’ access was working! Everything seemed to be OK. Just to be double sure, I wished to boot back into the RHEL distribution to see everything is still fine.
My next not-so-good experience
When RHEL was booting up, I noticed the error message “unable to access resume device ’swap-sda8′”. I googled for it and found that the swap partition was not being mounted for many users in fedora distribution. One user reported that doing ’swapoff, mkswap, swapon’ solved this problem. I wanted to check some thing else before trying this advice partly because the solution was for fedora and not directly to RHEL, although these distributions are siblings at best. Ok, I went on to check the ‘/etc/fstab’ in both the distributions. I observed that while RHEL was using ‘LABEL’, Ubuntu was using UUID to identify the partitions in the hard disk. I thought this could be the problem since since my case is unique in that I am dual-booting two Linux distributions. Since, Ubuntu was installed after RHEL I decided to copy the line for Ubuntu fstab file into the RHEL fstab file. I did that and still during next boot of RHEL, the error kept appearing. So, I tried the forum solution and the error was gone to my relief.
Now, I booted into RHEL and logged in as root and the login was OK. I applied the pending updates through rhn_register & yum and everything seems to be fine. Now, I logged into the normal shared user account and out-of-blue tens of warning dialogs appeared and after clicking ‘ok’ to each of them, I was left with a black desktop, no toolbars of any kind but with desktop icons. I couldn’t pretty much do anything and so hit ctrl+alt+backspace and restarted X. Tried again, same behaviour. Tried again as root user and everything seems to be OK. My thoughts were that, Ubuntu replaced the configuration files used by RHEL and this caused the login problems for RHEL. To confirm this, I created another user account under RHEL and confirmed that I was able to login into the system. I backed up the ‘.’ files and ‘.’ directories created under RHEL and then proceeded to login into ubuntu. I was able to login, not surprised! then expecting for sure in RHEL, I booted back into RHEL and was shocked to be able to login in properly. I am confused, in that I am not able to reproduce the error…
The only conclusion I could come is that I did this experiment some weeks ago and at that time I recall that I was having some problems with the ubuntu installation specifically the new accelerated binary driver which had the cool desktop effects. Now, from the experiments and the results I believe that after the binary driver was loaded, I should have booted into RHEL which caused the GUI panic in GNOME. Since, the driver was not stable in that it crippled some elements in GNOME, I have since disabled it. As part of complete resolution, I had to completely remove all ‘.’ files/folders in the home directory in ubuntu and start all over again. Now, to write this entry I don’t want to try again with the binary driver stuff
Inference:
1. I believe that the UID used by different Linux distribution are a minor concern. Can this starting UID be set somewhere in the installation wizard ?
2. The common partitions, usually the home and swap partitions need to checked after installation of the second or third linux distributions.
3. Is it possible that different gnome versions use different configuration file formats which are not backward-compatible ? since I am was able to login from command line initially when GUI was causing problems.
I would like to suggest/propose/enquire if it is possible to have different master configuration root directories ? that is currently the home directory contain all the configuration files and directories…instead if each distro maintains its own set of configuration files inside, say .rhel5 or .ubuntu704 folders in the home directory ?
If you have any suggestions or hints do post a reply
Category: Computer Science Comment »