Claws – I’ve moved to it.

I have been hearing a lot about an email client called Claws that’s giving Thunderbird a run for its money. Being a big fan of Thunderbird, I couldn’t hold myself anymore and decided to finally try it out this weekend. Much to my surprise I’m not planning to move back to Thunderbird.

Claws isn’t a feature enriched email client. It definitely is extensible via plugins just like Thunderbird, though the number of plugins available is limited. It is an elegant, fast and highly configurable email client. Every action in Claws has a keyboard shortcut which is a delight to the power user. A couple of dozen themes does help the user decide how she/he likes her/his eye candy. I personally fell in love with Claws for its minimal resource usage and load up speed and most importantly how efficiently it gets the job done. I do not say that Claws is the best available email client, but I’m sure that there are a hell lot of users who are wasting resources for no practical reason by being content with their current email client. Give Claws a try, who knows you may too get hooked to it.



Fluxbox Myths Cleared Up

In the month of August I got an article called “Fluxbox – A superior window manager” published in the Linux For You magazine. I assumed that most of the things I knew about this window manager were right, till I got my article reviewed by few of the fluxbox developers themselves.

Here are a list of things I got cleared recently:

a) Blackbox themes are not likely to work in Fluxbox. (Not anymore atleast)

b) fluxconf is way beyond a recent version of Fluxbox. Using fluxconf is not from the fluxbox team and when used with a recent version messes up the config (most likely the keys file) , in a way that fluxbox becomes unusable.

c)  cd /etc/X11/fluxbox/

cp fluxbox-menu init keys ~/.fluxbox/

cd ~/.fluxbox

sudo mv fluxbox-menu menu

touch apps

All the above mentioned steps are not required. Fluxbox itself copies these files, if not you have a faulty Fluxbox.

d) Its best not to use fluxbox-generate_menu. In case you are using a Debian/Debian based distro update-menus can be used instead. fbgm is just a wild-guessing-and-checking-tool on the other hand the update-menus actually checks for programs installed and generates a menu.

e) From version 1.1.1 onwards things are a little different. For example in the keys file you will find entries like:

OnDesktop Mouse5 :prevWorkspace

OnDesktop Mouse4 :nextWorkspace

OnWindow Mod4 Mouse1 :StartMoving

OnWindow Mod4 Mouse3 :StartResizing NearestCorner

And you can do something like “if currentwindow has title Mozilla-Firefox do this otherwise do that”

Isn’t that cool :).

Thats it so far. Will keep updating this page in case I get to know more.

Tweak kernel variables in sysctl.conf

Kernel variables can be tweaked to increase security or performance of the system. To get a lot of these settings working across reboots it can be stored in the /etc/sysctl.conf file. For the values to get applied immediately after editing this file, this command should be issued:

#sysctl -p

This is how my file looks like. The kernel used is a 2.6.24 and the os is Ubuntu 7.04.

# /etc/sysctl.conf – Configuration file for setting system variables
# See sysctl.conf (5) for information.

#kernel.domainname =

# the following stops low-level messages on console
kernel.printk = 4 4 1 7

# Functions previously found in netbase

# Uncomment the next line to enable packet forwarding for IPv4

# Uncomment the next line to enable packet forwarding for IPv6

## The below lines are manually added — stan



# increase system IP port limits
net.ipv4.ip_local_port_range = 1024 65536

# kernel will reboot after a panic in 10 seconds
kernel.panic = 10

# Increase the maximum and default receive socket buffer size
net.core.rmem_default = 524288
net.core.rmem_max = 524288

# Increase the maximum and default send socket buffer size
net.core.wmem_default = 524288
net.core.wmem_max = 524288

# Increase the maximum TCP write-buffer-space allocatable
net.ipv4.tcp_wmem = 4096 87380 524288

# Increase the maximum TCP read-buffer space allocatable
net.ipv4.tcp_rmem = 4096 87380 524288

# Increase the maximum total TCP buffer-space allocatable
net.ipv4.tcp_mem = 524288 524288 524288

