Friday, December 27, 2013

How to install and configure Debian

Debian is one of the many GNU/Linux operating systems. Ubuntu, perhaps the most popular GNU/Linux system, is based on Debian. Having used Ubuntu for a few months and irked by some persistent instability issues, documented in my previous post, I decided to try out the current version of Debian. Debian is supposed to be extremely stable, but for some reason the current version is codenamed 'Wheezy'. I hope this is not a reference to its performance!
In this post I explain what I did to install Debian and importantly to make it usable.

Installation
Last Friday I installed Debian on my laptop. I first backed up my data on an external hard disk and burned the Debian installation file on a CD. I restarted my computer and booted from the CD. Nothing happened. I saw the Ubuntu login screen instead of the Debian installer. The Debian website says something about how to get CDs to work but I wanted to try the USB drive option. This time it worked. Debian got installed. Well, that's to cut a long story short. It took nearly 6 hours to install Debian mainly because of a slow downloading stage when more than 1300 packages were obtained from a Debian server. This could have been avoided if I'd used a larger installation file I think. Also, I am on a 512 kbps connection -- not great for fast downloads.

During the installation, I didn't have to do much apart from selecting the default options whenever I was asked to. I even went out for a couple of hours in between, with the blue installation screen glowing in the dark house.

Getting started with Debian installation is not very easy. It's supposed to have become simpler over time but it's far from being as easy as installing Ubuntu. So I was worried about whether I would be able to handle the configuration after installation. I'm not a GNU/Linux expert and rely heavily on information on user forums and the Debian website.

Making my user account "powerful"
To my relief Debian got installed after an uncertain start. So I could begin with the configuration -- all the things I've described below. As the first step I had to gain superuser privilege. To add software or edit configuration files on Debian one needs to perform actions as a "superuser". I first added myself to the superuser group by following the instructions given in http://www.pathin.org/tutorials/howto-enable-sudo-on-user-account-debian-6-squeeze/

Getting wi-fi to work
After installation wi-fi did not work, as I'd expected. Many wi-fi chipsets require firmware that is not free. Debian in its pure form accepts only free software and firmware.

So I figured out which wireless chipset I have:
http://www.cyberciti.biz/faq/linux-find-wireless-driver-chipset/

I downloaded the package for the firmware for my wireless chipset: http://packages.debian.org/wheezy/all/firmware-iwlwifi/download

And I installed the package from the command line:
# dpkg -i filename.deb



Setting up the package manager
Packages in GNU/Linux are installation files for software. Packages should ideally be found and added from a package manager such as Synpatic that comes with Debian. In this process, installation is point-and-click and the command line is not needed.

By default only free packages are listed in Synaptic. These free packages are stored in Debian server mirrors around the world. To make Synaptic list non-free packages, I added these lines to the file sources.list in the folder /etc/apt/

deb http://ftp.de.debian.org/debian wheezy main non-free
deb http://ftp.de.debian.org/debian wheezy main contrib



To edit text documents I like to use gedit, one of many text editors available for GNU/Linux systems.

Fonts
If you're used to Windows or Mac and see a fresh Debian install you might be shocked at how bad or rough the fonts look. Many of the fonts we're used to are actually proprietary fonts owned by Microsoft or Apple. Free equivalents of common fonts are available but these are "free" in the price sense, not the "freedom" sense I think. Debian recommends that people use truly free fonts such as those in the Liberation series (Liberation sans, Liberation serif, etc.).

I am unfortunately too used to Microsoft fonts so I installed these fonts through Synaptic.



The Microsoft fonts installation file is ttf-mscorefonts-installer. Within this is contained Arial, Verdana, Times New Roman, Courier, etc. But these fonts don't look quite like what you might be used to. So I applied font smoothing by following the instructions given in https://wiki.debian.org/Fonts#Subpixel-hinting_and_Font-smoothing. This required me to create a new text file and copy-paste the code given.

Skype
Skype is a good example of a free application where "free" is like "free beer" but not "free speech". Skype is thankfully available for GNU/Linux systems (Debian, Ubuntu, Red Hat, etc.). I really need Skype for my work.

To install Skype I downloaded the .deb file (the extension for installation files in Debian) from the Skype website (http://www.skype.com/en/download-skype/skype-for-linux/) but ended up having to do some things to make it work, following the instructions given in https://wiki.debian.org/skype

Copying my files from an external hard disk
When you connect a USB drive or external hard disk to your computer you expect it to open. Not so easy in Debian! I had to mount my external hard disk following instructions in http://www.ehow.com/how_7223499_mount-usb-drive-debian-linux.html. But this seems to be a one-time process. When I connected the hard disk again it was automatically detected and I did not have to mount it.

Setting up my wireless printer and scanner
I have a Canon MG3100 wireless printer and scanner at home. I set up my Canon printer using an installation file downloaded from the Canon website:

http://support-sg.canon-asia.com/contents/SG/EN/0100393702.html

Then I set up the scanner using the 'scangearmp' program from http://support-sg.canon-asia.com/contents/SG/EN/0100394102.html

Java for online banking
For doing online banking with my bank, I need to cross a login stage where Java is used. To set up Java I installed two packages: openjdk-7 and icedtea-7-plugin from Synaptic.


With all this my laptop became pretty much ready for use, but I'm sure I'll be doing more installations and tweaks in the coming weeks!

1 comment:

  1. If you installed AMD64 and your audio works, you're one of the lucky few. Wheezy continues to distribute broken kernel modules for the most common sound cards. Stable, indeed! If you don't feel like compiling your own kernel and you think audio is a basic requirement for a computer in the current century, don't install Wheezy.

    ReplyDelete