In the previous tutorial, Linux with all its integral components was examined on the lines of being a complete open source operating system. Many different Linux distributions (also called Distros in short) were also very briefly mentioned at the end of the previous tutorial. There are hundreds of Linux Distros there and it can be intimidating to choose one, when, all it matters is, to have just a sound beginning. An almost exhaustive list and links of available Linux distributions can be checked on DistroWatch.com. Not just the number of available Linux Distributions is enough to trick any Linux beginner, the choice of computing platform can further perplex the situation. The Linux with full features and abilities can be run on desktop, server, IoT boards and cloud platforms. So, there are not one though many ways to head start with Linux.
For a beginner in the Linux world, taking initial objective to have hands dirty on shell scripting, IoT boards and desktop systems are most suitable to start with. Most of the Linux Distributions come available in desktop as well as server editions. The desktop editions can be tested with Live CDs (that can be downloaded from internet sources) to have a taste of a couple of Linux Distributions. After getting the look and feel of few Linux Distributions, one can install a chosen distro on regular desktop either with the help of CD/DVD or a bootable USB drive.
Apart from Desktop versions, many Linux distributions can be run on IoT boards. Running Linux on an IoT board has the advantage that one can begin his/her Linux journey without disturbing the regularly used desktop system considering the fact that Linux (particularly Shell Scripting and Command Line) can be initially daunting for someone used to rich graphic user interfaces of operating systems like Windows and Mac.
In this series, Raspberry Pi 3 has been taken to build a desktop like system and Raspbian is installed on it. Raspbian is based on Debian Linux just like Ubuntu and many other popular Linux Distros. Raspbian has its own default desktop called Raspberry Pi Desktop. So, one gets the same Windows or Mac like graphic interface on Raspberry Pi upon installing the Raspbian.
Another convenient option to start learning Linux on Raspberry Pi is Ubuntu Mate. Ubuntu is one of the most popular Linux Distributions based on Debian which comes with Unity as default Desktop. There are different derivatives of Ubuntu available for server, desktop, IoT boards and Cloud Platforms. Ubuntu Mate is an official derivative of Ubuntu. It has MATE as the default desktop environment instead of Unity or GNOME (which are default desktops in Ubuntu Desktop Distributions).
Either Raspbian or Ubuntu Mate can be installed on Raspberry Pi. For Shell Scripting, both have a terminal application where shell commands can be tested and tried.
Fig. 1: Screenshot of Linux Terminal Console on Raspbian
Why Raspbian –
Raspbian is the official operating system for Raspberry Pi. It is a Linux Distribution based on Debian. Raspbian is maintained by Raspberry Pi Foundation. The latest revision of Raspbian (released on June 29, 2018) is based on Linux Kernel 4.14. Raspbian is regularly updated and maintained. The learning experience of Linux using Raspbian can be expanded to embedded applications that require operating system and also to embedded Linux.
Why Ubuntu Mate –
Ubuntu is a popular Linux Distribution based on Debian. Debian, no doubt, is the most popular and widely adopted core Linux distribution. Ubuntu is supported by Canonical Ltd, Ubuntu Foundation and Ubuntu Community with periodic release of updated versions in every six months. Ubuntu Mate supports IA-32, x86-64, PowerPC and ARMv7 processors. The Raspberry Pi 2 and 3 being based on ARMv7 architecture can install Ubuntu Mate as operating system. Ubuntu Mate gives a Linux experience similar to any other standard Linux Distribution.
Any Linux distribution packages many add-on applications and several applications can be downloaded from online repository of that distribution. With around 42,026 open source software projects in repository, Ubuntu has wide range of applications available. Some of the popular Ubuntu attractions from its software repository include Bazaar, Unity, Terminator, MySQL, Open Stack, Openshot Video Editor, Shutter, SteadyFlow, Inkscape etc.
One crucial attraction in Ubuntu is Launchpad. The Launchpad is a software collaboration platform that provides bug tracking, code hosting, code reviews, translations, mailing lists, answer tracking and many other features. This let connect with the Linux community and have active participation as well as aid there in.
Ubuntu Core is another Ubuntu Derivative that can be installed on Raspberry Pi. It is useful when Raspberry Pi is setup as a server. For using Raspberry Pi as a desktop, Ubuntu Mate is suitable.
Setting Up Raspberry Pi Desktop –
The following hardware components are required to setup a Raspberry Pi Desktop –
1) Raspberry Pi 3
2) Power Adaptor for Raspberry Pi 3
3) LCD/LED Monitor
4) HDMI Cable
5) USB Keyboard
6) USB Mouse
7) MicroSD Card
Connect the LCD/LED monitor with the Raspberry Pi using HDMI Cable and attach the keyboard and mouse to the USB ports. Download and Load Raspbian or Ubuntu Mate on MicroSD card. Insert the card in the MicroSD slot of the Pi. Then, connect power adaptor and power on the monitor and the Raspberry Pi. Ubuntu Mate or Raspbian which ever loaded on the MicroSD card will install on powering the device for the first time. Later whenever the Pi will be powered on, the installed operating system (Raspbian or Ubuntu Mate) will boot up automatically.
Installing Raspbian on Raspberry Pi 3 –
For installing the Raspbian Operating System on MicroSD card, first download the latest image of Raspbian OS from Raspberry Pi website from the following link –
Copy the image of the latest Raspbian OS in the MicroSD card. If the MicroSD card used is 32 GB or below, it must be formatted to FAT32 (file system) before copying the image or if the MicroSD card is more than 32 GB, it should be formatted to exFAT before copying the image. Extract the OS Zip and copy it to the MicroSD card. The image can be written to the card by connecting the card to a laptop or PC using a MicroSD card reader. After copying the extracted image, insert the card in the MicroSD slot as shown below –
Fig. 2: Image of Raspberry Pi 3 MicroSD Card Slot
Connect the Raspberry Pi with a display monitor using HDMI Cable, a keyboard and a mouse. Power on the board by connecting to a power adaptor. The red LED on the board will start blinking and the OS will start booting from the MicroSD card. The boot process will display on the monitor and once the boot is complete, green LED will light up on the Raspberry Pi.
Installing Ubuntu Mate on Raspberry Pi 3 –
Installing Ubuntu Mate on Raspberry Pi 3 is similar to installing Raspbian. The latest release of Ubuntu Mate (supporting Raspberry Pi) can be downloaded from Raspberry Pi website from the following Link –
Ubuntu Mate for Raspberry Pi 2 and 3
The installation procedure for Ubuntu Mate is same as of Raspbian. Once the boot is complete, green LED will light up on the Raspberry Pi. Note that throughout this series, shell scripting has been tried on Raspbian.
Bash Shell –
Bash is the default shell in most of the Linux distributions. For opening Bash in Linux distributions having some default desktop, one simply needs to open the Terminal application. In Raspbian, click the Raspberry Pi icon and navigate to Accessories -> Terminal. A window will pop up. This is bash shell. The shell commands and scripts can be written and tested here.
From the next tutorial – Getting Started with Shell Scripting, it’s time to get hands dirty and begin writing some shell codes.
Filed Under: Featured Contributions
Questions related to this article?
👉Ask and discuss on EDAboard.com and Electro-Tech-Online.com forums.
Tell Us What You Think!!
You must be logged in to post a comment.