How to check for the gateway in Ubuntu

Use the route or ip command to get default routing table for Ubuntu Linux. Open the terminal and type the following command:

route -n

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface         UG    0      0        0 wlan0   U     2      0        0 wlan0     U     1000   0        0 wlan0

How to Install Opera in Ubuntu

Just follow these 3 step guide and you will be able to add Opera in Ubuntu.

1. Download and add the Opera Repository Key

To get started, press Ctrl – Alt – T on your keyboard to open Terminal. When it opens, copy and paste the line below and press Enter to add Opera repository key.

wget -O- | sudo apt-key add -

2.Add Opera to the sources list

Next, copy and paste the line below to add Opera software repository in Ubuntu. I use the following command. and add the following line in the software repository.

sudo gedit /etc/apt/sources.list
deb stable non-free

3.Finally, run the commands below to update your system and install Opera

sudo apt-get update

sudo apt-get install opera



Spend a lot of time in front of a Screen – Use Flux.

F.lux is an app that will help you control the screen colours as per the timing of the day.

We know that night-time exposure to blue light keeps people up late. We believe that f.lux adjusts colors in a way that greatly reduces the stimulating effects of blue light at night.

To understand the effects of f.lux on sleep, we’ve spoken with some researchers, and we’ve read a whole lot of papers.

The science that explains why blue light keeps you up was begun many years ago in the study of bird migration, and it continued in humans with the discovery of a new photoreceptor in the eye, called Melanopsin. Many are familiar with the “rods and cones” that provide our visual capabilities, but it was only about 15 years ago that retinal ganglion cells containing melanopsin, which are sensitive to a narrow band of blue light in the 460-480nm range, were discovered, and their unique effect on sleep was investigated.

For more research visit –

Download F.lux from –


How to remove an uninstalled package’s dependencies

Sometimes you might want to remove the dependencies with the software itself.In this case you should use the command apt-get autoremove. It will remove packages that are installed as automatic dependencies, but are not depended anymore.

Apt-get has a flag –auto-remove that can be used to automatically remove the automatically installed packages when removing a manually installed package:

apt-get remove --auto-remove packagename

Certain other tools are also capable of doing this, for example aptitude will automatically suggest that you remove the packages that have been orphaned.

The automatically installed packages tracking is built in to apt so the tracking should work no matter which tool you use to install the packages.

Reinstall / Recover GRUB from Ubuntu live CD / USB with Encrypted Hard Disk

OK, I upgraded my Ubuntu yesterday. Everything went smooth, but in the end my cab arrived. It led to disaster as when I reached my office, my Laptop would not boot. It just showed a screen of Grub with the command line.

So, I google’d  it and found a nice solution here.

The problem was I needed a live CD for that, so I downloaded Ubuntu 12.04, made a Live USB with the help of LiLi Live USB creator.

I booted the system, but the problem did not ended there. The problem was that my Hard drive was encrypted and I needed some way to mount that before I could re-install grub all over once again.

So, I followed these steps to mount my Encrypted Disk.

1.Install LVM2

sudo apt-get install lvm2
  1. Mount your hard drive using cryptsetup
sudo cryptsetup  luksOpen /dev/sda2  backup
  1. Your Hard drive will be mounted.

🙂 Enjoy.