From memorizing commands to understanding intent: inspect the system, navigate files, search intelligently, mount storage, and control system state safely.
This version removes the inserted screenshot figures and presents the extracted Linux command information systematically. The learning target is to understand command intent: what question you are asking, what object you are acting on, and what risk the command carries.
1) System information: learn what machine/system you are on
2) Shutdown/reboot: control system state
3) Files/directories: move around and inspect the filesystem
4) Search: find files, executables, packages, and commands
5) Mounting: attach storage or remote shares into the directory tree
Linux treats almost everything as a file or path. Most commands answer one of these questions:
β’ Where am I? β pwd
β’ What is here? β ls
β’ Where is something? β find / locate / which / whereis
β’ What is this system? β uname / lspci / lsusb / /proc
β’ How is storage attached? β mount / umount / /proc/mounts
β’ How do I safely stop/restart? β shutdown / reboot
| Question | Command | Intuition |
|---|---|---|
| CPU architecture? | uname -m / arch | Is it x86_64, arm64, etc.? Important for binaries and libraries. |
| Kernel version? | uname -r / cat /proc/version | Useful for drivers, compatibility, and support tickets. |
| Hardware inventory? | dmidecode -q | BIOS/DMI/SMBIOS hardware info. |
| CPU details? | cat /proc/cpuinfo | CPU model, cores, flags. |
| Memory usage? | cat /proc/meminfo | RAM totals and usage details. |
| Swap usage? | cat /proc/swaps | Which swap devices/files are active. |
| Network stats? | cat /proc/net/dev | Network interfaces and RX/TX counters. |
| Mounted filesystems? | cat /proc/mounts | What storage/filesystems are currently attached. |
| PCI/USB devices? | lspci -tv / lsusb -tv | Tree view of PCI/USB hardware. |
| Date/time? | date / cal 2007 | Show current date or a calendar. |
Before installing a PDK, running a simulator, or debugging tool issues, first learn the machine: architecture, kernel, RAM, devices, mounts, and date/time.
date 041217002007.00 and clock -w change system/BIOS time. Use only when you really intend to change time.
Use this as the visual memory anchor for /proc, uname, hardware, and date commands.
| Intent | Command | Notes |
|---|---|---|
| Shutdown now | shutdown -h now | Safe shutdown with halt/poweroff behavior. |
| Shutdown via init level | init 0 / telinit 0 | Older/sysvinit style; less common on modern systems. |
| Schedule shutdown | shutdown -h hours:minutes & | Schedule shutdown in background. |
| Cancel scheduled shutdown | shutdown -c | Cancels pending shutdown. |
| Reboot now | shutdown -r now / reboot | Restart system. |
| Logout shell/session | logout | Exit current login shell, not power off system. |
Do not run shutdown/reboot commands on shared company Linux servers unless you are authorized. For your own workstation, prefer normal GUI logout/shutdown unless you are practicing.
Top half shows system state commands; bottom half shows navigation commands.
| Intent | Command | Intuition |
|---|---|---|
| Go to /home | cd /home | Absolute path starts from root /. |
| Go up one level | cd .. | Parent directory. |
| Go up two levels | cd ../.. | Two parent levels. |
| Go home | cd | Your own home directory. |
| Go to another user home | cd ~user1 | User1βs home directory if accessible. |
| Return to previous directory | cd - | Very useful when jumping between two folders. |
| Print current path | pwd | Always use before destructive operations. |
| List files | ls | Basic directory listing. |
| Classify file types | ls -F | Adds markers like / for dirs, * for executable. |
| Detailed list | ls -l | Permissions, owner, size, modified time. |
| Show hidden files | ls -a | Shows dotfiles like .bashrc. |
| Pattern match | ls *[0-9]* | Shows names containing digits. |
| Tree view | tree / lstree | Directory tree structure. |
| Create directory | mkdir dir1 | Make new folder. |
pwd
ls -la
cd <target>
cd -
This is enough for 70% of navigation/debugging work.
Use this visual to memorize cd, pwd, ls, tree, and mkdir.
| Intent | Command | Meaning |
|---|---|---|
| Find by name from root | find / -name file1 | Search entire filesystem for file1. |
| Find by owner | find / -user user1 | Find files/directories owned by user1. |
| Find *.bin under /home/user1 | find /home/user1 -name *.bin | Name pattern search. |
| Find unused executables in /usr/bin | find /usr/bin -type f -atime +100 | Files not accessed for >100 days. |
| Find modified recently | find /usr/bin -type f -mtime -10 | Files modified in last 10 days. |
| Find rpm and chmod | find / -name *.rpm -exec chmod 755 '{}' \; | Find then execute chmod on each result. |
| Stay on same filesystem | find / -xdev -name *.rpm | Avoid crossing into mounted/removable filesystems. |
| Fast locate database | locate *.ps | Fast search from indexed database. |
| Find command/documentation | whereis halt | Binary/source/man location. |
| Find executable path | which halt | Executable used in PATH. |
Be careful with find / -exec chmod ... because it can change many files. First test with:
find /path -name pattern -print
Then add -exec only after confirming results.
Use this to memorize find conditions: name, user, type, access time, modified time, exec, xdev.
Linux does not use C: / D: like Windows. A disk/USB/ISO/network share becomes visible only after it is attached to a directory called a mount point, such as /mnt/usbdisk.
| Intent | Command | Notes |
|---|---|---|
| Mount disk partition | mount /dev/hda2 /mnt/hda2 | Attach device to directory. |
| Unmount disk | umount /dev/hda2 | Detach safely. |
| Force users off mount | fuser -km /mnt/hda2 | Kills processes using mount; dangerous. |
| Unmount without mtab update | umount -n /mnt/hda2 | Avoid writing mtab. |
| Mount ISO image | mount -o loop file.iso /mnt/cdrom | Treat ISO file like a block device. |
| Mount FAT32 | mount -t vfat /dev/hda5 /mnt/hda5 | Windows FAT32 filesystem. |
| Mount USB disk | mount /dev/sda1 /mnt/usbdisk | USB usually appears as /dev/sdX. |
| Mount Windows share | mount -t smbfs -o username=user,password=pass //WinClient/share /mnt/share | Older smbfs syntax; modern Linux often uses cifs. |
Always unmount before removing USB/disk:
umount /mnt/usbdisk
If βdevice is busyβ, run:
lsof +f -- /mnt/usbdisk
or
fuser -v /mnt/usbdisk
Use this to memorize device β mount point β filesystem type.
Click each card to reveal the answer. All original flashcards are preserved.
All original glossary terms are preserved below.
Top of the Linux filesystem tree.
Path starting from /, e.g. /home/user.
Path relative to current directory, e.g. ../dir.
File beginning with a dot, e.g. .bashrc.
Directory where a filesystem is attached.
Path under /dev representing hardware or virtual device, e.g. /dev/sda1.
Virtual filesystem exposing kernel/system information.
Firmware-provided hardware information used by dmidecode.
Access time / modification time used by find.
Shell variable listing directories searched for executables.
First ask what you want to know or change: system information, directory location, file search, device mounting, or system state. Then choose the command family and apply the safest command first.