# Increase the tcp-time-wait buckets pool size
net.ipv4.tcp_max_tw_buckets = 1440000

net.ipv4.tcp_rfc1337 = 1
net.ipv4.ip_no_pmtu_disc = 0
net.ipv4.tcp_sack = 1
net.ipv4.tcp_fack = 1
net.ipv4.tcp_window_scaling = 1
net.ipv4.tcp_timestamps = 1
net.ipv4.tcp_ecn = 0
net.ipv4.route.flush = 1

# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 1

# Controls whether core dumps will append the PID to the core filename.
# # Useful for debugging multi-threaded applications.
# kernel.core_uses_pid = 1

#Prevent SYN attack by enabling TCP/IP SYN cookies
net.ipv4.tcp_syncookies = 1
net.ipv4.tcp_max_syn_backlog = 2048
net.ipv4.tcp_synack_retries = 2

# Disables IP source routing
net.ipv4.conf.all.accept_source_route = 0
net.ipv4.conf.lo.accept_source_route = 0
net.ipv4.conf.eth0.accept_source_route = 0
net.ipv4.conf.default.accept_source_route = 0

# Enable IP spoofing protection, turn on source route verification
net.ipv4.conf.all.rp_filter = 1
net.ipv4.conf.lo.rp_filter = 1
net.ipv4.conf.eth0.rp_filter = 1
net.ipv4.conf.default.rp_filter = 1

# Disable ICMP Redirect Acceptance
net.ipv4.conf.all.accept_redirects = 0
net.ipv4.conf.lo.accept_redirects = 0
net.ipv4.conf.eth0.accept_redirects = 0
net.ipv4.conf.default.accept_redirects = 0

# Enable Log Spoofed Packets, Source Routed Packets, Redirect Packets
net.ipv4.conf.all.log_martians = 1
net.ipv4.conf.lo.log_martians = 1
net.ipv4.conf.eth0.log_martians = 1

# Enable bad error message Protection
net.ipv4.icmp_ignore_bogus_error_responses = 1

# Set maximum amount of memory allocated to shm to 256M
kernel.shmmax = 268435456

# Increase the maximum memory used to reassemble IP fragments
net.ipv4.ipfrag_high_thresh = 512000
net.ipv4.ipfrag_low_thresh = 446464

# Increase the maximum amount of option memory buffers
net.core.optmem_max = 57344


These values are stored in files under the /proc/sys/ directory. Its simple to understand and generate newer variables. The forward slashes are changed to dot in the variable name. For example a variable called vm.swappiness would mean the value stored in the file /proc/sys/vm/swappiness.

These values are tweaked to give my desktop better performance. Do let me know if i can further increase it.


Linux Performance Tweaks

Not too long ago my boss and myself came up with a wise idea to make a list of all the linux tweaks usually done to improve the performance of a linux system. The idea has been taken to a higher level and each and every silly possible change that could improve the performance of the system has been added. Of course the actual list would be never ending, but these are a few that I could think of. Do mail me if you think of more that can be added.

The first thing to look at a brand new machine is its BIOS. There is a lot of junk in there that you may never require. For example, if the machine is going to be used as a file server the on-board sound card is never going to be used, or if the machine is never to be connected to a lan why leave the on-board lan card enabled. If the system is going to be run in text mode only the shared graphics memory required should not be more than 2MB. All these changes should be done according to requirement.

During installation do try your best to avoid software raid and lvm unless absolutely required. These are two lovely features but both of ’em degrade performance considerably. The next most important thing is to use a kernel that’s suitable to your processor architecture. For example, if you have a 686 processor use a i686 kernel, if you have a 586 processor use a i586 kernel and if you have multiple processors/cores use the smp kernel. These are the 3 most common kernels provided with any modern distribution.

Most of us know that ext2/ext3 is the filesystem that has to be used during installation. No doubt that the ext2/ext3 file system is very reliable but if you are seriously looking forward towards a faster and much more responsive system ext2/ext3 is a bad option. Xfs is by far the fastest filesystem, and if you are dealing with many small files reiserfs is the best. If you have a directory with many different types of files, try to break it up. it definitely will improve performance. Oh, and do use a lighter file manager. Something like Thunar is great.

