Find a course
Age level: Adults & professionals (18+)BeginnerTechnology & Programming

Linux Command Line Basics

Navigate, manage files, chain tools and write your first Bash scripts

⏱ 2 h 10 min5 modules · 13 lessons81 practice questionsFinal exam: 20 questions
Included with this course

Your certificate for this course

Finish the 13 lessons (about 2 h 10 min) and pass the 20-question final exam. Your Certificate of Completion is ready the moment you pass.

  • Your name and this course titlePrinted in classic diploma typography
  • Grade: Pass, Merit or DistinctionOn the gold seal, with your final score
  • Unique ID and QR codeAnyone can verify it in seconds
  • Score report PDFModule-by-module results and exam score
  1. Lessons13 lessons
  2. Final exam20 questions · 70% to pass
  3. CertificatePDF + score report

What you will learn

  • Explain the roles of the terminal, the shell and the kernel, and read a shell prompt
  • Navigate the Linux file system with absolute and relative paths and find key system directories
  • Create, copy, move, rename and delete files and directories safely, including with wildcards
  • Read, search and locate files with less, tail, grep and find, and archive them with tar
  • Combine commands with redirection and pipes, and analyze text with sort, uniq, cut, sed and awk
  • Read and change file permissions and ownership with chmod and chown, using octal and symbolic modes
  • Use sudo and a package manager, and inspect and control processes and services
  • Write, run and schedule Bash scripts that use variables, arguments, exit codes, conditions and loops

About this course

Most of the world's servers, cloud machines and network devices run Linux, and most of them are managed by typing commands, not clicking buttons. The command line can look intimidating, a blinking cursor with no menus, but it follows a small set of consistent rules. Once you know them, you can do in one line what takes hundreds of clicks, repeat it on a thousand files, and automate it to run every night.

This free course takes you from your first prompt to your first working script in one sitting. You'll learn what the terminal, shell and kernel are, how every command is built from a name, options and arguments, and how to get help without leaving the terminal. You'll move around the file system with absolute and relative paths and learn what lives in /etc, /var and /home.

Next you'll create, copy, move and delete files safely, use wildcards, read and search huge log files with less, tail, grep and find, edit configuration files in nano (and escape from vim), and pack files with tar.

Then come the power tools: redirection, pipes, and text processing with sort, uniq, cut, sed and awk, ending with a real log analysis. You'll read and set file permissions with chmod and octal numbers, use sudo responsibly, install software with a package manager, and find and stop runaway processes and services. Finally you'll write Bash scripts with variables, arguments, if tests and loops, and schedule them with cron.

The course is for beginners: students, aspiring developers and system administrators, data analysts, and anyone who has been told to "just SSH into the server". Every lesson mixes short explanations with real command examples, scenarios and quick checks, and you can earn a free certificate by passing the final exam.

Syllabus

  1. Getting Started in the Terminal

    Learn what the terminal and the shell are, how every command is built, and how to move around the Linux file system with confidence.

    1. What the Command Line Is and Why It Matters9 min
    2. Anatomy of a Command and Getting Help10 min
    3. Navigating the File System11 min
  2. Working with Files

    Create, copy, move and delete files safely, use wildcards to act on many files at once, read and search text, and edit and archive files.

    1. Creating, Copying, Moving and Deleting11 min
    2. Viewing and Searching Files12 min
    3. Editing Text Files and Archiving10 min
  3. Redirection, Pipes and Text Processing

    Send output to files, connect small tools into pipelines, and use sort, uniq, cut, tr, sed and awk to answer real questions about data and logs.

    1. Redirection and Pipes11 min
    2. Text Processing: sort, uniq, cut, sed and awk12 min
  4. Permissions, Users and Processes

    Read and change file permissions, use sudo and package managers responsibly, and inspect, stop and manage running processes and services.

    1. File Permissions and Ownership12 min
    2. Users, sudo and Installing Software10 min
    3. Processes, Jobs and Services11 min
  5. Customizing the Shell and Writing Scripts

    Use variables, quoting, aliases and startup files, then write, run and schedule your first Bash scripts with arguments, conditions and loops.

    1. Variables, Quoting and Aliases11 min
    2. Your First Shell Script13 min
  6. Final exam and certificate

    20 questions drawn from a pool of 35. Score 70% or more to pass; retakes get a fresh set of questions.

