All about Linux

All about Linux

Table of contents

No heading

No headings in the article.

Linux is an open-source operating system(OS). It was proposed by the Finland student Linux Torvalds in 1991.

Operating System (OS)
An OS is the software that directly manages a system's hardware and resources, like CPU, memory, and storage. Its between application and hardware and make the connections between all your software and the physical resources.

What's a command line?

The command line is your direct access to a computer.

What's the Linux Kernel?

The Linux kernel is the main component of a Linux operating system(OS) and its the core interface between a computer's hardware and its processes. Its does 4 important jobs:

  1. Memory Management

  2. Process Management

  3. Device drivers

  4. System calls and security

Versions of Linux

The version of Linux are distributions of Linux. Popular distributions include:

  • Amazon Linux

  • CentOS

  • Fedora

  • Oracle Linux

  • SUSE Linux

  • Ubuntu

IBM Red Hat/ Red Hat Enterprise Linux (RHEL)


Linux Architecture


What's the Linux Shell?

The shell is a command interpreter through which users can interact with Kernel or you can say OS. In the old days, it was the only user interface available on a Unix-like system. Nowadays we have GUI in addition to CLI (command line interface).

On most Linux systems a program called bash (Bourne Again SHell, an enhanced version of the original Unix shell program, sh, written by Steve Bourne) acts as the shell program. Besides bash, there are other shell programs available for Linux systems. These include ksh, tcsh, zsh.


Linux Filesystem Hierarchy Standard (FHS)

Linux file system has a hierarchal file structure as it contains a root directory and its subdirectories and is structured in a tree-like hierarchy.

DirectoryDescription
/ (root filesystem)It is the top-level directory of the filesystem. It must contain all of the files required to boot the Linux system before other filesystems are mounted. It must include all of the required executables and libraries required to boot the remaining filesystems. After the system is booted, all other filesystems are mounted on standard, well-defined mount points as subdirectories of the root filesystem.
/binIt contains user executable files.
/bootContains the static configuration and files of the bootloader required to boot a Linux computer.
/devThis directory contains the device files for every hardware device attached to the system.
/etcContains host-specific system configuration
/homeHome directory storage for user files. Each user has a subdirectory in /home.
/libContains shared library files that are required to boot the system.
/mediaMount point for removable media devices such as USB thumb drives that may be connected to the host.
/mntA temporary mount point for regular filesystems (as in not removable media) that can be used while the administrator is repairing or working on a filesystem.
/optOptional files such as vendor-supplied application programs should be located here.
/rootThis is not the root (/) filesystem. It is the home directory for the root user.
/sbinSystem binary files. These are executables used for system administration.
/tmpTemporary directory. Used by the operating system and many programs to store temporary files. Users may also store files here temporarily. Note that files stored here may be deleted at any time without prior notice.
/usrThese are shareable, read-only files, including executable binaries and libraries, man files, and other types of documentation.
/varVariable data files are stored here. This can include things like log files, MySQL, other database files, web server data files, email inboxes, and much more.

Some example of a FHS-compliant system:

"Shareable" files are those that can be stored on one host and used on others. "Unshareable" files are those that are not shareable. For example, the files in user home directories are shareable whereas device lock files are not.

"Static" files include binaries, libraries, documentation files and other files that do not change without system administrator intervention. "Variable" files are files that are not static.