The next thing of course is to disable the services you never use frequently. Services like ‘timidity’ and ‘apache’ may very rarely be used by you. Well you can always start them when required. Running services when not required is such a waste of resources. Imagine running a service such as ‘postgresql’ when all that you are doing with you system is browsing the Internet.

‘Prelink” drastically speeds up application start-up times. There are a lot of benchmarks done with and without prelink just to prove its superiority. In most modern distributions prelink is very stable and reliable.

Avoid using stuff like Kat, Beagle, Evolution etc. etc. At times these apps make the system so unusable. There are much more lighter apps to get your work done. Take for instance, to do a quick word processing job why use ‘OpenOffice Writer’ when Abiword (which is much more lighter) can do the job just fine.

Use a light window manager. My best suggestion WindowMaker. Fluxbox also does a fine job. Well it will take you some time to get used to it. Hey but life is all about changes. I mean, when i started using computers i never knew what linux was. You just adapt to whatever suits you.
Well, i know that the above suggestion is not a easy one, but if you are using something like Gnome or KDE avoid using many taskbar applets. Those are real resource hungry. Also wallpapers, icons and files/folders on the desktop consume resources. In linux you have a central storage for each user, so use it for all your files. It keeps your system a lot cleaner, your desktop clear, and you can keep things more organized (atleast i can).

My greatest suggestion in this entire article would be to stay abreast with the latest distro. The only way to achieve this is to have a separate /home partition. So the next time you install a new distro, do not format your /home partition but only all the others for the installer to install the required packages and their related files. Packages change over time, Xorg is better than Xfree, Alsa is better than Oss, Udev is better than devfs. Most of all the kernel undergoes major changes, many of which are performance related.
Most of the latest distros have packages that are compiled using GCC 3.4 and upwards. GCC 3.4 compiles programs so they run at least 7% faster. Do you really want to miss out on such good performance gains?

For ext3 filesystems “noatime” and “data=writeback” are good options to have in the ‘/etc/fstab’ file.
/dev/hda1 / ext3 defaults,errors=remount-ro,noatime,auto,rw,dev,exec,suid,nouser,data=writeback 0 1
And for reiserfs add the option “notail” but remove “data=writeback”
/dev/hda7 /boot reiserfs noauto,noatime,notail

Six text-mode virtual consoles are absolutely unwanted for a user like me, and considering that each of these virtual consoles consume memory turns me off. Comment out the lines for the unwanted virtual consoles in ‘/etc/inittab’ and issue the command “init q” as root to make changes done without rebooting.

In most of the modern machines with 512MB and more ram a lot of swapping is not required. The more the swapping done when there is enough ram to do the job is a waste of performance. The default value is vm.swappiness=60. To change it issue “echo ‘vm.swappiness=<value>’ >> /etc/sysctl.conf” as root. Then issue #swapoff -a and #swapon -a. Generally a value from 20-30 is great for most modern machines. Find the right value that suits your needs.
The swap partition has to be created roughly in the middle of the harddisk for it to be easily accessed. Since the swap partition is accessed in very short bursts occasionally its the best option. Yeah, this is not one of those easily experimentable suggestions.

Coming to the harddisk.. Oh no, this is my most hated piece of hardware in a computer. It has moving parts, its unreliable and its a pain to maintain. Sometimes i wish i had an external usb hub with max capacity thumb drives built into it to use as a storage medium. I guess it would be enough for my day to day work. I dont know if it would be faster than a 10000 rpm hdd, but im sure its much more reliable because it can withstand more shocks, it does not heat up as much and it has no moving parts. To increase hdd performance there’s nothing better than ‘hdparm’. It tests speeds of the drive and give you a quite a bit of control over the hdd’s parameters. With ‘hdparm’ you can set the readahead, configure power management, enable/disable dma, display drive geometry, speed up/down the head movement, set spindown time and a whole lot of other neat stuff. Once you have got all options to your liking, add it to the end of ‘/etc/rc.sysinit’ so that it gets executed towards the end of the system’s booting process.
For example a line like this could be added:
hdparm -a1024 -c3 -d1 -m16 /dev/hda

