Linux for Beginners: Linux File System and File Commands | Lesson 3

Опубликовано: 14 Май 2026
на канале: DevLog
6
0

▶ Linux for Beginners Playlist:
   • Linux. Begginer course.  

In this lesson you’ll learn how the Linux file system is organized (/, /etc, /var, /home, /tmp, /proc) and practice the essential everyday commands: pwd, cd, ls, tree, touch, mkdir, cp, mv, rm, nano, and file viewing/log tools (cat, less, head, tail, tail -f).
We finish with links: symbolic links vs hard links, and how to tell them apart using ls -l and ls -li.

00:00 Intro
00:54 Main Linux Directories
03:45 What Is /proc
04:50 Absolute vs Relative Paths
07:42 pwd, tree, and cd
09:32 ls -la Explained
10:48 ls -i and Inodes
11:13 touch and mkdir -p
12:32 cp, mv, and rm
15:59 nano vs vim
17:05 cat, less, head, and tail
18:25 tail -f and Logs
19:24 Symbolic Links vs Hard Links
21:54 Wildcards: * and ?
23:36 file Command Explained
24:07 Summary

Commands used in this lesson

Navigation
pwd — show the current directory
cd /etc — go to the /etc directory
cd — go to the home directory
cd - — go back to the previous directory

Viewing directories and file structure
ls -la — list files in detail, including hidden files
ls -l — list files in detailed format
ls -i — show inode numbers
ls -li — list files in detail with inode numbers
tree -L 2 — show the directory tree up to 2 levels deep

Creating files and directories
mkdir -p projects/linux/lesson3 — create a directory path, including missing parent directories
touch notes.txt — create an empty file

Copying, moving, and deleting
cp notes.txt notes-copy.txt — copy a file
cp -r dir1 dir2 — copy a directory recursively
mv notes-copy.txt backup.txt — move or rename a file
rm backup.txt — remove a file

Working with text files
nano notes.txt — open a file in the nano editor
cat notes.txt — print the file content to the terminal
less /etc/services — open a file for scrolling and searching
head notes.txt — show the first lines of a file
tail notes.txt — show the last lines of a file
tail -f /var/log/syslog — follow a file live and show new lines in real time

Links
ln -s notes.txt notes-link.txt — create a symbolic link
ln notes.txt notes-hard.txt — create a hard link

Wildcards and patterns
ls *.txt — list all files that end with .txt
ls file?.log — list files where ? is exactly one character

File type detection
file notes.txt — show the file type

System information from /proc
cat /proc/cpuinfo — show CPU information
cat /proc/meminfo — show memory information

Installing a utility
sudo apt update && sudo apt install tree — update package lists and install the tree utility

#Linux #Ubuntu #DevOps