Thursday, March 19, 2015

Best Linux Distribution - Selecting Your First Linux Distro

Tired of your current OS and/or looking for another OS, wanting to learn new thing or feeling adventurous? If for any reason you want to try out Linux on your desktop/laptop but you are not sure where to start from, then this article is for you. Read on...

Microsoft's Windows has been a first choice of most of the desktop PC users for more than 15 years now. Most of the users buy computer/laptop which has Windows pre-installed on them so they get it as default OS for their computer/laptop. This was a part of well known business partnership between Microsoft and Intel, a software and a hardware company respectively. And that's how majority of desktop users have been introduced to the world of computers. In such conditions, where well established software and hardware companies have partnered, it was very difficult for others to enter into market and to be considered as an option. Unix, an OS which predates even DOS was also a proprietary software. However, there were many people all over the world who did not like the closed doors of Microsoft's offering and they were looking for other option to use. Linus Torvalds, a student back then, created Linux mimicking Unix which was closed and proprietary at the time. He released it online for others to review and use. Other users liked and loved Linux the way it was. Developers among them also improved it over the years and made it what it is today. Today also Linux development is lead by Linus himself.

I think that is enough of history one needs to know for using Linux. Now, let's see what you need to know for choosing a Linux based OS. You might have noticed that I said "Linux based OS" and not "Linux" in previous line. Because, you should clearly understand that Linux is only kernel and not a complete OS.  So what is an OS? Any modern OS includes a desktop environment and other GUI tools to support user while kernel directly manages system resources using drivers. So, Linux can handle your computer hardware(it provides plenty of device drivers in-built) but doesn't provide any GUI for user by itself. You ask then how do I use Linux, and that's where another beauty of OpenSource software comes into the picture. There are many OpenSource desktops available freely which you can use on top of Linux to operate your computer. We will see few of them later in this article. Once you have a desktop environment installed, you can install more software for specific tasks. We can name such packaged software stack(drivers, kernel, desktop environment and applications) as a Linux distribution. Below is a diagram depicting software stack of a Linux distribution.

A Linux Distribution - Software Stack


Now, you know what is required to be installed to build an OS using Linux kernel, so you start your search for a Linux distribution to download. But again, you will get overwhelmed by so many results provided by search engine. From your searching you find that there are hundreds of Linux distributions available and you have no idea which one to download to start with. This may be another stopper for you in your journey, but don't worry. As you learn more from reading articles like this on internet, you will realize that it is actually a great thing to have so many choices. However, your question still remains, which one I download and install? To answer this question, let's go back to desktop environments that we learned about a little while ago.

Desktop Environment

As I said, there are many desktop environments(DE) available to choose from. Let's try to know them little more this time. Before we go any further, let me tell you these very clearly that desktop environments are more of a personal preference and not one size fits all(like windows) thing. So you may like one environment more than others but don't hesitate to try others as well. That will give you an idea how diverse Opensource Desktop Environments are. Select the one which you think suits you the best. Your desktop/laptop/notebook's hardware configuration may also play a part in your DE selection. Let's see some popular DEs available.
Gnome has been a prominent desktop environment on Linux based OSes. It is a very popular and simple to use environment. Currently available in form of Gnome Shell based on Gnome3 libraries. It should run fine on 512 MB of RAM, however, I suggest to use it with 1 GB of RAM for smoother user experience.

"GNOME 3 is an easy and elegant way to use your computer. It is designed to put you in control and bring freedom to everybody. GNOME 3 is developed by the GNOME community, a diverse, international group of contributors that is supported by an independent, non-profit foundation."
--- gnome.org



KDE
KDE is another well known and popular DE developed and maintained by KDE community. It uses Qt libraries. It is highly configurable DE. You can find many options for tweaking the system to your liking. It's desktop is known as "Plasma". Plasma also has a "Netbook" and  a "Tablet" workspace/interface that I leave up to you to explore. Plasma 4 series is the stable version. Plasma 5 which is also stable but still under heavy development and does not have feature parity with Plasma 4 yet. Plasma 5 looks great, expect great releases in near future for this DE!

KDE consumes little more system resources relatively when compared to other DEs but if your system has enough power to run it, it is a power beast.

"For users on Linux and Unix, KDE offers a full suite of user workspace applications which allow interaction with these operating systems in a modern, graphical user interface. This includes Plasma Desktop, KDE's innovative desktop interface. Other workspace applications are included to aid with system configuration, running programs, or interacting with hardware devices. While the fully integrated KDE Workspaces are only available on Linux and Unix, some of these features are available on other platforms."
--- kde.org



Unity (Ubuntu fame)
Ubuntu Unity is a very ambitious project by Canonical Ltd. It is designed to run on different form factors like desktop, tablet, phone etc. and give the same user experience on each of these platforms. It is under heavy development, however a stable version for desktop is always available for use.

Unity also needs good amount of RAM and not recommended for systems with low RAM. You can take an online tour of it here.

