🔥 1. Advanced Linux Basics (Expected Depth) ❓ What happens when you run a command in Linux? 👉 Expected: Shell interprets command Checks PATH Forks process Uses exec() system call Kernel schedules execution ❓ Difference between process and thread? Process = independent memory Thread = shared memory within process ❓ What is load average? 👉 Example: uptime 1 min, 5 min, 15 min CPU load Compare with CPU cores ⚙️ 2. Process Management (Scenario-Based) ❓ A process is consuming 100% CPU. What will you do? 👉 Steps: top / htop ps -ef | grep renice -n 10 -p kill -15 kill -9 ❓ Difference between kill -9 and kill -15? -15 (SIGTERM) → graceful -9 (SIGKILL) → force kill ❓ How to find parent-child process? pstree -p ps -ef --forest 💾 3. Memory Management ❓ How Linux manages memory? 👉 Answer: Physical memory + Swap Virtual memory Paging ❓ What is OOM Killer? 👉 When memory is full → kills high memory process ❓ Check memory usage? free -m vmstat top 📂 4. File System & Storage ❓ Difference between soft link and hard link? Feature Soft Link Hard Link Inode Different Same Cross FS Yes No Broken link Yes No ❓ What is inode? 👉 Stores metadata (not filename) ❓ Disk is full but no files visible. Why? 👉 Possible reasons: Deleted file still used by process lsof | grep deleted ❓ How to extend LVM disk? 👉 Steps: lvextend -L +10G /dev/mapper/vg-lv resize2fs /dev/mapper/vg-lv 🌐 5. Networking (Important for DevOps) ❓ Difference between TCP and UDP? TCP → reliable UDP → fast, no guarantee ❓ How to check open ports? netstat -tulnp ss -tulnp ❓ Troubleshooting: Server not reachable 👉 Steps: ping traceroute telnet curl netstat ❓ What is DNS resolution flow? 👉 Expected: /etc/hosts /etc/resolv.conf DNS server query 🔐 6. Security (Very Important) ❓ What is SELinux? 👉 Security layer controlling access Modes: Enforcing Permissive Disabled ❓ Difference between chmod 777 and 755? 777 → full access (dangerous) 755 → safe for apps ❓ How to secure Linux server? 👉 Expected: Disable root login Use SSH keys Firewall rules Patch updates 🔧 7. Boot Process (High-Level + Deep) ❓ Explain Linux boot process 👉 Flow: BIOS/UEFI GRUB Kernel init/systemd ❓ What is systemd? 👉 Service manager Commands: systemctl start nginx systemctl enable nginx 📦 8. Package Management ❓ Difference between yum and apt? yum → RHEL/CentOS apt → Ubuntu/Debian ❓ How to find which package installed a file? rpm -qf dpkg -S 📜 9. Logs & Troubleshooting ❓ Where are logs stored? /var/log/ ❓ How to check service logs? journalctl -u nginx ❓ System is slow. How to troubleshoot? 👉 Expected structured answer: CPU → top Memory → free Disk → df -h IO → iostat Logs → /var/log 🚀 10. Real-Time DevOps Scenarios (Must Prepare) ❓ Application is down. What will you check? 👉 Answer flow: Service status Logs Port listening Disk full CPU/Memory Network ❓ Disk suddenly filled up. What to do? du -sh /* find / -type f -size +1G ❓ Server rebooted automatically. How to check reason? last -x journalctl -xb dmesg 💡 11. Advanced Questions (For 5+ Years) ❓ What is kernel tuning? /etc/sysctl.conf sysctl -p ❓ What is swap and when it's used? 👉 When RAM is full ❓ What is cron job? crontab -e ❓ Difference between NFS and CIFS? NFS → Linux CIFS → Windows sharing 🎯 Pro Interview Tip (Very Important)

Comments

Popular posts from this blog

Linux interview Questions :

Linux interview questions