Try a sample question

Bash and the terminal are two names for the same program.

True or false?

Show the answer

Answer: False

The terminal is the window; Bash is the shell program running inside it. You can run zsh or fish in the same terminal, or run Bash inside many different terminal apps. Keeping the two apart helps when you read documentation that talks about "shell features" versus "terminal settings".

Terminal
The window or program that displays text and sends your keystrokes to the shell.
Shell
The program that reads commands and asks the operating system to run them; Bash and zsh are common shells.
Kernel
The core of the operating system that manages hardware, memory, processes and files.
Bash
The Bourne Again SHell, the default shell on most Linux distributions.
Prompt
The text the shell prints when it is ready for a command, usually showing user, host and current directory.
Option
A flag starting with - or -- that changes how a command behaves, such as -l or --all.

Frequently asked questions

Do I need to install Linux to take this course?

No. The lessons and checks run in your browser. To practice the commands yourself, you can use Windows Subsystem for Linux on Windows, the Terminal app on macOS (zsh behaves almost the same as Bash for these basics), a virtual machine, or a free browser-based cloud shell.

Which Linux distribution should I learn on?

Any mainstream one. The commands in this course work the same on Ubuntu, Debian, Fedora, Rocky Linux and most others. The main difference you will notice is the package manager: apt on Debian and Ubuntu, dnf on Fedora and Red Hat family systems.

What is the difference between Bash and the terminal?

The terminal is the window that shows text. Bash is the shell, the program inside it that reads and runs your commands. You can run Bash in many terminal apps, and you can run other shells such as zsh in the same terminal.

How do I exit vim?

Press Esc to make sure you are in normal mode, then type :q! and press Enter to quit without saving, or :wq to save and quit. If you prefer a simpler editor, use nano, which shows its shortcuts at the bottom of the screen.

Is rm -rf really that dangerous?

Yes. It deletes directories and their contents recursively without asking and without a trash folder. Always check the exact path with ls first, use Tab completion to avoid typos, and be extra careful with variables and spaces in the path.

What does chmod 755 mean?

Each digit is a sum of read (4), write (2) and execute (1) for the owner, the group and everyone else. 755 means the owner can read, write and execute, while the group and others can read and execute but not change the file.

Is this course enough to become a Linux administrator?

It covers the command line foundation every admin uses daily. Administration also involves networking, storage, security hardening, monitoring and automation tools, which build on these basics. It is a solid first step toward entry-level Linux certifications.

Sources and further reading

Related courses

Adults & professionalsBeginner

IT Support Fundamentals

Help desk skills, troubleshooting, hardware, networks and account security

Technology & Programming
2 h 20 min12 lessonsCertificate
Adults & professionalsBeginner

Computer Basics

Hardware, files, the internet, email and staying safe, from zero

Technology & Programming
2 h12 lessonsCertificate
Adults & professionalsBeginner

JavaScript for Beginners

Variables, functions, arrays, objects, the DOM and async code

Technology & Programming
2 h 10 min12 lessonsCertificate
Adults & professionalsBeginner

Computer Networking Basics

IP addresses, subnets, TCP/IP, DNS, Wi-Fi and troubleshooting explained

Technology & Programming
2 h 15 min13 lessonsCertificate
Adults & professionalsBeginner

Excel Fundamentals

Formulas, lookups, tables, PivotTables and charts from zero to confident

Technology & Programming
2 h 10 min12 lessonsCertificate
Adults & professionalsBeginner

Python for Beginners

Write real programs with variables, loops, lists, dictionaries and functions

Technology & Programming
2 h 15 min12 lessonsCertificate