Menu Close

Minor performance tweaks for Ubuntu Intrepid (8.10)

First of all. This tutorial is about editing system files. DO remember that if you edit files wrong you’ll very easily get yourself a nice non-bootable system that takes some knowledge of linux to restore back to functional. Be careful…

 

Here are some tweaks and ways to improve performance on your Ubuntu Intrepid install. First of all I’ll suggest to download sysv-rc-conf program to edit loaded components during bootup. This way of course you can reduce amount of memory used.
Code:
sudo apt-get install sysv-rc-conf

This program is to be run from terminal with command
Code:
sudo sysv-rc-conf

You’ll see list of components loaded and in which runlevel during bootup. Use command man sysv-rc-conf to read it’s manual to get more depth in using it. Quickly mentioned, use arrow keys to move cursor and use spacebar to enable/disable processes. Press q key to quit program and save settings.

NOTE that many processes are required for functional system so DO NOT think about just disabling everything. As always you can easily figure out what example cups means and how? Use google, _very_ easily find out. For example I’ve disabled following completely

cups, anacron, cron, klogd, laptopmode, powernowd (both), sysklogd and usplash

As said use google to find out which are essential to you. Hint, you won’t be able to use some timed events, print and some log events are disabled with those. IT’S your job to figure out what to disable here. We all have different need of our installs so there are no absolutely right or wrong processes here. USE that google instead of asking. It’s system settings you’re about to fiddle with. Learn them if you’re about to change them. If in doubt or too lazy to learn, best to leave them alone completely

Ok, I’ll ease up now and suggest you leave readahead untouched on sysv-rc-conf if you want to increase your bootup time, we’ll get to that soon. First I’d suggest edit /etc/fstab file with command
Code:
sudo gedit /etc/fstab
and edit relatime parameter to noatime.
Here’s example (DO NOT COPY PASTE THIS LINE DIRECTLY TO YOUR FILE OR YOUR SYSTEM WON’T BOOT AT ALL) line from file.

Code:
UUID=5669a0b4-9105-46ed-ab0c-80a9efbf025b /               ext3    relatime,errors=remount-ro 0       1

Above is something you should see if used default install method. Note relatime parameter, change it way it’s below
Code:
UUID=5669a0b4-9105-46ed-ab0c-80a9efbf025b /               ext3    noatime,errors=remount-ro 0       1

This should have little improving effect on read and write to hard drive. It disables inode access time updating. Google is once again a very good friend of you to figure out more in depth.

Now to already mentioned readahead. With following we’ll profile bootup of system. Note that this is done one simply one startup and is meant to be used only after you have changed launched programs with sysv-rc-conf and/or changed your kernel completely.

Let’s see our /etc/kboot.conf file. Here’s example of my Intrepid launching line
Code:
Ubuntu Intrepid=’/boot/vmlinux initrd=/boot/initrd.img root=UUID=5669a0b4-9105-46ed-ab0c-80a9efbf025b video=ps3fb=4′

This is how it’s on my system when normal bootup is done. Now let’s add profile to this line, so that it’ll look like this
Code:
Ubuntu Intrepid=’/boot/vmlinux initrd=/boot/initrd.img root=UUID=5669a0b4-9105-46ed-ab0c-80a9efbf025b video=ps3fb=4 profile’

Save and reboot your system. If you have discarded options quiet and splash (what I suggest to do) you’ll now notice that bootup takes significantly longer than before. This is normal as system creates profile of booting processes and saves them. You should see profile word for sometime during boot. When system has booted change /etc/kboot.conf file back. Remove that profile word from file. Now your system should bootup quite much faster because of readahead. I could see definitely improvement in bootup speed.

As always make backups of system files you’re about to edit and think twice before you try to change something.

Here’s only few methods to speedup things. I haven’t disabled nearly all the things I want to from my sysv-rc-conf settings, because of I haven’t checked out how changing of some of them affects system. Apport I won’t disable for sometime as it’s used for bugreporting because Intrepid isn’t ready just yet and I plant to report bugs I notice etc.

One more hint. Check out program bootchart which should be found in repositories. If you do some research you’ll notice it to be very handy tool to checkout which processes exactly take much time during boot. There’s dozens of topics about how to use it. Now I don’t have time to write about it and likely you’ll easily find out very clear and helpful howto’s how to use it from Ubuntu’s forums.

17 total views, 1 views today

Leave a Reply

avatar

This site uses Akismet to reduce spam. Learn how your comment data is processed.

  Subscribe  
Notify of