Chapter 17: Supporting Other Operating Systems
Mastering Linux and macOS Administration for IT Professionals
Video Content Prompts
- Demonstrate Linux command-line navigation and file management
- Show package management with APT and DNF across different distributions
- Explore macOS system administration and unique features
- Cover network configuration and troubleshooting in both systems
- Compare cross-platform IT support strategies and best practices
17.1 Linux Features
17.1.1 Shells, Terminals, and Consoles
A CompTIA A+ technician should be capable of supporting diverse operating system environments. While this course focuses primarily on Microsoft Windows, understanding Linux and other systems is essential for comprehensive IT support.
The kernel is the core software component of an operating system that manages hardware and enables communication between software and hardware. A Linux distribution (distro) combines the Linux kernel with a package manager, software repository, and customizable shells, utilities, and applications.
Bootloaders
Before the operating system loads, a bootloader initializes the system and is responsible for loading the kernel into memory. Common Linux bootloaders include:
- GRUB (GRand Unified Bootloader): Most common modern bootloader
- LILO (Linux Loader): Older bootloader still in use
Shells and Terminals:
A shell provides a command-line environment for users to interact with the OS and applications. Popular Linux shells include bash, zsh, and ksh (Korn shell), each offering features like command history, tab completion, and syntax highlighting.
The terminal and shell communicate via a teletype (tty) device, handling text input and output through separate streams:
- stdin (0): Captures keyboard input for processing
- stdout (1): Displays data generated by the shell
- stderr (2): Outputs error information
17.1.2 Command Interface
Linux commands follow a standard format:
- Command: The executable name or path
- Options: Switches that modify behavior (single letters with -, words with --)
- Arguments: Values like file names that the command operates on
- Pipes (|): Redirect output of one command to another
- Semicolon (;): Execute multiple commands sequentially
Help System:
- Use
--helpoption to view command function and syntax - Use
man commandto access detailed manual pages - Pipe help output to
morefor easier reading:ls --help | more
Text Editors:
- nano: Simple editor similar to Windows Notepad
- vi/vim: Advanced editor with command and insert modes
17.1.3 Navigation Commands
In Linux, everything is represented as a file within a unified file system. Unlike Windows drive letters, Linux uses a hierarchical structure starting at the root (/).
Key Navigation Commands
- pwd: Display current working directory
- cd: Change directory
- ls: List directory contents
- cat: Display file contents
Common Usage Examples:
cd /etc- Change to absolute pathcd documents- Change to relative pathcd ..- Move to parent directoryls -la /etc- Detailed listing with hidden filescat file | more- View file with paging
17.1.4 Search Commands
Linux provides powerful search capabilities for both files and file contents.
find Command: Searches for files using criteria
find /home -name "*.txt"- Find all .txt files in /homefind . -size +1M- Find files larger than 1MBfind /var -user apache- Find files owned by apache user
grep Command: Searches file contents using patterns
grep -i "error" /var/log/messages- Case-insensitive searchls -l | grep audit- Filter directory listing
17.1.5 Filesystem Management
Linux uses a hierarchical directory structure starting at root (/). Key management tools include:
- mount: Attach filesystems to directory hierarchy
- /etc/fstab: Configuration file for automatic mounting
- fsck: Check and repair filesystem integrity
Example fstab entry:
/dev/sda1 / ext4 defaults 0 1
17.1.6 File Management Commands
Essential commands for manipulating files and directories:
| Command | Purpose | Example |
|---|---|---|
| cp | Copy files/directories | cp file1.txt file2.txt |
| mv | Move/rename files | mv oldfile.txt newfile.txt |
| rm | Remove files/directories | rm -r directory/ |
| df | Display disk free space | df -h |
| du | Display disk usage | du -sh directory/ |
rm -r with extreme care as Linux commands do not prompt for confirmation and there's no undo.
17.1.7 User Account Management
Linux user management involves several key concepts and commands:
Privilege Escalation Commands:
- su: Switch user accounts, typically to root
- sudo: Execute commands with superuser privileges
User Management Commands:
useradd, usermod, userdel- Add, modify, delete userspasswd- Change passwordsgroupadd, groupmod, groupdel- Manage groups
17.1.8 File Permissions Commands
Linux file permissions control access through three rights: read (r), write (w), and execute (x) for owner, group, and others.
Permission Examples
drwxr-xr-x- Directory with full owner access, read/execute for group and others-rwxr-xr--- File with full owner access, read/execute for group, read for others
Octal Permission Values:
- 4 = Read, 2 = Write, 1 = Execute
- Common combinations: 755 (rwxr-xr-x), 644 (rw-r--r--), 600 (rw-------)
Permission Commands:
chmod 755 file.txt- Change permissions using octalchown user:group file.txt- Change ownershipchgrp group file.txt- Change group ownership
17.2 Package and Network Management
17.2.1 Package Management Commands
Linux software is distributed as source code or pre-compiled packages. Package managers handle installation, updates, and dependencies:
Major Package Managers
- APT (Advanced Packaging Tool): Debian-based systems (.deb packages)
- DNF (Dandified YUM): Red Hat-based systems (.rpm packages)
APT Commands:
apt update- Refresh package informationapt upgrade- Upgrade all packagesapt install package-name- Install new application
DNF Commands:
dnf check-update- Check for available updatesdnf update- Upgrade all packagesdnf install package-name- Install applicationdnf remove package-name- Remove application
17.2.2 Process Monitoring Commands
Every Linux process receives a unique Process ID (PID) for identification and management.
| Command | Purpose | Key Features |
|---|---|---|
| ps | Display process table | Static snapshot of running processes |
| top | Interactive process viewer | Real-time, sortable, can terminate processes |
| systemctl | Control systemd services | Start, stop, enable, disable services |
Top Command Shortcuts:
- M - Sort by memory usage
- P - Sort by CPU usage
- u - Filter by user
- q - Quit
Systemctl Examples:
systemctl start apache2- Start service immediatelysystemctl enable apache2- Enable service at bootsystemctl status apache2- Check service status
17.2.3 Network Management Commands
Modern Linux distributions use various approaches for network configuration, from traditional methods to NetworkManager.
Key Network Commands
- ip: Modern replacement for ifconfig and route
- ping: Test network connectivity
- dig: DNS lookup tool
- curl: Transfer data from servers
- traceroute: Trace network path
IP Command Examples:
ip addr show- Display network interfacesip link set enp0s3 up- Enable network interfaceip route show- Display routing table
Important Configuration Files:
- /etc/hosts: Local hostname to IP mapping
- /etc/resolv.conf: DNS server configuration
17.2.4 Backup and Scheduling Commands
Linux uses the cron scheduling service for automated tasks like backups and maintenance.
Crontab Management:
crontab -l- List scheduled jobscrontab -e- Edit scheduled jobscrontab -r- Remove all scheduled jobs
Crontab Syntax
mm hh dd MM weekday command
- mm: Minutes (0-59)
- hh: Hours (0-23)
- dd: Day of month (1-31)
- MM: Month (1-12)
- weekday: Day of week (0-7)
Example: 15 02 * * 5 /usr/bin/backup.sh
Runs backup script at 2:15 AM every Friday
17.3 macOS Features
17.3.1 Interface Features
macOS provides a distinctive graphical interface with unique elements that differentiate it from Windows systems.
Key Interface Elements
- Menu Bar: Always present at top of screen, displays commands for active window
- Apple Menu: Located left of menu bar, provides system options
- Dock: Bottom-screen launcher similar to Windows taskbar
- Spotlight Search: System-wide search tool (⌘+Space)
Advanced Features:
- Terminal: Command-line environment using Z shell (zsh) by default
- Mission Control: Window and desktop management (F3 key)
- Multiple Displays: Support for multiple desktops with different backgrounds
17.3.2 System Folders and Finder
macOS organizes system resources in specific directories with defined purposes:
| Folder | Purpose |
|---|---|
| /Applications | System-wide applications for all users |
| /Library | System-wide resources and settings |
| /System | Core macOS files (system-managed) |
| /Users | Individual user account folders |
| ~/Library | User-specific application data (hidden) |
Finder: The macOS equivalent of Windows File Explorer, providing file system navigation and management capabilities.
17.3.3 Security and User Management
macOS implements comprehensive security features including user account management and system protection.
Account Types:
- Administrator Account: Created during installation
- Guest User Account: Optional limited-access account
- Apple ID Integration: Links local accounts to Apple services
Security Features
- Privacy & Security: Configure app permissions and analytics
- Keychain: Password management across devices
- FileVault: Full-disk encryption protection
- iCloud Keychain: Sync passwords across Apple devices
17.3.4 iCloud and Continuity
Apple's ecosystem integration provides seamless connectivity between devices and cloud services.
iCloud Services:
- iCloud Drive: File storage and synchronization
- FaceTime: Video/audio calling service
- iMessage: Messaging service across Apple devices
- Mail, Contacts, Calendar: PIM synchronization
17.3.5 App Installation and Management
macOS supports multiple methods for software installation and management.
Installation Methods:
- App Store: Centralized platform for free and paid applications
- Direct Downloads: Vendor websites for non-App Store software
File Types
- .dmg: Disk image files for simple installations
- .pkg: Package files for complex installations
- .app: Application directories in /Applications
Security Considerations:
- Default installation limited to App Store and identified developers
- Antivirus software available (Avira, Avast, Sophos)
- Corporate enrollment in mobile device management systems
17.3.6 System Maintenance and Troubleshooting
macOS includes built-in tools for system maintenance, updates, and problem resolution.
Update Management:
- App Store Updates: Automatic daily checks for app updates
- macOS Updates: System Settings > Software Update
- Rapid Security Response (RSR): Fast security patches
Troubleshooting Tools
- Force Quit: ⌘+Option+Esc to close unresponsive apps
- Recovery Menu: ⌘+R during boot for system recovery
- Time Machine: Comprehensive backup and restore solution
- Disk Utility: Disk verification, repair, and formatting
Time Machine Backup:
- Automatic backups to external drives (APFS or HFS+)
- Hourly (24 hours), daily (past month), weekly (all previous)
- Timeline interface for file restoration
- Local snapshots when backup drive disconnected