Running Debain on Desktop

Warning: I might change this article depending on feedback. This warning will be removed when I finish with such edits. After hearing some recent reports from users who tried to run Debian GNU/Linux on their desktops, I thought it will be useful to list some guidelines to avoid some common pitfalls. Debian is great to run on the desktop and with the recent udev/sysfs stuff, hardware detection works great, and apt has always been an excellent, if not the the best, package management tool... :-) Which version? Use Debian `testing' (`Etch' at the time of writing this post). Period. Debian `stable' (`Sarge') doesn't get new versions of software, but only bug and security fixes, which is a great for servers; not for desktops. Debian `unstable' (`Sid') get latest versions of software before `testing', but it breaks dependencies from time to time, which is also not desiarable for a general desktop. How many CDs? If you have a good Internet connection, getting the small `netinst' CD is good enough. Otherwise, first 2-4 CDs are all what you need. If you'll ever need more, then you won't be reading this guide... ;-) You can use jigdo to download the official weekly builds, or less preferably download the ISOs (CD/DVD) here. There were problems with some of the `unofficial' CD/DVD builds, so I recommend getting the official builds. Linux kernel 2.6 If you want all the bells and whistles of the latest Linux kernel, instead of just hitting ENTER when booting the installatoin CD, type `linux26'. Partitions For a desktop, it's sufficient to have three partitions. One swap partition (about 512 MB - 1 GB), one root (/) partition for the installation (2-10 GB, depends on the amount of software you plan to install), and one home partition (/home) for personal files (size of this partition depends on your needs, if you are going to have a lot of audio/video files, this will fill up soon). By having a seperate /home partition, it's possible to play around with the installation in the root (/) without loosing the personal files. If you are planning to have databases and other servers, they will consume space in /var, which is in the root (/) in the above settings. Consider increasing the size of the root partition, or creating a seperate /var partition if this is the case. Personally, I use a single root partition (not a seperate /home), because once you install Debian, there is absolutely no need to install again, as you can keep on upgrading... :-) This installation I am using right now has survived three laptop migrations!!! Filesystem Use a journalling filesystem. I personally prefer reiserfs, as it has good indexing capabilities, and excellent when there are lots of small files. If you have a much larger files instead, consider xfs or jfs. Ext3 is also not a bad choice. What to install? With Debian, it is best to finish the basic install as soon as possible. Therefore, don't select anything extra (x windows or gnome etc), and don't add any additional CDs. Just use the first CD and get over with the installation. Now what? Once installation is over, login as root, and add any additional CDROMs with apt-cdrom tool.

# apt-cdrom add
Repeat this for all the CDs available. Consult /etc/apt/sources.list if you want to verify. Now add X windows, and KDE and/or GNOME desktop(s). Again, if you prefer any other desktop (fvwm or windomaker), you won't be reading this guide... ;-)
# apt-get install x-window-system-core
# apt-get install kde
# apt-get install gnome-desktop-environment
You can play around with /etc/X11/xorg.conf to tweak your X window settings (or alternatively, try the `dexconf' tool). Use the `startx' command to start X windows. Once you are happy with the X window settings (resolution, depth and refresh frequency etc), install a graphical login manager (e.g.: kdm).
# apt-get install kdm
# /etc/init.d/kdm start
One last bit of advice: always login as a normal user, not as root. Open a terminal and run `su -' to become root if necessary. This will reduce possibilities of you harming the system, ensuring long life of the installation. I am hoping to write another howto on installing multimedia stuff and Java. Disclaimer: I am sorry if this makes you forget what `installing' is, because it's very unlikely that you will do another installation ever again... ;-) By the way, happy Debianning!


Dinesh Premalal said...

#dpkg-reconfigure xserver-xfee86 (xserver-xorg if u using xorg)

would be a helpful thing for a new user (at least it helped me a lot) when things messed up with unknown vga drivers or when need to achive high resolutions ;)

Dinesh Premalal said...

sorry it should be
#dpkg-reconfigure xserver-xfree86

Anuradha said...

Reconfiguring xserver-{xorg,xfree86} runs dexconf. Please study /var/lib/dpkg/info/xserver-{xorg,xfree86}.* files.

MCKAY Brothers said...

deconf only nessesary runs on sarge, etch n above releases dont need!