Linux is EVERYWHERE, and believe it or not… you probably use it every day without even knowing it! Android mobiles, supercomputers, smart TVs, smart cars, home appliances and much much more!
A few years ago I started my journey in Linux, I studied and passed the Linux Comptia+ certification. This post is all about Linux and why you really need to learn it!
What is Linux
Chances are high right now that you are either using a Windows or Mac computer? Well, Linux is simply just another operating system like Windows and macOS, and similar to how you have different versions of Windows (7,8,10) and macOS (Catalina, Big Sur, Monterey) there are many different versions and distributions of Linux.
Linux powers things such as:
- Android
- Websites
- In-car entertainment
- Checkout tills and registers in shops
- Critical infrastructure such as traffic light controllers or
- Industrial sensors
Here are some Linux facts to get you thinking:
- In 2022, the lines of code submitted to the Linux Git repository reached 28 million
- 90% of all cloud infrastructure operates on Linux
- Out of the top 25 websites in the world, only 2 aren’t using Linux
- In 2021, 100% of the world’s top supercomputers run on Linux
Who created Linux
Linux was created by a man called Linus Benedict Torvalds, he’s a Finnish-American software engineer. He was the creator and historically the main developer of the Linux Kernal. He’s also the man behind distributed version control system Git.
If you want to read into Linux and its long history, you can do that here.
Flavours of Linux
Linux is very different to other operating systems, sure it can have a graphical user interface and the same types of applications such as web browser, email and word processor etc… however, the name “Linux” is actually an umbrella term for multiple OS’s that are based on UNIX, which is another operating system.
Since UNIX is open-source, there are lots of different variants of Linux, these come in all shapes and sizes and are most commonly best suited for what the system is being utilized for. Ubuntu, Fedor and CentOS are some of the most popular distributions of Linux, these have been heavily developed by the open-source community and are widely used. For example, you can run Ubuntu as a server running services such as websites and applications, or you can run it as a fully-fledged desktop.
Testing Linux
Ok, there are a few different ways to test Linux… You can test in the cloud, locally on your own laptop or via the web browser.
I won’t cover them all here, but if you are familiar with cloud technology then you can easily build a Unbuntu server on AWS, GCP or Azure.
You can also download your own copy and run it as a virtual machine on your computer. The first thing to do is download and install free VMware Player. Then, get the latest version of Ubuntu here or download CentOS here. Create a new VM in VMware Player and use the ISO file you downloaded.
Finally, you can test via the web browser, while researching for this post I googled and found loads of websites, however, DistroTest seemed to have the most comprehensive list.
Your first commands
OK, so you have a server up and running and you’re ready to go?
No better way to learn anything new than getting hands-on, therefore I’ve listed a few commands below to get you navigating around the operating system.
Navigating your way around takes a little getting used to, you don’t have a GUI or mouse to click from folder to folder, therefore you need to know the following commands.
List files in the current directory (ls)
The ls command, which is short for listing, is used to list files that already exist in the current directory.
Change directory (cd)
The cd command, which is short for change directory allows you to move around the Linux directory. For example, if I had a folder called Gerard, located in the Home directory, I could simply type cd gerard to navigate that directory. You can also navigate to other folders such as the etc folder by entering the commands below… cd /etc/.
Concatenate (cat)
The cat command is short for concatenate. This allows you to output the contents of a file. In the screenshot below, I use the ls command to check what files are in the current directory, then I type the cat filename command to view the contents of the test.text file.
Print working directory (pwd)
The pwd command is one of my favorites, as you navigate through the Linux directory its very easy to get lost. This simple command lets you know where you are. This is especially handy when you are moving files from directory to directory.
Output text (echo)
Simple, echo just means output any text we provide.
Who is logged in (whoami)
The whoami command allows you to see what user you are currently logged in as.
Searching for files (find)
The find command is another beauty, there’s so much to know about the find command. It can be as basic or as complicated as you need it to be.
In the screenshot below I have used the find command to search for the text.text file, all you need to do is type find -name and the name of the file. In the example below I have searched for the test.text file.
If you want to search for all files of a certain type, you could also use the find -name *.text command.
Conclusion
I hope you have enjoyed this very brief introduction to Linux, if you are currently working in a Network, Cloud, Security or Application field then understanding and gaining some Linux skills will really set you apart.