9

I was trying to change the ownership on an external drive, and mistakenly used

sudo chown -RL myuser:myuser /media/"New Volume"

Unfortunately, it changed the ownership on the entire drive to myuser. I've since changed the ownership back to root on everything except the /home/myuser directory. But, I still have problems, such as google-chrome didn't work anymore, I can't see mounted drives, and pulseaudio doesn't work. (There are probably more -- but these were enough to make me want to fix this).

I downloaded the Ubuntu 12.04 LTS DVD (x86_64) and am booted into it right now. When I try to do the installation, I don't have an option to Upgrade from 12.04 to 12.04 (Possibly this is due to the fact that I have two partitions:

  • Ubuntu 12.04
  • Linux From Scratch

So my questions are these:

  1. How do I do an upgrade (if possible)?
  2. If I have to reinstall, and choose not to format the partition that my / is on (which includes /home, /bin, /usr, /etc, and so on), what will I lose (It says that it will delete everything in /etc /usr /bin ....)?

2 Answers 2

6

First, you should really have a backup of your personal data, because harddisks are crashing all the time.

Second, I would recommend a complete reinstallation, because getting to the bottom of your problems is quite hard to accomplish.

To make things not too hard you can remember all the packages you installed via apt/dpkg by using

$ dpkg --get-selections "*" > package.list

then save that file somewhere save, reinstall, and restore the package selection.

$ sudo dpkg --set-selections < package.list
$ sudo apt-get -u dselect-upgrade

The restore your the data you backuped before and you should be good to go.

0

In the end, I did the 'Something Else' option, and selected my root drive without formatting it. It wiped out most of my third party programs (read as Google Chrome and a few others), but kept some of them (Skype, XBMC, etc).

I agree about the complete reinstallation in most (almost all) circumstances. In my specific case, my problem was that I took ownership of / and all of it's subdirectories. So, I didn't need a complete reinstallation--only a repair of the permissions and ownerships. The only "easy" way I saw was to try the 'Something Else' option.

In my specific case, it wasn't a fear of losing data--only having to reinstall all of my programs and settings. Knowing the steps that you suggested from dpkg makes that a lot easier.

I'm joining the call to make a "Repair Installation" option (or disc) for Ubuntu (and linux in general). Even if it just be doing the dpkg steps that you mentioned,

2
  • Something that'd be fixing file permissions, as in resetting them to their default dpkg state, would be awesome.
    – mweinelt
    May 12, 2012 at 11:16
  • I would echo this call for a repair option. It's too easy to break a ubuntu installation. Apr 8, 2014 at 19:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .