cloud career

Linux for Cloud Computing (An Introduction and Basic Linux Commands)

Go Cloud Architects > Articles > Uncategorized > Linux for Cloud Computing (An Introduction and Basic Linux Commands)
linux-for-cloud-computing

Linux for Cloud Computing

Today we are going to discuss Linux for Cloud Computing. We’ll cover its prevalence in the cloud, its history, and importance. We will also go over 20 of the top Linux commands for navigating the Linux operating system. If you are a cloud architect, cloud engineer, or technology professional then Linux is a crucial piece of your knowledge skillset.

About the Author

Hello! My name is Michael Gibbs, CEO and Founder of Go Cloud Architects. I’ve been working in technology for well over 25 years. We are dedicated to helping our clients build elite cloud computing careers. I’ve been working in technology for over 25 years, and I’ve spent 20 years of my career coaching or mentoring others to get their first tech job.

In my 25-tech career, I have worked in:

  • Networking
  • Security
  • Cloud computing
  • Teaching
  • Coaching
  • Mentoring

What is Linux

Linux is an extremely common operating system. 90% of all cloud computing systems run on Linux. Most servers and technology-embedded devices run on Linux. It doesn’t matter if you are a cloud architect, cloud engineer, network engineer, network architect; Linux knowledge is important for your career. It is almost everywhere and knowing how to navigate Linux is crucial for your career.

linux-for-cloud-computing

According to Hosting Tribunal, 100% of the world’s top 500 supercomputers run on Linux. And only 2 of the top 25 websites in the world are not using Linux, Furthermore, according to the same article 96.3% of the world’s top one million servers are all running Linux. That’s approximately 37,000 that don’t and 963,000 that do!

Think about that. The vast majority of all cloud servers are running on a Linux kernel and/or a Linux Hypervisor. It’s the Linux control plane that manages and orchestrates the computing power in the cloud. The data plane (computing) is performed on servers with a Linux kernel and hypervisor. Its virtually a guarantee that any cloud provider’s servers are running a Linux kernel on their own hypervisor. Each of these servers is likely communicating through a Linux control plane. Essentially, this means that the entire cloud is on Linux. Linux, Linux, Linux.

linux-for-cloud-computing

A Brief History of Linux & How it Works

To know Linux, it helps to understand it’s history. In 1991, Linus Torvalds came up with the Linux kernel. In truth, Linux is not exactly an operating system. It’s a kernel with additional packages and, over the years, Linux has gained even more functionality.

If you want to become a cloud architect, then you must know Linux and understand the architecture of a Linux system. If you want to become a cloud engineer, then you’re going to be building and configuring Linux. Whether you wish to become a cloud architect or cloud engineer, you must understand how the operating system works. To design systems, you must understand them.

Let’s start with the baseline layer. At the base, you’ve got the hardware layer. The hardware layer is your CPU, your DRAM, your disc.

On top of the hardware layer, and before the software layer, are the kernel modules. Kernel modules are pieces of code that get loaded and unloaded onto the kernel in an on-demand fashion. Device drivers are an example of kernel modules. Kernel modules are pieces of code that are placed in and out of the kernel as needed. If you didn’t have these kernel modules you would have to reboot your system every single time its used.

The next piece of the Linux architecture is the actual kernel itself. The kernel is the core of the operating system. The kernel is responsible for everything. Think of the kernel as what manages memory and CPU resources. All or most critical things are performed by the kernel.

After all that, you have a set of system libraries. These are basically pre-compiled pieces of code. Applications on your system will call upon these common system libraries to do their jobs. Above the system libraries is your user processes, your software, and so on. Realistically speaking, that is the architecture of the Linux module.

Once more, it goes:

  • Hardware at the base
  • Kernel modules & device drivers
  • The Kernel itself
  • Systems Libraries
  • Processes & software

Let’s think about the systems that are running in Linux. Web servers run almost completely on Linux. Servers hosting your databases are hosted almost entirely on Linux. Even your virtualization servers are running on Linux. When you run server virtualization inside of the datacenter, either through KVM or the QEMU hypervisor, you’re running those processes directly through Linux. Even VMware’s ESXi comes from a Linux kernel.

Now Let’s Get Some Hands on Linux Practice

In this section we will walk you through the Linux terminal. For Linux servers most management is performed from the command line. So, if you want to become a great cloud architect, or a talented cloud engineer with an amazing career, then you’ve got to learn Linux. Linux is the basis of all your servers. Servers are your basic infrastructure for everything that goes on the cloud. Your servers host your applications. Your servers host your containers. Your servers host everything. And almost every one of your servers is running on Linux.

Now that you know how the Linux operating system works, we’d like to show you 20 of the top Linux commands.

1. ls – List the Contents of a Directory

Entering ls by itself will simply return the contents of our current directory. We can add options to the end of the command like ls -la or ls -al. This will return all files and hidden files in a long list format. The longlist format will provide additional information of the files such as permissions and owner information.

linux-commands-1
linux-commands-1
linux-commands-2
linux-commands-2
2. echo – Print / Output Text to the Console

This is one of the first commands you will have likely ever seen in Linux. As you might have guessed, the command repeats, or echoes, everything you type. We’ll give you a basic example and print something onto the screen such as, “Hello, Go Cloud Architects!”

linux-commands-3
linux-commands-3
3. touch – Create a File

The touch command allows you to create a file in Linux. We’ll use the touch command to create, or touch, a file named gocloudarchitects. The files created by this command are empty, but you can write inside the files whenever you want.

linux-commands-4
linux-commands-4
4. mkdir – Make Directory Command

In Linux, one of the easiest ways to organize things is with a directory. We’ll simply use the make directory command to – you guessed it – make a directory.

