Skip to content

Latest commit

 

History

History
616 lines (473 loc) · 19.8 KB

00_OVERVIEW.md

File metadata and controls

616 lines (473 loc) · 19.8 KB
title Linux DevOps Complete Guide
description Comprehensive Linux system administration and DevOps guide covering commands, storage, networking, security, performance, and automation
category Linux
difficulty beginner

Linux DevOps Complete Guide - Overview

Welcome

This is a comprehensive Linux system administration and DevOps guide designed for practitioners at all skill levels - from beginners learning basic commands to experienced engineers optimizing production systems. The content is organized into 10 major sections covering the essential knowledge needed for modern Linux system administration and DevOps practices.

What You'll Learn

This guide provides complete coverage of:

  • Command Mastery: Essential Linux commands for daily operations
  • Storage Management: Filesystems, partitioning, LVM, and RAID
  • Network Configuration: Interface management, routing, VLANs, and troubleshooting
  • Security Implementation: Firewalls, SELinux, SSH hardening, and encryption
  • Performance Optimization: CPU, memory, disk I/O, and network performance tuning
  • User Administration: Account management, permissions, and security policies
  • System Administration: Services, packages, boot process, logging, and backups
  • Troubleshooting Techniques: Systematic approaches to common system issues
  • Reference Materials: Quick-lookup tables for codes, permissions, and standards
  • Bash Scripting: Complete automation and scripting guide for DevOps

Target Audience

  • System Administrators: Managing Linux servers in production environments
  • DevOps Engineers: Automating infrastructure and deployment pipelines
  • Site Reliability Engineers (SRE): Ensuring system reliability and performance
  • Cloud Engineers: Working with Linux-based cloud infrastructure
  • Developers: Understanding the Linux environment for application deployment
  • IT Students: Learning Linux system administration fundamentals
  • Beginners: Starting their journey with Linux command line

Prerequisites

  • Access to a Linux system (physical machine, virtual machine, or container)
  • Basic familiarity with terminal/command line interfaces
  • Curiosity and willingness to experiment (in safe environments)
  • For advanced topics: intermediate Linux knowledge and scripting basics

Section Overview

@_OVERVIEW.md)

Focus: Essential Linux commands for file operations, text processing, system information, network operations, process management, and user administration.

Key Topics:

  • File and directory operations (ls, cp, mv, rm, find)
  • Text processing tools (grep, sed, awk, cut, sort)
  • Archive and compression (tar, gzip, zip)
  • Process management (ps, top, kill, systemctl)
  • System information commands (df, free, lscpu, lsblk)
  • Network commands (ip, ss, ping, curl, wget)
  • User management commands (useradd, usermod, passwd)

When to use: Daily Linux operations, command-line productivity, quick system tasks


@_OVERVIEW.md)

Focus: Comprehensive storage management including filesystems, partitioning, LVM, and RAID configurations.

Key Topics:

  • Filesystem types and operations (ext4, xfs, btrfs)
  • Disk partitioning (GPT, MBR, fdisk, gdisk, parted)
  • Logical Volume Management (LVM) - volume groups, logical volumes, snapshots
  • RAID configurations and management (software RAID, mdadm)
  • Storage optimization and troubleshooting

When to use: Setting up new systems, expanding storage, performance optimization, disaster recovery planning


@_OVERVIEW.md)

Focus: Network configuration, routing, VLANs, bonding/teaming, and troubleshooting.

Key Topics:

  • Network fundamentals (TCP/IP, OSI model, protocols)
  • Interface management (ip command, NetworkManager, nmcli)
  • Routing configuration and policy routing
  • VLANs and network segmentation
  • Network bonding and teaming for redundancy
  • Network troubleshooting tools and techniques

When to use: Network configuration, connectivity issues, performance optimization, high availability setups


@_OVERVIEW.md)

Focus: System hardening, firewalls, SELinux, SSH security, encryption, and user security.

Key Topics:

  • Firewall management (firewalld, nftables, iptables)
  • SELinux configuration and troubleshooting
  • SSH hardening and key-based authentication
  • Encryption (LUKS, dm-crypt, GPG)
  • System hardening best practices
  • User and access security

When to use: Securing production systems, compliance requirements, incident response, security audits


@_OVERVIEW.md)

Focus: System performance analysis, monitoring, and optimization for CPU, memory, disk I/O, and network.

Key Topics:

  • CPU performance tuning and monitoring
  • Memory management and optimization
  • Disk I/O analysis and tuning
  • Network performance optimization
  • Monitoring tools and frameworks (top, htop, sar, iostat, vmstat)
  • Performance baselines and capacity planning

