≡ Menu

hack

Generally, all Linux distributions needs a scheduled reboot once to stay up to date with important kernel security updates. RHN (or other distro vendors) provides Linux kernel security updates. You can apply kernel updates using yum command or apt-get command line options. After each upgrade you need to reboot the server. Ksplice service allows you to skip reboot step and apply hotfixes to kernel without rebooting the server. In this post I will cover a quick installation of Ksplice for RHEL 5.x and try to find out if service is worth every penny.
[click to continue…]

Linux Server with Embedded Display

Looks nice but this hack is not for the faint hearted!

Old Gateway PC transformed into a Linux server with embedded display

Old Gateway PC transformed into a Linux server with embedded display

Old Gateway PC transformed into a Linux server with embedded display, which is a hacked portable B&W TV driven directly by the VGA card.

Update: Vmware sever 2.0 final has been released. Version 2.0 has updated version for Firefox 3.0.x series.

VMWare remote console plugin allows to control VMWare server 2.0RC1. However, when you upgrade Firefox to 3.0.1 it will not work or get disabled by Firefox 3.0.1 due to plug-in compatibility issue. To fix this issue shutdown your Firefox, locate a directory called VMwareVMRC@vmware.com. This hack tested on:
=> Linux running Firefox 3.0.1

=> VMware Remote Console Plug-in version 2.5.0.100265

Open a shell prompt and type the following commands:
$ cd ~/.mozilla/
$ find . -type d -iname "VMwareVMRC@vmware.com"

Sample output:

./firefox/szvrcz3m.default/extensions/VMwareVMRC@vmware.com

Change the directory, enter:
$ cd ./firefox/szvrcz3m.default/extensions/VMwareVMRC@vmware.com
Open install.rdf
$ cp install.rdf ~/install.rdf.bak
$ vi install.rdf

Find line that read as follows:

<em:maxVersion>3.0.0.*</em:maxVersion>

Replace it with:

<em:maxVersion>3.0.1.*</em:maxVersion>

Save and close the file. Open Firefox and plug-in should work without a problem.
(Fig.01: Running VMWare Server Remote Console Plugin under Updated Firefox v3.0.1)

Most Linux distro can not display multilingual text on the console / shell prompt by default. There is a small hack which allows you to display other languages such as Hindi, Chinese, Korean, Japanese etc text on the prompt.

You need to use the bterm application, which is a terminal emulator that displays to a Linux frame buffer. It is able to display Unicode text on the console.

First, enable framebuffer by editing grub.conf file, enter:
# vi /etc/grub.conf
or
# vi /boot/grub/menu.lst
Find kernel line and append "vga=0x317" parameter:
kernel /vmlinuz-2.6.18-92.1.1.el5 ro root=LABEL=/ console=tty0 console=ttyS1,19200n8 vga=0x317
Save and close the file. Next, you need to install bterm - a unicode capable terminal program for the Linux frame buffer. Type the following command to install it under Fedora / RHEL / Cent OS Linux, enter:
# yum install bogl-bterm
If you are using Debian / Ubuntu Linux, enter:
$ sudo apt-get install bogl-bterm
Now reboot your Linux desktop / workstation so that kernel can create /dev/fb0. To use multilingual text on the console, type the command bterm, enter:
$ /usr/bin/bterm

Recommended Readings:

mplayer lacks an option for selecting files in a reverse order. So here is a quick way to playback all mp3 files in reverse order:
$ ls -1 -r *.mp3 > mp3.rev
$ mplayer -playlist mp3.rev

Where,

  • -r reverse order while sorting
  • -1 list one file per line
  • -playlist file : Play files according to a playlist file

Let's hear your shell hack in the comments.

The open source journal has published an interesting hack. It mostly applies to high-end, multiple-disk storage:

Under the right conditions (that is, with certain hardware configurations which I'll identify later) it is possible to literally double your sequential read performance from disk. If you noticed the terrible performance of the 3Ware 9500S RAID controller and cared enough to investigate. It all has to do with a sneaky little block device parameter known as readahead. Without going into too much gory detail, readahead controls how much in advance the operating system reads when, well, reading, as its name implies. By default, some operating systems (in particular, RHEL5 Server) sets this to 256 (512-byte sectors), or about 128 KB. When dealing with large filesystems spanning many disks, this paltry figure can actually nuke your performance.

=> HowTo: Linux: Double your disk read performance in a single command

This is a nice hack and a small how to about controlling Amarok media player:

Ever since I’ve received my new phone, bluetooth has excited me. To be honest, the notion of being able to control my pc from the phone was the exciting aspect. Ever wondered how to do this? Let me elaborate.

How to: Control Amarok Media Player with Bluetooth Enabled Phone
(Image Source: Authors blog)

=> Control Amarok with Bluetooth