"Enjoy the simplicity of Ubuntu's intuitive interface. Fast, secure and with thousands of apps to choose from, the sleek Ubuntu desktop experience is now optimised for multitouch devices, including laptop trackpads and touchscreens, as well as the familiar keyboard and mouse."
-- ubuntu.com



Cinnamon (Linux Mint fame)
Cinnamon is a DE developed by Linux Mint(a very user friendly distribution) community led by Clement Lefebvre. It has a traditional looks but is built upon latest technologies under the hood. It uses Gnome3 libraries. Its traditional look makes it easy to use; even for a new user. This also makes it suitable for all age groups of users.

Cinnamon uses moderate amount of RAM and should not be used with systems with low RAM. Here you can have an overview of features provided by Cinnamon.

"Traditional layout, advanced features, easy to use, powerful, flexible."
--- linuxmint.com



Xfce
Xfce is another DE which has become more popular after gnome users getting displeased by early Gnome Shell and Ubuntu Unity releases. Xfce is a traditional looking DE having a launcher menu, a panel and system tray. It is very light weight in terms of system resource usage. If you have an old system which is not able to run latest versions of Windows or other DEs discussed above, try Xfce.

"Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly."
--- xfce.org



MATE
MATE is a fork(a new branch from an old one) of once very popular and widely used Gnome2. Gnome moved on to newer libraries and created Gnome Shell. People who did not like Gnome Shell took the source code of Gnome2 and created MATE using it. Though it uses old code-base, it is very actively maintained and updates released regularly. It uses moderate amount of system resources but should work fine even with a 512 MB of RAM.

"The MATE Desktop Environment is the continuation of GNOME 2. It provides an intuitive and attractive desktop environment using traditional metaphors for Linux and other Unix-like operating systems.

MATE is under active development to add support for new technologies while preserving a traditional desktop experience."
--- mate-desktop.org



LXDE
LXDE is another light-weight but a full-fledged DE. It features traditional look with start menu and a panel at the bottom which reminds of windows XP. So any user who has used Windows should find it a familiar user interface. It is extremely light-weight and can bring old hardware to a new life.

"The "Lightweight X11 Desktop Environment" is an extremely fast-performing and energy-saving desktop environment. Maintained by an international community of developers, it comes with a beautiful interface, multi-language support, standard keyboard short cuts and additional features like tabbed file browsing. LXDE uses less CPU and less RAM than other environments. It is especially designed for cloud computers with low hardware specifications, such as netbooks, mobile devices (e.g. MIDs) or older computers."
--- lxde.org

LXDE has joined hands with Razor-Qt desktop project to produce a new DE named LXQt. It is under development but early versions are available to try.


There are few more DEs available that you should search and explore yourself but at least one of the above should cater your computing needs, if you don't want to look any further for desktop.

User Applications

Normally a Linux distribution packages a DE along with many applications for day-to-day activities. For example, Gnome Shell, Unity and Cinnamon will have applications built using Gnome3 libraries. MATE will have applications using Gnome2 libraries and KDE will have applications using KDE/Qt libraries. So it will be a good idea to search for available applications for a given DE. If you don't find specific type of application available for a DE, don't worry. You can install apps from other DEs but that will also install underlying required libraries too. Also, such application from other DEs may look different(visual difference) from native library applications. Personally, I try to keep my system have applications that use same libraries as my DE. This gives consistent look for all applications under my DE.

Now, Go to YouTube and watch videos of latest stable versions of each of these DEs, it will help you in deciding/short-listing the DE for your needs or liking. 


Now you have short-listed 1-2 DEs, you can search for a distribution(distro in short) which packages your preferred DE and provides it out of the box. Doing so will take you 1 step closer towards selecting your first distro. At this point of time, you should have a list of distros providing the DE(s) you want to try out. Out of this list, later you can pick 1 or 2 to try out and regular usage then onward.


Latest vs Stable

Majority of Linux distros provide you with a stable version of DE and other applications. These versions give your system stability and makes it reliable. Major updates are not frequent on such distros and all updates are tested very well before they are made available to regular users. So you can rest assured that your system will be usable even if you update something. Such distros release their new version at a regular intervals like 6-9 months and these versions are generally supported for a year or two. Some distros provide LTS(Long Term Support) releases which are supported for 3-5 years. Here support means regular updates to stable software and security fixes. When you use a stable distro, you may need/want to re-install the distro after a new version is released(for example after 6 months) as new version will have major updates to system software. However, it is not necessary to always re-install your distro just to upgrade to newer version as an upgrade path is always made available for most stable distros.

On the other hand, there are very few distros which provide you with latest versions of DE and user applications. These versions are stable versions of individual software but may not be tested thoroughly(but good enough) and may affect system integration which may result in unusable system. However, such things happen rarely these days but there is always a possibility. This may sound little risky but it has its own advantages like getting new features, security fixes etc shortly after they are available. Such distros are knows as Rolling Release type of distros.  All your software including drivers, kernel, DE and user applications are updated continuously so that you do not need to re-install your linux distro when a new version of it is released. Your distro always remains latest!