Like i said earlier there are a lot of ways to improve the system’s performance. These are only a few i can think of. Try out ‘powertweak’ its good. Readahead, preload, upstart, teardown are good for boot-up, shutdown, and faster application loading times. Do not forget to inform me of something that i could add to this list.

Enlightenment e17 Installation

Yesterday I installed Enlightenment e17. I had heard a lot about Enlightenment e17, had seen a lot of screensots (,,, and found them impressive. After a lot of searching I got all the packages for ubuntu edgy (6.10) from http://seerofsouls. This is a great repository for all the PLF packages for Debian, Ubuntu and Mandriva. The total size of all the e17 packages and its dependencies was about 50MB. Got it all installed perfectly. The moment of truth was when I logged in.

Awesome, gorgeous, sexy, simply superb… boy oh boy this is what everyone who has used e17 was going ga ga about. This is the best window manager I have seen till date. I’m still using the default theme, haven’t changed it yet. Its a bit more heavier than the enlightenment e16.. but for the eye candy its definitely worth it. Not to forget its much much lighter than gnome or kde. The effects are mind blowing, I bet you can use it on a machine with 128 megs of RAM.

The best part of e17 was that it generated beautiful menu’s with all my installed packages. e17 is very modular in the sense you only enable whatever you require and disable the rest which will then not consume any resources in the background. As soon as you turn off all effects you can notice a significant improvement in performance. The configuration and settings are real simple to change, thanks to the lovely gui tools.

There is a very well maintained user guide at along with all the packages and other forums. For all the missing files and libraries visit

After a bit of playing around I decided to try beryl with e17, although I knew beryl only works with kde, gnome and xfce. Well the obvious happened, my X server cashed. It would have been nice to see the both working together. I wouldn’t call e17 very unstable because I didn’t experience any crashes. I wonder why the developers still want to say e17 is in its alpha stages. Believe it or not every library for e17 has been written from scratch.. nothing taken from e16. I haven’t come across any file manager, I guess they do not have one. Maybe I’ll use PCMan or Thunar along with e17.

WindowMaker still remains my favourite lightweight window manager (I believe its the lightest)… but I guess I’ll be sticking to e17 on my home machine atleast for a long time.

Ease Of Use

in one of my previous posts i had mentioned ‘ease of use’ which i feel wasn’t the right term to use. ‘ease of use’ or ‘user-friendliness’ i strongly believe varies from user to user. so if u tell me that windows is user-friendly i would disagree. i need a terminal open the first thing i log into my home machine. on windowmaker i’ve set gnome-terminal to open by default as soon as i login. a blend of gui and tui is what i really love. well i’ve also come across users who just cant do it with the gui, and there are the windows users who dont even know that a tui exists (i’m not windows bashing). while working with linux servers its a must to know how to get ur work done only with the tui but on desktops anything will do, infact these days gui is a must. something like konsole and gnome-terminal having the facility to open multiple tabs is what i’d call bonito (arv says).

saying that “windows is user-friendly” or “linux is not user friendly” without adding “in my opinion” to it dosent really make sense.

My Last Day With Windows

today i’ve been doing quite a bit of reading to fix problems with tuxguitar and kguitar, 2 of those tools i desperately need to make complete migration happen. i used to use guitar pro earlier… but now i can smell complete freedom coming my way. freedom from multiple reboots, fat32 and ntfs partitions and many other inconveniences.. and finally i’ve settled with a permanent linux distro.. UBUNTU.. superb ease of use for any stupid desktop user.

i’ve got tools for everything i need in linux… especially video encoding, multitrack recording, audio editing, drum machines, comic readers, chm readers, blah blah blah…….. and a hell lot of stuff.

i feel good already. i strongly believe that mark shuttleworth is the name that’s going to replace bill gates’ in the desktop market. and the stuff that he’s coming out with ubuntu’s gonna be a tough competition for redhat in the server market soon.