Skip to main content

Command Palette

Search for a command to run...

🐧 Linux Interview Questions Every DevOps Engineer Must Know

Published
3 min readView as Markdown
🐧 Linux Interview Questions Every DevOps Engineer Must Know
M

Tech enthusiast | Code craftsman | DevOps explorer | Turning bugs into features one line at a time 🚀

🔰 Beginner-Level Linux Interview Questions

1️⃣ What is Linux?

Linux is an open-source, Unix-like operating system kernel used to manage hardware resources and provide services to applications.

📌 Examples:

  • Ubuntu

  • CentOS

  • Amazon Linux

  • Red Hat Enterprise Linux (RHEL)


2️⃣ What is the Linux Kernel?

The kernel is the core of the operating system that:

  • Manages CPU, memory, and devices

  • Handles process scheduling

  • Acts as a bridge between hardware and software


3️⃣ Difference between Linux and Unix?

LinuxUnix
Open sourceMostly proprietary
FreePaid
Community drivenVendor controlled
Widely used in cloudLimited usage

4️⃣ What is a Shell?

A shell is a command-line interface that allows users to interact with the Linux OS.

Popular shells:

  • bash

  • zsh

  • sh


5️⃣ Common Linux Commands

ls      # list files
pwd     # current directory
cd      # change directory
mkdir   # create directory
rm      # delete file
cp      # copy file
mv      # move/rename file

⚙️ Intermediate-Level Linux Interview Questions

6️⃣ What is the difference between rm and rm -r?

  • rm file → deletes a file

  • rm -r dir → deletes a directory recursively


7️⃣ What are Linux file permissions?

Linux permissions are:

  • Read (r) – 4

  • Write (w) – 2

  • Execute (x) – 1

Example:

chmod 754 file.sh

Meaning:

  • Owner: rwx

  • Group: r-x

  • Others: r--


8️⃣ What is a process in Linux?

A process is a running instance of a program.

Commands:

ps
top
htop
kill

9️⃣ Difference between ps and top?

pstop
Static outputReal-time
SnapshotDynamic
LightweightInteractive

🔟 What is a daemon?

A daemon is a background process that runs continuously.

Examples:

  • sshd

  • cron

  • systemd


🧠 Advanced Linux Interview Questions

Hard LinkSoft Link
Same inodeDifferent inode
Cannot cross filesystemCan cross filesystem
Works even if original deletedBreaks if original deleted

1️⃣2️⃣ What is inode?

An inode stores metadata about a file:

  • File size

  • Permissions

  • Owner

  • Disk location

📌 File name is not stored in inode.


1️⃣3️⃣ What is swap space?

Swap is disk space used as virtual memory when RAM is full.

Commands:

free -h
swapon -s

1️⃣4️⃣ What is cron?

cron is a job scheduler used to run tasks automatically.

Example:

0 2 * * * backup.sh

➡ Runs daily at 2 AM


1️⃣5️⃣ Explain booting process in Linux

  1. BIOS/UEFI

  2. Bootloader (GRUB)

  3. Kernel

  4. init/systemd

  5. User space


🚀 Linux + DevOps Interview Questions

1️⃣6️⃣ How Linux is used in DevOps?

  • Running Docker containers

  • Managing Kubernetes nodes

  • CI/CD pipelines

  • Cloud servers (AWS EC2, GCP, Azure)


1️⃣7️⃣ Difference between systemctl and service?

systemctlservice
Used in systemdUsed in SysVinit
ModernLegacy
More controlLimited

📝 Final Tips for Linux Interviews

✔ Practice commands daily
✔ Understand why, not just how
✔ Use real-world examples
✔ Learn Linux from a DevOps perspective


📌 Conclusion

Linux is not just an operating system — it’s a core skill for DevOps engineers. Mastering Linux fundamentals gives you confidence in interviews and real production environments.

More from this blog

Untitled Publication

78 posts