linux-commands-5
linux-commands-5
5. grep – Global Regular Expression Print / Search for a String or Regular Expression

Grep enables you to search for a string or regular expression. When grep finds a match to your query, it prints that line to console. This is especially useful when combing through substantial files. Below, we’ll grep a file named Research to look for the phrase awards and honors.

linux-commands-6
linux-commands-6
6. man – Display the User Manual for Any Command

The man command is probably one of the most useful commands. It gives you a detailed overview of exactly how to use the command. As you can see, Linux has a built-in set of instructions.

linux-commands-7
linux-commands-7
7. pwd – Print the Working Directory

This command lets you know exactly where you are located within the file system. It is a simple command, but you will be using it quite frequently.

linux-commands-8
linux-commands-8
8. cd – Change Directory

Change your directory and navigate to the directory of your choosing. We’ll change to the root directory in our example.

linux-commands-9
linux-commands-9
9. mv – Move

The mv command allows you to move directories and files from one place to another. In the following example, we’ve moved our text file ‘gocloudarchitects’ and into the directory newdir/.

linux-commands-10
linux-commands-10
10. head – Output the Beginning (head) of a File / Files

The head command allows you to look at the beginning of a file. As you can see in our example, we’ve looked at the beginning of the file named John Chambers Research.

linux-commands-11
linux-commands-11
11. find – Find Command

This command allows you to search for files in Linux. You can use the super user permissions with this command to find things that are outside of your local directory. Below is me searching for my OS-release and being returned the files. (Ignore the permission denied. That’s the mount point for the FUSE interface to the Gnome Virtual Filesystem. It’s a known issue, but is nothing to worry about.)

linux-commands-12
linux-commands-12
12. less – Less Command

The less command allows you to peruse a file line by line or one page at a time. This is preferred when the text file is massive. If you used a traditional text editor like vim or nano, you might become overwhelmed by the sheer wall of text. Below is the output of us using the less command on our /etc/os-release file.

linux-commands-13
linux-commands-13
13. cat – Concatenate

The cat command is very similar to the previous command. Instead of using a text editor to view a file, like vim or nano. You can use the cat command to display the contents of a file like we did with our John Chambers Research file.

linux-commands-14
14. tail – Tail Command

The tail command is the exact opposite of the head command. Tail outputs the very last lines of a file.

linux-commands-15
linux-commands-15
15. chmod – Change Mode

The Change Mode, or chmod, command allows you to optimize the permissions of a file, directory, or script. Below, we’ve changed the permissions of the gocloudarchitects file so that only the Owner can read, write, or execute. All other Groups and users can only read the file.

linux-commands-16
linux-commands-16

16. history – History Command

The history command allows you to see every single line that you have typed inside of your current session. This tool is useful because you may have forgotten what commands you have previously entered.

linux-commands-17
linux-commands-17
17. curl – Client URL Command

This command allows you to transfer data over various network protocols. For example, you can pull a file or a series of files from a website.

linux-commands-18
linux-commands-18
18. cp – Copy Command

The cp command allows you to copy files and folders and move them to another location. Alternatively, you can create a copy and save a backup. As you can see, I created a backup with the copy command.

linux-commands-19
linux-commands-19
19. top – Table of Processes

This command displays the running processes with the Linux system. This information is updated and shown to you in real-time. The useful information is CPU & memory utilization.

linux-commands-20
20. kill – Kill Command

The kill command allows you to kill an application process. This is particularly useful if a command is going haywire or functioning improperly. You can use the kill command to stop that process completely. As you can see in the example: I’ve killed the process for top by specifying its PID of 5506.

linux-commands-20
21. Bonus Command: exit – Exit command

As a bonus, we’ve included arguably the most useful Linux command. The exit command. This command is rather straight forward. It’s called the exit command. It allows you to exit from an SSH or terminal session. As you can see below, I’ve entered the exit command. This exit command closed our terminal session and returned us to the Ubuntu desktop.

linux-commands-22
linux-commands-22
linux-commands-23
linux-commands-23

How Can We Help You Reach Your Dream Career?

Career Development Programs

At Go Cloud Architects our goal is to improve the cloud computing community as a whole, by developing individuals to succeed in their roles. Our Career Development Programs are designed to help you get the best career at the fastest speed possible. These programs not only provide technical training, but also the much-overlooked soft skills and emotional intelligence that determine whether an individual can reach that dream career. In these group training programs, we provide a combination of live group training sessions, on-demand web-based content, and extensive labs. We also provide server access to our students, to build their own cloud architectures from the ground up. You can find more information on the programs by clicking the button below.

Cloud Architect Career Development Program

Our FREE Offerings Every Week

Mondays and Thursdays

Go Cloud Architects offers the “How to get your first cloud architect job webinar twice a week on Monday at 9:00 AM EST, and Thursday at 12:00 PM EST. You can register for the next call here. We conduct a presentation in the beginning and afterward, participants can ask any questions they want. We will even help build a career plan LIVE on these free calls. We will talk about:

  • What employers desire
  • How to build a perfect resume
  • How to get your name out to the community
  • How to get hired
  • Things to do on your interview

Register for the How to Get Your First Cloud Job Webinar

With Our Compliments

Go Cloud Architects is truly excited to offer multiple FREE resources for AWS Certification training. These include:

We look forward to you joining our Go Cloud Architects community!

Admin

Leave a Reply

35% Black Friday DiscountOur Largest Discount Ever!

Use code "blackfriday" at checkout to receive 35% off.

35% Black Friday SpecialOur Largest Discount Ever

Use special code "blackfriday" at checkout to receive 35% off.

%d bloggers like this: