DevOps · K8s · Volleyball · Travel  •  DevOps · K8s · Volleyball · Travel  •  DevOps · K8s · Volleyball · Travel
Explore NY Stream

Introduction to Linux Operating System

— ny_wk

Introduction to Linux Operating System

The Linux operating system is a free, open-source, multi-user platform built on Unix design principles, where everything is treated as a file and the system is organized as a single inverted tree of directories. Understanding the Linux architecture, its kernel-shell-utility layers, and the standard filesystem hierarchy is the foundation every system administrator, developer, and DevOps engineer needs before touching a single command.

This guide walks you from the absolute basics—what an operating system actually does—through the core Unix philosophy, the three-layer Linux architecture, and a directory-by-directory tour of the filesystem. Where the older tutorials taught outdated details, this version uses the modern, correct equivalents you will see on a real Linux server today.

What Is an Operating System?

An operating system (OS) is the software layer that sits between you and the computer hardware. Hardware only understands binary—sequences of 0s and 1s—while humans think in words and clicks. The OS translates your instructions into something the processor, memory, and disks can execute, and translates the results back into a form you can read.

Without an OS, a computer is just inert metal and silicon. The operating system manages the CPU, allocates memory, talks to storage and network devices, enforces security, and provides a consistent environment for applications to run. The Linux operating system does all of this while remaining open source, meaning anyone can read, modify, and redistribute its source code.

Types of Operating Systems

Operating systems are commonly grouped by how many users and how many tasks they handle at once:

TypeDescriptionExamples
Single user, single taskingOne user, one task at a timeMS-DOS
Single user, multitaskingOne user, many tasks at onceOlder Windows desktops (95/XP/7), classic macOS desktop sessions
Multi-user, multitaskingMany users, each running many tasks, sharing resources simultaneouslyLinux, Unix, Windows Server

Linux is a true multi-user, multitasking operating system. Dozens of users can be logged in at the same time—over SSH, locally, or through services—each running their own programs while the kernel fairly shares the CPU, memory, and disk between them. This design is exactly why Linux dominates servers, the cloud, and supercomputing.

The Unix Philosophy Behind Linux

Linux inherits its design from Unix, and a handful of guiding principles explain why the system behaves the way it does. Internalizing these makes every later command feel logical rather than arbitrary.

  • Everything is a file. Documents, directories, hardware devices, running processes, and even network sockets are exposed as files. Because access to a file can be controlled with simple permissions, securing a hard disk works the same way as securing a text document. This single idea unifies the whole system.
  • Configuration is stored in plain text. System settings live in readable text files, mostly under /etc. You can copy a config from one machine to another, track it in version control like Git, diff two versions, and roll back to an earlier state—none of which is easy with an opaque binary registry.
  • Small, single-purpose programs. Each tool does one job well. grep searches, sort orders, wc counts. Mastering a few sharp tools beats wrestling one giant application.
  • Avoid captive user interfaces. Unix tools assume you know what you are doing and do not nag you with constant prompts. This makes them ideal for scripting and automation, but it also means a command like rm deletes without asking—so think before you press Enter.
  • Chain programs together. The output of one program can become the input of another using a pipe (|). By combining small tools you assemble powerful one-liners that solve complex problems no single program was designed for.

For example, this single pipeline lists the five processes using the most memory—four small tools cooperating:

  1. ps aux — list every running process
  2. sort -rk4 — sort by the memory column, highest first
  3. head -n 6 — keep the header plus the top five

Put together: ps aux | sort -rk4 | head -n 6. That is the Unix philosophy in action.

The Architecture of the Linux Operating System

The Linux operating system architecture is layered, and you can picture it as three concentric rings around the hardware. Each layer has a clear responsibility and only talks to the layers immediately next to it.

1. The Kernel (the core)

The kernel is the heart of Linux and the only part that talks directly to the hardware. It is responsible for:

  • Process scheduling — deciding which task runs on the CPU and for how long.
  • Memory management — allocating and protecting RAM, handling virtual memory and swap.
  • Device drivers — communicating with disks, network cards, and other hardware.
  • Security and access control — enforcing user permissions and isolating processes.

Technically, "Linux" refers specifically to this kernel, originally written by Linus Torvalds in 1991. A complete usable system pairs the kernel with GNU utilities and other software—which is why you sometimes see the name "GNU/Linux." You can check your running kernel version any time with uname -r.

2. The Shell (the interpreter)

The shell is the command interpreter that sits between you and the kernel. It reads the commands you type, interprets them, launches the right programs, and returns the output. The default shell on most modern Linux distributions is Bash (the Bourne Again Shell), though zsh and others are popular too. Run echo $SHELL to see which shell you are using.

3. Utilities and Applications (the user level)

The outermost layer is the collection of utilities and applications—the everyday commands and programs you actually run, from ls and cp to web servers and databases. This is the user level, because it is where you, the operator, do your work. Your commands flow inward through the shell to the kernel, and results flow back outward to you.

The Linux Filesystem Hierarchy Explained

Unlike Windows, which uses separate drive letters like C:\ and D:\, the Linux filesystem uses a single, unified, inverted-tree structure. Everything branches from one top-level directory called root, written as a single forward slash (/). Every disk, partition, and removable drive is attached ("mounted") somewhere inside this one tree.

This layout follows the Filesystem Hierarchy Standard (FHS), so the same directories appear in roughly the same place across distributions. Here are the directories you will use most, with their purpose and a Windows analogy where one helps.

DirectoryPurposeRoughly like (Windows)
/The root directory—parent of everything elseC:\
/rootHome directory of the root (superuser) accountAdministrator's profile
/homeHome directories for all regular usersC:\Users\
/bootFiles needed to boot: the kernel, initramfs, GRUBBoot files
/etcSystem-wide configuration files (plain text)Settings / Registry
/bin, /usr/binEssential command binaries for all usersC:\Windows\System32
/sbin, /usr/sbinSystem binaries, mostly for the superuserAdmin tools
/usrUser programs, libraries, and shared dataC:\Program Files
/optOptional / third-party application packagesC:\Program Files
/varVariable data: logs, mail spools, caches, databasesProgramData / logs
/devDevice files representing hardwareDevice Manager
/procVirtual filesystem exposing kernel and process infoTask Manager internals
/lib, /usr/libShared libraries used by binariesDLL files
/mnt, /mediaMount points for temporary and removable storageDrive letters for USB/CD
/tmpTemporary files, usually cleared on rebootTemp folder

A Closer Look at the Most Important Directories

  • /boot holds the compressed kernel (a file named like vmlinuz), the initial RAM filesystem (initramfs, the modern replacement for the older initrd), and the bootloader. Most distributions now use GRUB 2 (GRand Unified Bootloader), which replaced the original GRUB—the rough Windows counterpart is the Windows Boot Manager.
  • /etc is where configuration lives. Key examples include /etc/passwd (user account information), /etc/resolv.conf (DNS resolver settings), and /etc/fstab (filesystems mounted at boot). Because these are plain text, you can edit them with any editor and back them up trivially.
  • /dev contains device files. On modern systems the first SATA, SAS, or USB disk is /dev/sda (older IDE-only naming like /dev/hda is obsolete), NVMe SSDs appear as /dev/nvme0n1, and there are special files such as /dev/null and /dev/zero.
  • /proc is a virtual filesystem—its files do not exist on disk but are generated live by the kernel. Read /proc/cpuinfo for processor details and /proc/meminfo for RAM and swap usage. Its contents change constantly because they reflect the running system.
  • /var grows over time with variable data. System logs traditionally live in /var/log, which is the first place to look when troubleshooting.

Getting Started: Your First Commands

The fastest way to make all of this concrete is to explore the system yourself. On any Linux machine—a server, a virtual machine, or the Windows Subsystem for Linux (WSL)—open a terminal and try these safe, read-only commands in order:

  1. pwd — print the working directory (where you are now).
  2. ls / — list the contents of the root directory and spot the folders described above.
  3. cd /etc then ls — move into the config directory and look around.
  4. cat /etc/os-release — identify which distribution and version you are running.
  5. uname -a — print the kernel version, architecture, and hostname.
  6. whoami — confirm which user you are logged in as.
  7. man ls — open the built-in manual for any command (press q to quit).

None of these modify anything, so they are perfectly safe for a first session. The man command in particular is your most valuable resource—every standard tool documents itself.

Common Pitfalls for Linux Beginners

A few mistakes trip up nearly everyone moving to the Linux operating system. Knowing them in advance saves hours of frustration.

  • Forgetting Linux is case-sensitive. File.txt, file.txt, and FILE.txt are three different files. Windows treats them as the same.
  • Running everything as root. The superuser can delete or break anything with no confirmation. Work as a normal user and use sudo only for the specific commands that need elevated rights.
  • Treating rm like a recycle bin. There is no undo. rm -rf on the wrong path is permanent—double-check before you confirm.
  • Using backslashes for paths. Linux paths use the forward slash (/home/user), not the Windows backslash.
  • Ignoring permissions. "Permission denied" almost always means the file's owner/group/other bits do not allow your action—inspect them with ls -l.

Verification: Confirm Your Understanding

You can prove that the concepts above are real on your own machine. Each check below maps directly to a section of this guide:

  • Confirm the single-rooted tree: run ls / and verify you see etc, home, usr, var, and the rest—all under one /.
  • Confirm everything is a file: run ls -l /dev/sda (or /dev/nvme0n1) and see your disk listed as a file entry.
  • Confirm the kernel layer: run uname -r to print the exact kernel version managing your hardware.
  • Confirm the shell layer: run echo $SHELL and pipe two commands together, e.g. ls /etc | wc -l, to count config entries.
  • Confirm plain-text config: run head -n 3 /etc/passwd and read real, human-readable account data.

If every command returns sensible output, you have a working mental model of how Linux is organized—and a solid base for learning user management, permissions, networking, and shell scripting next.

Key Takeaways

  • An operating system is the translator between human instructions and binary hardware; Linux is a free, open-source, multi-user, multitasking OS.
  • The Unix philosophy—everything is a file, text-based config, small tools, and chaining with pipes—explains why Linux behaves the way it does.
  • The Linux architecture has three layers: the kernel (hardware and scheduling), the shell (command interpreter, usually Bash), and utilities (the user level).
  • The Linux filesystem is a single inverted tree rooted at / and standardized by the FHS, with predictable directories like /etc, /home, /var, and /dev.
  • Start safely with read-only commands (ls, pwd, uname, man), avoid running as root, and remember Linux is case-sensitive.

Frequently Asked Questions

Is Linux an operating system or a kernel?

Strictly speaking, Linux is the kernel—the core that manages hardware, memory, and processes. A complete, usable operating system combines the Linux kernel with GNU utilities, a shell, and other software, which is why it is sometimes called GNU/Linux. In everyday speech, "Linux" refers to the whole distribution.

Why does Linux say everything is a file?

Linux exposes documents, directories, hardware devices, and even running processes through the filesystem as file-like objects. This unifies the system: one consistent set of permissions and tools can read, write, and secure anything—whether it is a text document or a hard disk under /dev.

What is the difference between the Linux filesystem and Windows drives?

Windows assigns each disk a separate letter (C:\, D:\). Linux uses one unified tree starting at /, and every additional disk or partition is mounted into a directory inside that tree. There are no drive letters—just one consistent hierarchy.

Which Linux distribution should a beginner start with?

Ubuntu and Linux Mint are the most beginner-friendly for desktops, while Ubuntu Server, Debian, and Rocky Linux are common for learning server administration. All share the same architecture and filesystem hierarchy covered here, so the skills transfer directly between them.

If this guide helped Linux finally click for you, subscribe to @explorenystream on YouTube for more clear, practical Linux and sysadmin tutorials.