LAB-FS-04 - Inside /proc and /sys - The Virtual Windows
Inside /proc and /sys - The Virtual Windows
Read basic live system information from /proc and /sys so you understand that Linux exposes many hardware and kernel details as files.
- Read a few useful files under /proc and /sys.
- Explain why these files can show live system state without being normal disk files.
- This lab is read-only. Do not write to files in /proc or /sys.
Part A: The Field Guide
Linux exposes a lot of live system state through files that are generated on demand.
That means you can often inspect CPU, memory, uptime, or device details with the same reading skills you already learned.
Important Boundary
You can read many files under /proc and /sys safely. Writing to them is a different topic and can change system behavior. Do not do that in this lab.
Useful starter paths
/proc/cpuinfofor processor details/proc/meminfofor memory statistics/proc/uptimefor uptime data/sys/class/netfor network interface information
Part B: The Drill Deck
Terminal required: keep this lab observational.
G Guided Step by step - type exactly this and compare the result >
Exercise G1: Read CPU information
- Run
grep "model name" /proc/cpuinfo - Notice that the information appears as text even though it is live system data
Exercise G2: Read memory information
- Run
head -n 10 /proc/meminfo - Find
MemTotalandMemAvailable - Compare that with the output of
free -hif available
Exercise G3: Read uptime directly
- Run
cat /proc/uptime - Notice that the first number is the uptime in seconds
- Explain why a normal text file on disk would not update like this on every read
S Solo Task described, hints available - figure it out >
Exercise S1: Inspect network interface details
- Run
ls /sys/class/net - Choose one interface such as
lo,eth0, orwlan0 - Read its state with
cat /sys/class/net/<name>/operstate - Read its address with
cat /sys/class/net/<name>/address
Exercise S2: Connect the command to the source
- Run
uptime - Run
cat /proc/uptime - Run
free -h - Run
head -n 5 /proc/meminfo
The point is not that the outputs are identical. The point is that many commands are presenting data that ultimately comes from these pseudo-filesystems.
M Mission Real scenario - no hints, combine multiple skills >
Mission M1: Explain the difference
In your own words, explain:
- why
/procand/sysfeel like files but are not ordinary stored documents - why they are useful when graphical tools are unavailable
- why reading is safe but writing should wait until you understand the consequences
If you can explain that clearly, the mental model is doing its job.