> KS3CURED

Linux for Dummies
101

// Table of Contents
// 01 — Foundations

What is Linux and Why Should You Care?

// Why Linux Matters for Cybersecurity

// Distros Explained

A distribution (distro) is Linux + a package manager + a set of pre-installed software. Think of Linux as an engine — a distro is the car built around it.

DistroGood For
UbuntuBeginners. Large community, easy to search for help, stable.
Kali LinuxPenetration testing. Pre-loaded with 600+ security tools. NOT a daily driver.
Arch LinuxLearning by doing. You build it yourself. Intense. (My daily driver.)
DebianRock-solid. Ubuntu is based on it. Great for servers.
Parrot OSSecurity + privacy. Lighter than Kali, good alternative.
💡 Start with Ubuntu if you're brand new. You'll learn the same core skills and won't spend 3 hours debugging your bootloader before you've even opened a terminal.
// 02 — Getting Started

Your First Terminal Session

Opening a terminal for the first time and seeing a blinking cursor is either exciting or terrifying depending on your mindset. Let's demystify what you're looking at.

// How to Open a Terminal

// What the Prompt Means

ky@thinkpad:~$ # This is your command prompt # ky = your username # thinkpad = your machine's hostname (its "name") # ~ = current directory (~ means home folder) # $ = regular user (# means root/admin)

// Terminal vs Shell vs Bash

TermWhat it actually is
TerminalThe window/emulator you're typing in. Just the visual container.
ShellThe program interpreting your commands. The brain.
BashOne specific shell. "Bourne Again Shell." The default on most Linux distros.

// How to Not Panic

// Try It Yourself — Practice Terminal

Type a command below and hit Enter. Try: whoami, pwd, ls, date, echo hello, clear, help

goofygoober@thinkpad: ~
goofygoober@thinkpad:~$ 
// 03 — Navigation

Navigation Commands

The filesystem is just folders inside folders. Learning to move around it fast is 90% of feeling confident in a terminal.

// pwd — Print Working Directory

ky@linux:~$ pwd /home/ky

// ls — List Directory Contents

ky@linux:~$ ls Desktop Documents Downloads projects scripts ky@linux:~$ ls -la # long format + hidden files drwxr-xr-x 8 ky ky 4096 May 1 14:23 . -rw-r--r-- 1 ky ky 220 Apr 28 09:01 .bash_profile drwxr-xr-x 2 ky ky 4096 May 1 14:20 Desktop

// cd — Change Directory

ky@linux:~$ cd Documents # go into Documents ky@linux:~/Documents$ cd .. # go up one level ky@linux:~$ cd ~ # go to home dir, always ky@linux:~$ cd /etc/nginx # absolute path (starts with /) ky@linux:/etc/nginx$ cd ../ssh # relative path (no leading /)

// Absolute vs Relative Paths

TypeStarts withExample
Absolute//home/ky/projects — full path from root
Relativeletter or .projects/notes — from where you currently are
SESSION ALERT — after section 03

Getting lost navigating the filesystem? Mixing up absolute and relative paths? This is the #1 thing I help beginners fix in their first 1:1 session. You'll go from confused to confident in 15 minutes.

→ Book a Linux Session
// 04 — Files

Working with Files and Directories

Creating, copying, moving, and deleting files. This is the muscle memory of Linux. Practice these until they're automatic.

// Creating

ky@linux:~$ mkdir my_project # make directory ky@linux:~$ mkdir -p a/b/c # make nested dirs ky@linux:~$ touch notes.txt # create empty file ky@linux:~$ touch file1.txt file2.txt # create multiple

// Copying and Moving

ky@linux:~$ cp notes.txt backup.txt # copy file ky@linux:~$ cp -r my_project/ backup/ # copy directory (need -r) ky@linux:~$ mv notes.txt Documents/ # move file ky@linux:~$ mv notes.txt renamed.txt # rename file

// Deleting

ky@linux:~$ rm notes.txt # delete file ky@linux:~$ rmdir empty_folder # delete empty dir ky@linux:~$ rm -rf my_project/ # delete dir + all contents
⚠ WARNING: rm -rf has no trash, no undo, no mercy. Deleted = gone. Always double-check your path before running this.
// 05 — Reading Files

Reading and Editing Files

Log files, config files, text files. In cybersecurity, you spend a lot of time reading files that tell you what happened on a system. Here's your toolkit.

// cat — Print Entire File

ky@linux:~$ cat /etc/hosts 127.0.0.1 localhost 127.0.1.1 thinkpad

// less and more — Paged Reading

ky@linux:~$ less /var/log/syslog # scroll with arrows, q to quit ky@linux:~$ more bigfile.txt # spacebar to advance

// head and tail — Specific Lines

ky@linux:~$ head -20 access.log # first 20 lines ky@linux:~$ tail -50 error.log # last 50 lines ky@linux:~$ tail -f /var/log/auth.log # live follow (Ctrl+C to stop)
💡 tail -f is one of the most useful commands in security work. Watch live authentication attempts and system events in real time.

// nano — Simple Text Editor

ky@linux:~$ nano notes.txt # Ctrl+O → save Ctrl+X → exit Ctrl+W → search
// 07 — Searching

Finding Things

Searching through filesystems and file contents is a core security skill. Incident response, log analysis, and hunting for misconfigs all rely on finding things fast.

// find — Locate Files

ky@linux:~$ find /etc -name "*.conf" # find .conf files ky@linux:~$ find /home -type f -perm 777 # world-writable files ky@linux:~$ find . -mtime -1 # modified in last day

// grep — Search Inside Files

ky@linux:~$ grep "failed" /var/log/auth.log # failed logins ky@linux:~$ grep -i "error" app.log # case-insensitive ky@linux:~$ grep -r "password" /etc/ # recursive ky@linux:~$ grep -n "root" /etc/passwd # show line numbers

// Pipes — Chain Commands Together

# The | symbol pipes output from one command into the next ky@linux:~$ cat /var/log/auth.log | grep "Failed" | tail -20 # Last 20 failed authentication attempts ky@linux:~$ ps aux | grep "nginx" # Check if nginx is running
💡 Mastering grep + pipes = reading logs like a pro. In security, this is how you hunt for indicators of compromise.