When to use: Performance troubleshooting, capacity planning, system optimization, SLA management


@_OVERVIEW.md)

Focus: Complete user and group administration, permissions, and account security.

Key Topics:

  • User account creation and management
  • Group administration
  • File and directory permissions (standard and ACLs)
  • User account files (/etc/passwd, /etc/shadow, /etc/group)
  • Password policies and account security
  • Sudo configuration and privilege escalation

When to use: User provisioning, access control, security policies, compliance requirements


@_OVERVIEW.md)

Focus: Service management, package management, boot process, logging, cron jobs, and system maintenance.

Key Topics:

  • Service management with systemd (systemctl, journalctl)
  • Package management (yum, dnf, apt, zypper)
  • Boot process and GRUB configuration
  • System logging and log management
  • Scheduled tasks (cron, anacron, systemd timers)
  • Backup and recovery strategies
  • Kernel management
  • Containers and virtualization basics
  • Database service administration

When to use: Daily system maintenance, software deployment, system updates, troubleshooting boot issues


@_OVERVIEW.md)

Focus: Systematic troubleshooting approaches for boot, network, performance, security, and service issues.

Key Topics:

  • Boot issue diagnosis and recovery
  • Network connectivity troubleshooting
  • Performance problem investigation
  • Service failure analysis
  • Security incident response
  • Log analysis techniques
  • Troubleshooting methodologies

When to use: System issues, outages, performance degradation, error investigation


@_OVERVIEW.md)

Focus: Quick-reference tables for date formats, exit codes, permissions, partition types, network ports, and signals.

Key Topics:

  • Date format codes for formatting timestamps
  • Shell exit codes and their meanings
  • File permission octal codes
  • GPT and MBR partition type identifiers
  • Common network port numbers
  • Linux signal numbers and names

When to use: Quick lookups during scripting, troubleshooting, configuration, system design


@_OVERVIEW.md)

Focus: Complete shell scripting guide from basics to advanced DevOps patterns, automation, and best practices.

Key Topics:

  • Shell scripting fundamentals (variables, operators, conditionals, loops)
  • Functions and arrays
  • String manipulation and text processing
  • File operations and I/O redirection
  • Process management and signals
  • Debugging techniques
  • Advanced I/O and performance optimization
  • DevOps automation patterns
  • CI/CD integration
  • Security best practices
  • Monitoring and logging scripts
  • Real-world examples and templates

When to use: Automation, deployment scripts, system monitoring, batch operations, DevOps pipelines


Quick Start Paths

For Absolute Beginners

Week 1-2: Start Here

  1. Read @_START_HERE.md) for orientation
  2. Work through @_OVERVIEW.md)
  3. Learn basic text processing: @_OVERVIEW.md)
  4. Practice with QUICK_START_GUIDE.md

Week 3-4: Build Skills

  1. User management basics: @_OVERVIEW.md)
  2. Basic bash scripting: @_OVERVIEW.md)
  3. System information: @_OVERVIEW.md)

For System Administrators

Essential Sections (Priority Order):

  1. @_OVERVIEW.md) - Review all command categories
  2. @_OVERVIEW.md) - User and permission management
  3. @_OVERVIEW.md) - Service and package management
  4. @_OVERVIEW.md) - Security hardening and firewall
  5. @_OVERVIEW.md) - Problem-solving techniques
  6. @_OVERVIEW.md) - Storage management
  7. @_OVERVIEW.md) - Network configuration

For DevOps Engineers

Focus Areas (Automation-First):

  1. @_OVERVIEW.md) - Complete scripting mastery
  2. @_OVERVIEW.md) - Systemd and services
  3. @_OVERVIEW.md) - Performance monitoring and tuning
  4. @_OVERVIEW.md) - Security automation
  5. @_OVERVIEW.md) - Container technologies
  6. @_OVERVIEW.md) - Log parsing and data extraction

For Troubleshooting Focus

When Things Go Wrong:

  1. @_OVERVIEW.md) - Start here for systematic approaches
  2. @_OVERVIEW.md) - Log analysis
  3. @_OVERVIEW.md) - Performance issues
  4. @_OVERVIEW.md) - Network problems
  5. @_OVERVIEW.md) - Quick code lookups

Navigation

Getting Started

  • @_START_HERE.md) - Complete introduction and orientation
  • Quick Start Guide - Fastest path to productivity
  • Complete Index - Alphabetical listing of all files

