Get AI summaries of any video or article — Sign up free
60 Linux Commands you NEED to know (in 10 minutes) thumbnail

60 Linux Commands you NEED to know (in 10 minutes)

NetworkChuck·
5 min read

Based on NetworkChuck's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.

TL;DR

SSH is the gateway command for remote Linux access, requiring a username and a target IP/hostname, followed by fingerprint acceptance and password authentication.

Briefing

Linux access starts with SSH: connect using a username and an IP/hostname, accept host fingerprints, then authenticate with a password. Once inside, basic navigation and file handling form the backbone of day-to-day work—ls (with -l for details and -a for hidden files), pwd to confirm the current directory, and cd to move around (including cd .. for one level up and cd with no argument to jump to home). Creating and editing files is equally essential: touch creates files quickly, echo can append or write text, nano offers a beginner-friendly editor (save via Ctrl+X, then Y/Enter), and vim-style editing is referenced through the vi/nano workflow of insert mode and “write and quit” (Escape, :wq). For viewing content, cat prints immediately, while less scrolls page-by-page; head and tail show the beginning or end of a file. When comparing or diagnosing differences, cmp checks whether two files match, and diff pinpoints exactly what changed.

The toolkit expands into searching, permissions, and system introspection. mk dir creates directories, cp copies, mv moves/renames, rm deletes files, and rm -r removes directories recursively when they’re not empty. Symbolic links are created with ln -s (soft links), and terminal clutter can be cleared with clear. For identity and access control, whoami reveals the current user; user management uses adduser (with sudo/pseudo for privileges) and su to switch users, while passwd changes passwords. The transcript also highlights “learn-as-you-go” documentation: man for full references, and whatis/which to find commands and their locations.

Downloading and compressing files are covered with practical commands: wget isn’t mentioned, but curl fetches from a URL into a file, zip compresses, unzip extracts, and grep/fine are used for searching (with find described as locating files by name patterns, including hidden, empty, or executable files). Executable permissions are handled via chmod +x, and ownership changes via chown. Network troubleshooting rounds out the middle and late sections: ip addr (or ifconfig-style alternatives) shows IPs per interface; resolv.conf and resolvectl status are used to inspect DNS; ping tests reachability with options like -c for count; traceroute reveals the path and latency; netstat (with -tulpn) and the newer ss provide port/process visibility. Firewall management is simplified with UFW: allow port 80, check rules with ufw status, then enable it.

System health and process control come next. uname -a and neofetch provide quick system summaries; cal shows a calendar; free reports memory and swap; df -h shows disk usage; ps aux lists processes; top and htop monitor resource-heavy tasks. To stop programs, kill uses a PID (often found via ps/grep), while pkill stops by process name. Service management uses systemctl under System D (or service otherwise) to stop/start/restart/status daemons like Apache. The session ends with history to review prior commands, plus reboot and shutdown (including shutdown now via -h now). The overall takeaway is a fast, practical command ladder—from logging in, to files, to permissions, to networking, to running processes—so a Linux user can operate and troubleshoot without getting stuck.

Cornell Notes

The core idea is a rapid “command ladder” for Linux: start by getting access with SSH, then move through navigation, file creation/editing, viewing, and comparison. From there, the essentials expand to permissions (chmod, chown), documentation (man/whatis/which), and searching (find/grep-style workflows). Networking commands cover IP/DNS checks, reachability (ping), path tracing (traceroute), and port inspection (netstat/ss), with firewall control via UFW. Finally, system monitoring and control—uname/neofetch, free/df, ps/top/htop, kill/pkill, and systemctl—turn basic command knowledge into real operational troubleshooting.

Why is SSH the first command worth knowing, and what information does it require?

SSH is the entry point for remote Linux work. The connection format uses a username, an @ symbol, and the target server’s IP/hostname (e.g., copying the machine’s IP and placing it after user@). After connecting, host fingerprints must be accepted, then authentication happens via a password.

How do ls, pwd, and cd work together to keep you oriented in the filesystem?

ls lists what’s in the current directory; -l adds a detailed “long” listing and -a reveals hidden entries. pwd prints the absolute path of the current working directory. cd changes directories: cd <path> moves to a specific location, cd .. goes up one level, and cd with no argument jumps to home.

What’s the practical difference between cat, less, head, and tail?

cat outputs the entire file immediately, which can be unwieldy for large content. less shows content one page at a time, making it easier to scroll. head displays the beginning of a file, while tail shows the end—useful for logs and quick inspection without dumping everything.

When should you use cmp vs diff?

cmp determines whether two files are identical, but it doesn’t provide a full breakdown of changes. diff goes further by showing exactly what differs between the two files, making it better for understanding modifications.

How do UFW rules relate to port access, and what are the basic steps shown?

UFW sits on top of IP tables to simplify firewall management. The workflow shown is: allow a port (e.g., ufw allow 80), check current rules with ufw status, then enable the firewall with ufw enable and re-check status. This sequence ensures the rule exists and the firewall is active.

How do kill and pkill differ for stopping processes?

kill requires a process ID (PID), so you typically find it first using ps and then kill -9 <PID> to force termination. pkill is name-based, so you can stop a process by its name without manually looking up the PID (the transcript uses pkill with a -f option).

Review Questions

  1. Which command sequence would you use to confirm your current directory, list hidden files, and then move back one level?
  2. If two files differ, which command helps you pinpoint the exact lines that changed, and why is it better than cmp for that task?
  3. What combination of commands would you use to (1) check open ports and (2) verify firewall rules on a Linux machine?

Key Points

  1. 1

    SSH is the gateway command for remote Linux access, requiring a username and a target IP/hostname, followed by fingerprint acceptance and password authentication.

  2. 2

    Filesystem navigation relies on ls (with -l and -a), pwd for location, and cd for moving—using cd .. and cd for quick jumps.

  3. 3

    File workflows include touch for creation, echo for quick text output, nano for editing (Ctrl+X then Y/Enter), and cat/less/head/tail for viewing.

  4. 4

    Copy/move/delete operations follow a consistent pattern: cp and mv for file handling, rm for files, and rm -r for non-empty directories.

  5. 5

    Permissions and ownership are controlled with chmod +x (make executable) and chown (change owner), which are prerequisites for many admin tasks.

  6. 6

    Network troubleshooting uses ip addr for addressing, resolvectl/resolv.conf for DNS, ping and traceroute for reachability and path, and netstat/ss for port visibility.

  7. 7

    Operational control uses ps/top/htop to observe, kill/pkill to stop, and systemctl (System D) or service to manage daemons like Apache.

Highlights

SSH is presented as the non-negotiable first step: without remote access, most Linux work can’t begin.
less, head, and tail provide safer file inspection than cat when content is large or log-like.
UFW is framed as the simpler firewall layer over IP tables: allow a port, check status, then enable and re-check.
systemctl is positioned as the modern service manager under System D, with stop/start/status/restart patterns for daemons.
The command set forms an end-to-end workflow: login → navigate/edit → search/permissions → network checks → monitor/kill/manage services.

Topics

  • SSH Access
  • File Management
  • Text Viewing
  • Networking Troubleshooting
  • Process and Service Control

Mentioned

  • SSH
  • UFW
  • IP
  • DNS
  • PID
  • System D