If you follow the posts on this site, you'd have noticed my issues with the recent Hardy upgrade. While I thought they'd been fixed in my fstab, this was apparently not the case. When I rebooted the machine next, I couldn't even get to the shell as I encountered the message - Unable to execute /bin/sh - Permission Denied.
The error message essentially means that you have fucked up your fstab and set the root partition to read-only. To fix this, you will need to access the fstab and amend it to be writable or in the more plausible scenario, remove the duplicate read-only mount for the root partition from your fstab. To access the fstab, you will need to either move the drive to another machine or boot-up using a Live CD like Knoppix or even that of your distro, mount the root partition and perform the amendments.
In my case, this whole affair occurred because of the aforementioned upgrade - this is not Kubuntu's fault btw - where the new version of the Linux kernel decided to standardise all hard disc denotations to sdX rather than use hdX for PATA and sdX for SCSI (and SATA) drives. This wreaked havoc on my box where my mount point all got messed up due to the fact that my hda drive was now my sda, my sda was now my sdb ad infinitum. Furthermore, this happened because my fstab mount entries were based on partition denotations rather than their UUIDs. UUIDs are effectively constants whereas partition denotations can be variable as seen here.
The UUIDs for each partition can been seen by typing blkid in a terminal.
The fix:
/dev/sdb1 /media/video auto nouser,atime,auto,rw,nodev,noexec,nosuid 0 0
would become
UUID=2b12354a-4fbf-4540-9913-d2a349732b1e /media/video auto nouser,atime,auto,rw,nodev,noexec,nosuid 0 0
As mentioned above, use the blkid command to find the UUIDs for each partition. You can open another terminal window to do this.
Hope this helps somebody out there!
Comments
Went half crazy for a couple
Went half crazy for a couple of hours until finding this post. If it were not for your tip of a scrambled fstab I would never, ever have found the problem. Your tip has transformed what was going to be a reinstall fest into a very simple fix.
Thanks again.