Sunday, September 5, 2010

The Beginning...

This blog is going to server as my Ubuntu Lucid Lynx installation record. I meant to do this after (and during) my Karmic Koala install so I am doing it now. Why now? I made a big mistake before beginning my upgrade process from Karmic to Lucid and want to document the process, the programs and commands I like to use (which I know I will forget later). Makes sense, right?

History:
In preparation of my move to Lucid, I figured it was time to backup my /home directory as 10.04 had been out for a while and now was listed as 10.04.1. I began searching for a tool to help my backup operation. I found a few, one of them being LuckyBackup (http://luckybackup.sourceforge.net/manual.html) which itself uses rsync. I began using the program and it appeared to be working quite well. I was backing up my /home dir and thought I'd go ahead and backup /etc, /usr/local and /var (as recommended by sbackup). In the process I messed up the permissions on those special directories by doing a synchronization back from the external drive (read point 3: http://luckybackup.sourceforge.net/manual.html#OperationType). I should have read the instructions *before* beginning the backup process. LuckyBackup is a great program and it isn't at fault for what happened. It did exactly what I told it to do. If you use it, be sure to read the instructions (note to self: heed own advice). Oh well, this is how I learn!

To make matters worse and because the permissions were changed, I could no longer use sudo to try and fix things. Failed attempts at rebooting and changing a few permissions didn't work. I thought maybe performing the upgrade from Karmic to Lucid could possibly fix the permission issues. It did not. So after a failed upgrade (some parts were upgraded, some weren't), I tried to repair the permission issues further with no luck (by looking at what the permissions *might be* using another machine with Karmic loaded via Virtual Box). Now what?

I talked with Nate (linux user and comrade) and he led me to a couple of resources: http://ubuntuforums.org/showthread.php?t=166626 and http://www.linuxquestions.org/questions/ubuntu-63/can-i-delete-and-reinstall-ubuntu-8-04-and-keep-a-home-partition-697267/. Read up a bit and decided to go for it!

To start, I ended up booting up the Lucid live CD, getting a desktop (which loaded all the internal drives) and backed up my /home dir once more (paranoia) using rsync (rsync -avzhPn --exclude='/*/.gvfs' /home/<userdir> /media/<location>/<dir>) to the external and a new directory. (I now have my /home dir backed up three times.) With that done, I started the clean install process by choosing the Install option from the Live CD.

I setup Karmic originally with three ext4 partitions: root, home and swap . I chose to format / (sda1) which got rid of the old Karmic installation, kept my /home (sda2) partition untouched (no format) and elected to format /swap (sda3). (Choosing to format /swap is irrelevant as it will occur if you don't select the format option!)

The installation proceeded, finished successfully and I was at a new shiny 10.04 login screen. I logged in using my old /home user but found I could not setup any new users. I dropped into terminal, added a new user as admin and was able to login and perform all the sudo duties. This meant there was a problem with my /home dir. Well, let's try again.

I booted up the Lucid Live CD to a desktop, used ctrl-alt-f1 to get into terminal (after loading the internal drives), logged-in (by default using the Live CD, this gives root access), renamed the /home user dir, used ctrl-D to logout, used alt-f7 to get back to the desktop and started the install again. After it completed, I was able to login and everything is working as expected now. Now, on to configuring Lucid so I can do all the things I was doing before when Karmic was rock solid.

Prior to installing:
Backup /home to external (my /home dir is on a separate partition; I want to make sure I don't lose anything before the upgrade - so far so good)
commands: rsync -avzhPn --exclude='/*/.gvfs' /home/<userdir> /media/<location>/<dir>
rename /home/user to /home/user_bak - after install I will use beyond compare to diff the two and bring back any settings (like .mozilla profiles, etc)
commands: mv /home/user /home/user_bak

Installing:
Install Lucid from Live CD
Format sda1 and sda3 (root and swap), leave sda2 (home) untouched

Post install:
install nVidia recommended video driver (as opposed to version 173 listed - both found under system > administration > hardware drivers; which one is better?)
install scooter's beyond compare (for diff functions) - http://www.scootersoftware.com/download.php
install x.flux (for saving the eyes; it works in windows too) - http://www.stereopsis.com/flux/

To Do:
install wifi drivers - need to compare B43 vs. STA
check backup of /etc/ sources list
backup sources.list and then edit (changing Karmic references; reconfigure for Lucid)
make list of useful commands (i.e. lspci, ls, modprobe, ps, adduser, deluser, userdel, useradd and others)
make list of useful keyboard strokes (i.e. ctrl-alt-f1, ctrl-alt-f7, f2 and others)
make list of software to install (compiz, gnomedo, zenmap, ubuntu tweak and others)

No comments:

Post a Comment