0

Linux for Dummies

How Linux Works: A Peek Inside the Penguin’s World

Linux, often associated with the omnipresent mascot Tux the Penguin, is more than just an operating system. It represents an ideology, a movement, and a powerful platform that runs everything from supercomputers to household gadgets, matter a fact this site is running on linux just like the show you are watching on Netflix. But how exactly does Linux function? Let’s dive in.

What is Linux?

At its core, Linux is a free and open-source operating system (OS) based on the Unix architecture. It has grown in popularity over the decades due to its security, reliability, and customization capabilities due to it being open-source.

The Kernel, aka: The heart of Linux

The core component of Linux is the “kernel.” It’s responsible for managing the system’s resources and interfacing with hardware components. It does this by:

  • Handling process management: determining the order and priority of tasks.
  • Managing memory: ensuring that each process gets the RAM it needs.
  • Interfacing with hardware: facilitating communication between software and physical components like hard drives or GPUs.

The Shell: Communicating with the Kernel

Maybe you have seen movies where hackers or smart IT guys having an excessively amount of screens with text running on a black screen, that is probable the shell. The shell acts as the intermediary between the user and the kernel. It’s a command-line interface (CLI) where users can input commands to perform tasks. Popular shells include Bash, Zsh, and Fish.

System Libraries

Libraries contain codes that software can use to perform specific tasks. Instead of writing a piece of code from scratch every time it’s needed, developers can call on these libraries. This ensures efficiency and consistency in application development. These are often located in /lib or /Library.

File System: Organizing Data

Linux organizes data in a hierarchical file system, with the root (‘/’) as the base. This hierarchy ensures a structured and consistent approach to data management. Key directories include:

  • /bin: Essential user command binaries
  • /etc: Configuration files
  • /home: User home directories
  • /var: Variable data such as logs and databases

Processes and Daemons: Doing the Work

Processes are the running instances of programs. They’re managed by the kernel, which allocates resources to ensure smooth execution. Daemons are background services that start up with the system, such as network managers or database servers.

Package Managers: Software Installation Made Easy

Linux distributions come with package managers that simplify the process of installing, updating, and managing software. Examples include apt for Debian-based systems, yum for Red Hat-based systems, and pacman for Arch Linux.

In the labs I will be using brew and apt to install packages. For the best experience in the labs install HomeBrew. Here is a link for instructions: https://brew.sh

Conclusion

Linux, with its robust kernel, efficient file system, and powerful command line, stands as a testament to what collaborative, open-source efforts can achieve. Its adaptability makes it suitable for servers, desktops, phones, and even household gadgets. As you use and perhaps dive deeper into the world of Linux, you’ll discover the immense power and potential that lies beneath its penguin exterior.

What’s next?

If you want to get your hands dirty I suggest to go and checkout the basic hands on guide on Linux listed under “Hands-on Lab”

I hope this post got you a better understanding of when Linux is and how it works.

Big Love Philip