The shell is your primary interface to Linux. Master it, and you unlock the true power of the system.
Understanding the Shell
The shell is a command-line interpreter that reads your commands and executes them. The most common shell is Bash (Bourne Again Shell).
Essential Commands
Navigation
pwd # Print working directory
cd /path # Change directory
ls -la # List files with details
File Operations
mkdir dirname # Create directory
touch filename # Create empty file
cp source dest # Copy file
mv source dest # Move/rename file
rm filename # Remove file (careful!)
Viewing Files
cat filename # Display entire file
less filename # View file page by page
head filename # First 10 lines
tail filename # Last 10 lines
Paths and Permissions
Understanding absolute vs relative paths is crucial:
/home/user/file- absolute path./file- relative to current directory../file- relative to parent directory
File permissions use a three-tier system: owner, group, and others. Each can have read (r), write (w), and execute (x) permissions.
Practice
Try navigating your system:
cd ~
ls -la
cd /etc
ls | head -5
The shell is your gateway to everything. Master these basics before moving on!