Browse by Category

  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)
  • @_OVERVIEW.md)

Documentation Standards

This guide follows consistent documentation standards across all sections:

Modern Linux Focus

Target Distributions (2024-2026):

  • Red Hat Enterprise Linux 8, 9, 10
  • Ubuntu 22.04 LTS, 24.04 LTS
  • SUSE Linux Enterprise Server 15
  • Fedora 38+, openSUSE Leap 15+

Deprecation Warnings

Legacy commands and tools are clearly marked with deprecation warnings and modern alternatives are provided. Examples:

  • ifconfig → ip command
  • netstat → ss command
  • service → systemctl
  • network-scripts → NetworkManager/netplan

Content Structure

Each section and topic includes:

  • Purpose: What the topic covers and why it matters
  • Prerequisites: What you should know before starting
  • Examples: Practical, tested examples with explanations
  • Best Practices: Do's and don'ts
  • Troubleshooting: Common issues and solutions
  • Security Considerations: Security implications and hardening
  • Performance Notes: Performance impact and optimization
  • Related Topics: Cross-references to related content

Example Quality Standards

All examples in this guide:

  • Are tested on modern Linux distributions
  • Include expected output where helpful
  • Explain each command option
  • Note potential risks or side effects
  • Provide context for when to use each technique
  • Include both simple and real-world scenarios

Learning Approach

Hands-On Practice

This is a practical guide - every topic includes examples you can run. The best way to learn is:

  1. Read the concepts to understand the "why"
  2. Try the examples in a safe environment
  3. Experiment with variations
  4. Apply to real-world scenarios
  5. Document what you learn

Safe Practice Environments

Before practicing with destructive commands or system changes:

  • Use virtual machines (VirtualBox, VMware, KVM)
  • Use containers (Docker, Podman)
  • Use cloud instances (AWS, Azure, GCP free tiers)
  • Practice in dedicated test environments
  • Create snapshots before major changes

Progressive Learning

Content is structured to build skills progressively:

  • Beginner: Basic concepts and simple examples
  • Intermediate: Multiple options, command combinations
  • Advanced: Complex scenarios, optimization, integration
  • Expert: Edge cases, performance tuning, security hardening

Best Practices Across All Topics

General Principles

DO:

  • Test in non-production environments first
  • Read documentation (man pages, --help)
  • Make backups before destructive operations
  • Use version control for configuration files
  • Document your changes and procedures
  • Implement security best practices
  • Monitor and log system activities
  • Plan for disaster recovery
  • Keep systems updated and patched

DON'T:

  • Run unknown commands with sudo/root
  • Disable security features without understanding implications
  • Skip backups before major changes
  • Ignore error messages and warnings
  • Use deprecated tools in new implementations
  • Hard-code credentials in scripts
  • Give excessive permissions (chmod 777, root access)
  • Make production changes without testing

Security First

Every section in this guide includes security considerations. Key security principles:

  • Principle of least privilege
  • Defense in depth
  • Regular security updates
  • Strong authentication
  • Encryption for sensitive data
  • Audit logging
  • Regular security audits
  • Incident response planning

Performance Awareness

System changes can impact performance. Always consider:

  • Resource utilization (CPU, memory, disk, network)
  • Impact on other services and users
  • Scalability implications
  • Monitoring and alerting
  • Performance baselines
  • Capacity planning

Modern Linux Command Reference

This guide prioritizes modern Linux toolsets used in current distributions:

Recommended Modern Commands

