Category Archives: Tech

Weekend Project with OpenSource

Here’s another story about how open source helped me.

I have a USB disk at home where I store all my photos, videos, movies, songs etc.  The disk is connected to a desktop computer at home and shared across the network. Making it available on network helped me to backup my laptop data also to the disk using wireless connection. So far so good.

But what about watching movies or listening to songs or viewing pictures? I can do it from my laptop, but it will be only me. What’s the fun in that? I wanted to enjoy them with family and friends in my TV in the living room. Here’s how I did it.

In old Laptop, I installed PinGuy Linux (http://pinguy-os.sourceforge.net/ ) . I also updated all softwares to the latest version.

Now the problem is that I have a CRT TV. It supports only RCA input. My laptop had a  S-Video output. I bought a S-Video to RCA Cable and connected the laptop. It did not work !. Then I bought a VGA to RCA cable , that also failed. I did some research and ended up buying a VGA to RCA Converter box from the local electronics market. It gives 640×480 resolution that is probably the maximum my TV can do, anyways.. it worked.  πŸ™‚

Here’s the box.

So now, My TV shows only a part of the laptop screen because laptop is running at 1024×768 and TV can do only 640×480. Then I started XBMC , the Media Center Application. It gives a nice GUI to configure settings and also to manage the Media. I configured it to run in Window mode and dragged and re-sized the window to 640×480 resolution and placed it on the corner of the screen so that it covers fully what is shown on my TV.

Rest of the operation was simple, connected to my USB disk over network, added those files to XBMC. I also configured XBMC to show weather information and play Youtube videos.

I am now able to watch all my photos, videos and listen to songs in my USB disk via my TV. Hurray !

Wishlist :Infrared Remote for Laptop. Also a HD capable TV in future πŸ™‚

Firefox 4 Released

Firefox 4 is now available for download. Click here to see what’s new.

I installed it on my laptop. It has improved a lot. Specially the way tabs are organized and the visual layout overall has been totally streamlined. It is also loading webpages faster. Unlike the previous versions, Firefox 4 is using less RAM on my system.

So what are you waiting for? Give it a try. πŸ™‚

Libre Office – Free Yourself.

The Document Foundation is an independent self-governing meritocratic Foundation, created by leading members of the OpenOffice.org Community. After Oracle’s takeover of Sun, there has been a lot of discussion going on as to what would be the future of the Open Source Projects funded by Sun. Oracle has already shown that they are not so much into supporting Open Source projects. So I think this is definitely a good move.

I have downloaded it and installed on my computer. It is definitely faster and lot better in UI already. If you are still using OpenOffice, you could also consider migrating to LibreOffice. It uses the same code base and is already improved a lot than OpenOffice. May the freedom be with you ! πŸ™‚

SNMP Monitoring using Nagios

Nagios is very good and commonly used monitoring tool for systems and network equipments. It can monitor and report availability statistics as well as provide alerts in case of host or service incidents. I am going to discuss on how to use the SNMP capabilities of Nagios and GNU/Linux to enable monitoring without special agents installed on the hosts.

Usually, Nagios will need you to install NRPE addons to report disk space and so many other updates about the system that need to be monitored. This needs you to install additional software on the target machines which is not always possible/recommended practice. Instead, we are going to use the SNMP software that comes as part of the GNU/Linux OS to provide information for Nagios. I am not going to brief about how to install Nagios and Plugins. You could read that in a beautiful how-to here : http://nagios.sourceforge.net/docs/3_0/quickstart-ubuntu.html

There are two steps in enabling SNMP Monitoring.

Configure SNMP in the host to be monitored.

  • Edit /etc/snmp/snmpd.conf and add one line. ( rocommunity public )
  • Restart snmpd service ( sudo /etc/init.d/snmpd restart )

Configure Nagios to check free RAM in the host via SNMP .
First, add a host entry like this to your .cfg file.

define host {
use linux-server
host_name linuxserver01
alias MyLinuxServer
address 192.168.1.24
}

Now we will add a service to check free RAM

define service{
use generic-service
host_name linuxserver01
service_description Free RAM
check_command snmp_freeram_linux
}

Next, we will define the snmp_freeram_linux command to use snmp_check plugin that comes as part of Nagios Plugins installation.

define command{
command_name  snmp_freeram_linux
command_line /usr/local/nagios/libexec/check_snmp -H $HOSTNAME$ -C public -o .1.3.6.1.4.1.2021.4.11.0
}

After this, restart Nagios. ( sudo /etc/init.d/nagios restart )

You should be now able to see a new service added to host and SNMP getting the data. With some efforts, you would be able to configure SNMP for other operating systems and network equipments too. If you have queries, please let me know. πŸ™‚

Making Ubuntu Better !

Here’s a few things I do just after installing Ubuntu Linux. While this step is not mandatory, it sure makes a lot of good additions to the experience. With these few simple commands, your new Ubuntu system will get lot of additional things that is going to make it feature packed, shinier and a pleasure to use.

Before we start
Having a internet connection is necessary to do these tricks. Before we start, update your system by running the following commands one by one.

sudo apt-get update 
sudo apt-get upgrade

Multimedia
Adding VLC Player, Lots of different codecs for playing variety of Media formats like MP3, MP4 etc is so easy. This command will also install some of the fonts used commonly in Microsoft Office Documents for compatibility. avidemux is a simple but capable Video Editor.

sudo apt-get install vlc ubuntu-restricted-extras avidemux

Graphics Applications
Scribus is a Desktop Publishing Software. InkScape is a Vector Graphics application just like Corel Draw. Gimp could compete well with Photoshop.

sudo apt-get install gimp scribus inkscape

Windows Programs
You want to run Windows Programs in Ubuntu ? Sure. Let’s install Wine. After installing wine, you could just double click any .exe files just like you did earlier to run them. You could even install Windows Software packages on Ubuntu. They will appear under Applications -> Wine -> Programs Menu after installation.

sudo apt-get install wine

Sun Java Support
If any of your programs are not running because Sun Java is not installed or the OpenJDK is not able to run them, install Sun Java.

sudo apt-get install sun-java6-jre sun-java6-plugin sun-java6-fonts

Skype, Acrobat Reader, Flash and lot more..
You want to customize it further and add lots of more softwares like Skype, Acrobat Reader, Google Chrome and much more ? Install Ubuntu Tweak. Download the package and double click on the file to install. Once installed, this tool appears under the Applications menu. There are a huge number of things you could do with this very handy application. For example, if you dont like the “close” button on the left side of your windows, this tool will help you to change it back to the right corner..

For GUI Lovers
All the above apt-get commands can be done via GUI using applications -> software center. Just search for the package name and click install. Like I always say, it’s all about choice. πŸ™‚

Side Note : Some of these commands actually makes you install non-open-source applications or libraries to your system. You have been warned. πŸ™‚