Tag Archives: Ubuntu

Fixing Ubuntu 11.04 after a problematic installation

As I wrote earlier, I had problems installing Ubuntu 11.04 on my laptop, but after som fights I managed to have a computer running Natty Narwhal.

But not everything was fine though: there was no time-out in GRUB2 and starting daemons like Apache didn’t work.

For the first issue, my laptop could display GRUB until I pressed the enter key. Setting the timeout in /etc/default/grub was useless. Obviously the install wasn’t fine so I corrected this by reinstalling GRUB:

I’m not sure the last line is necessary, hopefully apt-get takes care of updating GRUB, but it’s better to write one line too much than having a system which can’t start.

The other issue was starting daemons. Ubuntu doesn’t use anymore the System-V init but another system called Upstart. But Apache and MySQL didn’t start at boot time, and when I wanted to start them I got Warning: Fake initctl called, doing nothing. As above, the install was corrupted and I had to reinstall upstart:

My computer is better now, but I might reinstall more packages as soon as I have other issues.

An Ubuntu 11.04 install story

Two days ago Ubuntu 11.04 was released. I didn’t want to upgrade my system that day, but this silly box announcing a new Ubuntu release when I logged into my system tempted me a lot and yes, I clicked on the upgrade button.

The process began, and obviously I wasn’t the only one upgrading because the download speed was very slow. I stopped it and I downloaded the install CD via Bittorrent instead. That was quickly finished. I made a live USB and rebooted my computer. I didn’t want to try Ubuntu live, so I clicked on the install Ubuntu button, and after answering a few questions the installation upgrade began.

When I went back my screen was black with a lot of system messages and it was freezed, which is of course very unpleasant when you’re installing/upgrading your system. I could reboot and this went fine. But when I came to GDM, my usual username wasn’t listed and after a few tries I had to admit that I couldn’t log in. I rebooted again the LiveUSB, and reinstalled Ubuntu. Then I could come into the system but I had no wireless. I rebooted again in Ubuntu live, in which I could access the Internet.

I looked for this issue of freezing installation and I found that I wasn’t the only one. But I found also this page, which was very useful. So I did this:

sudo mkdir /media/fix
sudo mount /dev/sda6 /media/fix
sudo chroot /media/fix su

Then I checked that everything was correctly downloaded, since the installer freezed:
apt-get update
apt-get upgrade
apt-get dist-upgrade

apt-get was happy so I supposed that the system was okay.

I rebooted again and well, I could log in, but still no wireless available. Then I realised that my grub menu listed the same kernel as the previous release (2.6.35) instead of 2.6.38. I made a
sudo update-grub
and grub showed me the new kernel. I selected it, booted and now I have a nice Ubuntu 11.04 with the WiFi working :-)

Theme crash in Ubuntu 10.10

From what I can read it’s a common issue for many people using Ubuntu 10.10, at least among the users of the 64-bits version. There are two bugs reported in launchpad: here and here.

After several months without problem, I just experienced this issue… and the two solutions given in Launchpad (aptitude reinstall gnome-settings-daemon and sleep 2) don’t help at all.

So, how to deal with that? Well, it’s simple: just open a terminal window and in it write:
$ gnome-settings-daemon

Now the theme is restored, but the icons in the file manager still look bad. That’s because of Nautilus the file manager. You have to kill it. Yes, kill it:
$ killall nautilus

So Nautilus will be restarted after that, with the right icons. You can now close your terminal window and go back to a normal life.

I hope the Ubuntu people will fix this issue before the release of the next version, Natty Narwhal, which should be released this month.

How to change the timeout in GRUB2?

Sometimes booting your Linux system can be relatively long. It depends often on how many services your system needs to start while booting.

There’s also a phase which takes time: the boot-loader. It displays a menu in which you can choose which kernel to use or starting another operating system. If you don’t choose anything, there is a timeout and then the boot-loader picks up the default kernel/operating system.

Ubuntu 10.10 sets this timeout to 10 seconds which can be seen as long. It’s possible to change that.

How? Well the boot-loader used by Ubuntu is GRUB2. Since 9.10 (Karmic Koala) and the file for configuring it is /etc/default/grub.

In Ubuntu you need to use sudo for editing this file (replace emacs by your editor of choice):
sudo emacs /etc/default/grub

Then you need to find the setting GRUB_TIMEOUT and change its value to 3 seconds for instance:
GRUB_TIMEOUT=3

Save the file and you have done most of the work!

To achieve it, you need now to run update-grub to update the file /boot/grub/grub.cfg:
~$ sudo update-grub
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.35-22-generic
Found initrd image: /boot/initrd.img-2.6.35-22-generic
Found linux image: /boot/vmlinuz-2.6.32-25-generic
Found initrd image: /boot/initrd.img-2.6.32-25-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Windows 7 (loader) on /dev/sda1
done
~$

You can now reboot your system if you want to test it :-)