Category Modern Command Replaces Notes
Network Interfaces ip ifconfig Standard in all modern distros
Network Statistics ss netstat Faster, more detailed
Network Config nmcli network-scripts NetworkManager CLI
Service Management systemctl service, chkconfig systemd standard
Logging journalctl tail /var/log/* Centralized systemd logging
Firewall firewall-cmd Direct iptables High-level firewall interface
Time/Date timedatectl Manual /etc/localtime systemd time control
Hostname hostnamectl Manual /etc/hostname systemd hostname control

Package Managers by Distribution

Distribution Primary Package Manager Commands
RHEL/CentOS/Fedora DNF (Dandified YUM) dnf install, dnf update, dnf search
Ubuntu/Debian APT apt install, apt update, apt search
SUSE/openSUSE Zypper zypper install, zypper update, zypper search

Quick Reference - Most Essential Commands

File System Navigation & Operations

pwd                     # Print working directory
ls -lah                 # List files with details, hidden files, human-readable sizes
cd /path/to/directory   # Change directory
cp -r source dest       # Copy recursively
mv source dest          # Move or rename
rm -rf directory        # Remove directory (CAUTION!)
mkdir -p path/to/dir    # Create directory with parents
find /path -name "*.log"  # Find files by pattern

System Information

uname -a                # System information
hostname                # Show hostname
hostnamectl             # System hostname and info (modern)
df -h                   # Disk space usage
free -h                 # Memory usage
lsblk                   # List block devices
lscpu                   # CPU information
uptime                  # System uptime and load

Process & Service Management

ps aux                  # List all processes
top                     # Interactive process monitor
htop                    # Enhanced process monitor (if installed)
systemctl status service  # Check service status
systemctl start service   # Start service
systemctl enable service  # Enable service at boot
journalctl -u service   # View service logs
kill -15 PID            # Gracefully terminate process
pkill process_name      # Kill by process name

Network

ip addr show            # Show IP addresses
ip route show           # Show routing table
ss -tuln                # List listening TCP/UDP ports
ping -c 4 host          # Test connectivity (4 packets)
dig domain.com          # DNS lookup
curl -I https://url     # HTTP request (headers only)
nmcli device status     # NetworkManager device status

User & Permissions

sudo command            # Execute as root
su - username           # Switch user
whoami                  # Current user
id                      # User ID and group info
chmod 755 file          # Change file permissions
chown user:group file   # Change ownership
passwd username         # Change password

Text Processing

grep "pattern" file     # Search for pattern
grep -r "pattern" /path # Recursive search
sed 's/old/new/g' file  # Replace text
awk '{print $1}' file   # Print first column
cat file                # Display file
less file               # View file with pagination
tail -f /var/log/messages  # Follow log file
wc -l file              # Count lines

About This Guide

Coverage and Scope

Total Content:

  • 10 major sections
  • 80+ subsection categories
  • 500+ individual topics
  • 1000+ practical examples
  • Reference tables and quick lookups

Depth:

  • Beginner to expert level content
  • Real-world production scenarios
  • Security and compliance considerations
  • Performance optimization techniques
  • Troubleshooting methodologies

Content Updates

This guide focuses on modern Linux distributions (2024-2026) and is regularly updated to reflect:

  • Current best practices
  • New features in recent distribution releases
  • Security recommendations
  • Deprecated command replacements
  • Modern DevOps patterns

Target Systems:

  • RHEL 8, 9, 10 and derivatives (AlmaLinux, Rocky Linux)
  • Ubuntu 22.04 LTS, 24.04 LTS
  • SUSE Linux Enterprise Server 15+
  • Fedora and openSUSE (latest releases)

How to Use This Guide

As a Learning Resource:

  • Follow the recommended learning paths
  • Work through examples hands-on
  • Practice in safe environments
  • Build skills progressively

As a Reference:

  • Use the INDEX.md for quick topic lookup
  • Bookmark frequently used sections
  • Reference @_OVERVIEW.md) for quick code lookups
  • Search for specific commands or concepts

For Troubleshooting:

  • Start with @_OVERVIEW.md)
  • Cross-reference specific subsections
  • Follow systematic diagnostic approaches
  • Use reference tables for code interpretation

For Automation Projects:

  • Deep dive into @_OVERVIEW.md)
  • Apply security best practices from @_OVERVIEW.md)
  • Reference @_OVERVIEW.md) for scripting constants
  • Learn from real-world examples

Getting Help

Within This Guide

  • Each section has its own overview with detailed navigation
  • Cross-references link related topics
  • Examples include explanations and context
  • Troubleshooting sections address common issues

External Resources

  • Man Pages: man command_name - authoritative Linux documentation
  • Info Pages: info command_name - GNU documentation system
  • Help Options: command --help - quick command reference
  • Distribution Docs: Official documentation for your Linux distribution
  • Community: Forums, IRC, Stack Exchange, Reddit

Command Documentation

man command             # Full manual page
command --help          # Quick help summary
info command            # Info page (GNU commands)
type command            # Show command type
which command           # Show command location
whatis command          # One-line command description

Ready to Begin?

Choose your starting point:

Absolute Beginners: → @_START_HERE.md) Quick Start: → QUICK_START_GUIDE.md Browse Topics: → INDEX.md Jump to Commands: → @_OVERVIEW.md) Jump to Scripting: → @_OVERVIEW.md)


Last Updated: 2026-06-06 Total Sections: 10 Total Files: 500+ Coverage Level: Beginner to Expert Target Distributions: RHEL 8/9/10, Ubuntu 22.04/24.04, SUSE SLES 15+, Fedora 38+