So, if you want a reliable system pick a distro with stable but little old versions of software. If you want a super-reliable system(installing for study work, parents etc.), select an LTS version of distro. And if you are adventurous and like living on bleeding edge, select a rolling release type of distro. Choose wisely!


Installing/Removing Software

Next thing will be to consider if a distro provides a graphical software manager tool or not. Using such a software manager you can search and install new softwares from online repository. An online repository is nothing but an app store from where you can download software packages. I highly recommend that you learn how to use command line package managers after you are comfortable with your distro. Every distro has at least a command line package manager to install/remove softwares but as a new user your priority should be getting used to the new system first which includes installing and removing softwares. So select a distro which provides a graphical software manager. Majority of  regular-user oriented distros come with such a tool so it should not be a difficult task.


Ease of Installation

Most of the Linux distros have a graphical installer for installation purpose. However, there are few distros meant for not-first-time users which do not provide graphical installer. As a beginner, you should select a distro with a graphical installer. Also, now a days graphical installers have a slideshow going on while system is being installed. Such a presentation give you information about what softwares are included, where to look for help etc.

Some distros are easier to install than others. Search the web, user forums, YouTube and other resources to find out how easy it is to install your selected distro. Find a distro which is easy to install.


Media Codecs

Another thing you might be used to because of your previous Windows/Mac experience is that your media files like MP3s play right away after installing the OS. However, this may not be true in case of a Linux distro. Countries like USA and UK have software patents which makes it impossible for distro packagers to package media codecs required to play MP3s and other media files. So many of the well known distros do not come with these codecs pre-installed. Instead they are made available for download and install from an online repository. So make sure that you comply with software patent laws in your country and select a distro accordingly with/without media codecs pre-installed.


Support Availability

Majority of Linux distros have community support. Community support is available in various forms like wiki, user forums, IRC channels etc. Also, there are few distros which are backed by companies providing technical support.

Depending your skill level, learning ability and most importantly patience, choose a distro with/without commercial support.


If you haven't discovered this on your own yet, then here it is.
Some distros provide more than 1 DEs. This can be useful especially if you have decided upon stable/rolling model of distro but didn't know your preferred DE is supported by that distro. Do check for supported DEs for your selected distro before finalizing one.

For example, Linux Mint provides different installation images for Cinnamon, KDE, MATE and Xfce. So you get to choose your preferred DE on top of stable Linux Mint base.


Picking The Right Distro

Prepare a table and note down rating/comments for above mentioned criteria against each of your short listed distro as per below table. These rating should give you fair idea of which distro(s) you should start your Linux journey with.



Sr. No. Distro Name Desktop Environment Stable/Rolling Graphical S/W Manager Easy To Install Media Codecs Support
1
2
3
4
5


Some Important Points

  • This article tries to help you in selecting a Linux distro that may be suitable to your needs but does not suggest or recommend any over others.
  • A Linux based OS may not completely replace your current OS depending upon your needs. For example, if you use CAD/CAM softwares or design software like Photoshop. There may be some Linux alternatives out there for such softwares but you may not find them having same features/workflow or they may not be able to open/save your files created using your current software.
  • It is important that you backup all your data/software setup before trying to install Linux. If you do anything incorrectly during installation for Linux, you may lose all your data. Always take backup of your data.

Hope this helped you in selecting a good distor/linux based OS to start with.

In another article I will write about installing a distro.


Cheers!


Friday, June 27, 2014

KF5 Tutorial 2 - How To Use KXmlGuiWindow

In first tutorial, we learned how to write our first KF5 program. In this 2nd tutorial, we will learn how to create a main window program. Again, this is example 2 from KDE4 - Development series available here. Credit for code goes to original writer of the code on  KDE techbase site. I will be making changes in that code so that it can be compiled and run using KDE Frameworks 5 libraries. With that said, you can use code in this post for learning development with KF5 libraries.

I will not explain each line of code like it is explained in KDE4 tutorial, however you will find short comments within code which will give you some idea about what's being done. I plan to add explanation for code at later time. Also, I am not pointing out changes that are made for porting purpose because I am planning to do it in near future.

Before we begin, I assume that you have development environment setup and you have completed the first tutorial. You need at least following software installed.
  • Qt 5.3
  • KDE Frameworks 5(KF5)
  • cmake
  • extra-cmake-modules(ECM)

Tuesday, June 24, 2014

Hello World with KDE Frameworks 5

I have been wanting to learn KDE development for very long time but couldn't do much in the past due to various reasons. Now, with KDE Frameworks 5 beta releases are out, this is a great time to start.

I am documenting my learning process here for my reference and anybody else on the web who would like to have simple start point.