How to repair a broken Ubuntu Desktop installation
I was trying to install Ubuntu Server 6.10 (Edgy) in a virtual machine and as noted earlier in one of the posts, Ubuntu server does not install the desktop component (ubuntu-desktop) by default. You have to install it separately (a download of around 1.5 Gb) if you want it.
I tried to install it on the VM from my previous knowledge by running the following command.
mukul@usrvr:~$ sudo apt-get install ubuntu-desktop
Ubuntu downloads the desktop component and configures it. While configuring, it asked me for the screen resolution to use. I happily gave it the resolution that my monitor support 1400x1050. Ubuntu was taking a long time to complete the configuration so I thought maybe the VM was not able to support the resolution and panicked and shutdown Ubuntu abnormally by closing the VM. When I next tried to restarted Ubuntu, it completed loading around 85% and then hung there. I tried a couple of times to reboot unsuccessfully. By now I had realised that I had totally messed up the desktop installation and was thinking about removing it and reinstalling it. Command to do it:
mukul@usrvr:~$ sudo apt-get remove ubuntu-desktop
While booting, Ubuntu provides a way to go into boot menu just like any other operating system and in the menu it provides an option to boot into recovery mode. The recovery mode is nothing but the "Safe mode" that we are all very much familiar in the Windows world. The recovery mode essentially provided me with root access to the file system without asking for the login prompt. Once I was at the bash prompt, I entered the command mentioned above to remove the desktop and it gave me a very helpful message saying that dpkg was aborted during configure and to fix it Ubuntu gave me the command to run.
mukul@usrvr:~$ sudo dpkg --configure -a
Once I ran the command above, it started running the configuration of the desktop from where it had left and completed the installation without further troubles.
- Category(s)
- Linux
- Computer Tip
- The URL to Trackback this entry is:
- http://www.dharwadkar.com/weblog/ubuntu04/tbping

Unfortunatly my installation is now corrupted and hangs even when I try to boot into safe mode.
Do you know of a way to get in there so I can finnish the upgrade? I have the live CD for Dapper 6.06 but don't know how to find out which bit is broken so I can fix it, and I can't use apt-get because it will be referencing the live CD not my instalation.
I've posted on the ubuntu forums but no one has got back to me yet.
Hope I'm not defacing you blog with this comment but I'd really apreciate any help you can offer me.
Thanks
I would certainly be glad to help you. But I don't have any means to contact you. You can send me an email on my email address which I have published here on my website. Although I cannot guarantee that I will be able to help, but I can certainly try...
Mukul Dharwadkar
I can help you fix your problem. However, you did not provide me with any contact information. You can contact me on my email given out in the About Us page.
Apparently there was some work in the background and the process continued itself later when left alone.