Saturday, 31 January 2009

Moving /home to another partition in Linux

Warning: Please note that these instructions are for an Eee PC 901 with 2 internal SSD's, a 4GB and a 16GB. If your PC has a different setup these settings may not work. These instructions are from memory and I can not be responcible for any data loss you may suffer from following them - use at your own risk!

After a couple of days of messing around with other OS's on my Eee PC I have reverted back to Cruncheee. Actually it is RC2 of Crunchee!

While playing with the other options I have been very careful not to install anything on the second SSD inside the Eee PC as this houses my original /Home partition with all of my custom settings since my last Cruncheee install. Looking back I have realised that I never posted instructions on how to move your /home partition to the second SSD so here they are:

First and formost you need to move your existing /home data to the second SSD. Make sure your second SSD is mounted already by checking your /media directory. In here there shoud be a folder called 'disk'. If not follow these instructions:

1) Go to your /dev directory > cd /dev

2) List the available drives > ls sd* > this should output sda sda1 sda2 sda5 and sdb sdb1. Your second SSD is sb1 (at least mine was!).

3) Create a folder in /media to mount the drive > sudo mkdir /media/disk

4) run > sudo mount /dev/sdb1 (or the name of your 2nd SSD) /media/disk > to mount the 2nd SSD to /media/disk.

From here you can log out of your 'windows' session. When prompted o log in if you click the Options button in the bottom left you should be able to select Choose Session then select Failsafe Terminal. Then proceed to log in with your normal username and password.

This should log you in to a terminal only session and from here you can move your existing home folder to your 2nd SSD with this command:

sudo cp /home /media/disk/

This should copy the contents of your /home folder to the 2nd SSD. Once complete, it can take a while, you need to edit your fstab so it mounts your new /home correctly:

sudo vim /etc/fstab

and add the following 2 line to the bottom:

# /dev/sdb1 for /home
/dev/sdb1 /home ext3 rw,user,exec,relatime 0 0

write and quit this file and reboot your machine. Once rebooted you should find that your /home directory is located on your 2nd SSD giving you lots more space to store files!

Note: there is some debate about the need to add relatime as it is not proven that SSD's will suffer more than a normal HD as a result of continuous writes - Article.

Assuming this was successful you Will not want to go back and remove your 'old' home directory. To do this you will need to edit your fstab and comment out, with #, the lines you added above. Then reboot your PC. Log in to the failsafe terminal again and insure that the files in the /home directory are your old ones then you can safely remove them. Then edit your fstab to comment those lined back in and reboot your machine and log in normally, Voila you have moved your /home directory to your more spacious 2nd SSD.

Thursday, 29 January 2009

Google Apps For Your Domain now has Offline Gmail

Logging into my account this morning I noticed that the page had a distinctly different layout. I checked the 'Labs' tab under settings and found that I now had the long sort after 'Offline' option! GAFYD now has offline email reading supported by Google Gears.

From the Official Gmail Blog - Here.
Reported a couple of days ago in Lifehacker.

Friday, 23 January 2009

vnStat network monitoring tool

vnStat is a console based application for Debian linux (I am using it on Cruncheee) that will monitor you network traffic on the specified interface. You can view daily, weekly or monthly information or you can use it as a realtime traffic monitor.

How to install and use - Here

Information on - Here

To view live information on the fly try this command
vnstat -i -l

My Eee-PC links via bluetooth to my mobile on interface ppp0 so my command is:
vnstat -i ppp0 -l

Unfortunately, it does not offer real time totals which would be useful!

Wednesday, 21 January 2009

Pidgin, Facebook and Twitter

I have recently installed a couple of useful Google Code provided plugins for Pidgin.

The first of these I have been using for a while, the Facebook plugin. This ties into your Facebook account and lets you use the instant then messaging feature of Facebook through Pidgin. This plugin is quite easy to install for both the standard and the portable edition. For a standard Pidgin install you can download and run the .exe. Or you can download the .dll and install it directly into the plugin directory (normally C:\Program Files\Pidgin\plugins) then download the icons from here and copy those to the appropriate directory in C:\Program Files\Pidgin\pixmaps\pidgin\protocols\.

Note: If you are using the Portable Apps version you need to copy the .dll file to your portable drive - PortableApps\PidginPortable\App\Pidgin\plugins and extract the protocol icons to PidginPortable\App\Pidgin\pixmaps\pidgin\protocols.


Once installed, restart Pidgin, right click on your Pidgin task bar icon and select Accounts. Here you can add the details of your Facebook account by selecting Facebook from the drop down menu. Once added I you should see a new category of Facebook in your buddy list, your Facebook buddys will appear here when they sign in. Personally, I don't like having myself in the list. You can remove this by going back to the Accounts window select your Facebook account, click Modify, go to the Advanced tab and tick the box 'Remove myself...'.


The second plugin I have only recently discovered is the Microblog-Purple plugin again from Google Code. This plugin allows you get your Twitter updates within Pidgin.

This plugin has an .exe for both a standard install of Pidgin (here) or the Portable Apps version (here). Both of these will automatically install the plugin and required icons etc for you. The only issue I found is that with the portable apps version you must point the install to > your portable drive\PortableApps\PidginPortable\App to make sure it installs correctly.

Once installed, restart Pidgin and right click on the Pidgin icon in your task bar. From here go to the Plugin window and scroll down untill you find Twitgin and tick the box to activate this plugin.

Note: originally I have a compatibility problem 'ABI Version Mismatch' when trying to activate the plugin. However, after updating Pidgin Portable to the latest version the plugin worked fine.

Once the plugin is activated you can add your Twitter account in the Accounts menu by selecting TwitterIM from the drop down list and entering your details. Once your account is setup you should see a Twitter category in your buddy list with a Twitter buddy. Updates from twitter friends timeline will appear in a new window allowing you to follow your twitter timeline.

I normally right click on the Twitter buddy in the list and give it a shorter name, 'T' for example, which makes the timeline easier to follow in the twitter window.