Linux files structure Flashcards
(28 cards)
What does -rw-r–r– mean?
- is it directory? (-/d)
- access rights for owner 3
- access rights for memebrs of files group 3
- access rights for everyone else 3
What does second argument (1) mean?
-rw-r–r– 1 root root 1186219 2017-04-03 11:05 kubuntu-leaflet.png
Number of hard links
Why are root args duplicated?
-rw-r–r– 1 root root 1186219 2017-04-03 11:05 kubuntu-leaflet.png
First is owner of file, second is name of group that own the file
LESS command
- Move to the end of file?
- Move to the beggining of file?
- Search for occurence of text?
- Search for the next occurence of previous search?
- See help for all LESS options?
- Shift + g
- g
- /text + enter
- n
- h
Simple copy paste trick?
Double click on a word in terminal, right click to paste it
What is /bin directory?
Contains binaries used by system to boot and run
What is /boot directory?
Contains linux kernel, RAM disk image, boot loader
/boot/vmlinuz is linux kernel
What is /dev directory?
Contains device nodes.
Device is also a file for linux.
What is /home directory?
base directory for each user.
Ordinary users should only have rights to modify files in home dirs
What is /etc directory?
Contains system configuration files.
Also contains shell scripts, that start system services.
/etc/crontab defines automated cron jobs
/etc/fstab defines storage devices with their mount points
/etc/passwd contains list of user accounts
What is /lib directory?
Contains shared library files by core system programs.
Similiar to windows DLL in Windows
What is /lost+found directory?
Contains recovery data in case of failure of some device or formatted partition
What is /media directory?
Contains mount points for removable media, like USB
What is /mnt directory?
In Olders systems contains mount points for removable devices
What is /opt directory?
Contains optional software, e.g. commercial programs
What is /proc directory?
It is virtual file system maintained by kernel. Contains information how kernel sees computer.
What is /root directory?
Home directory for root account
What is /sbin directory?
Contains system binaries, reserved for superuser
What is /tmp directory?
Storage of temporary files
What is /usr directory?
Contains all program files used by regular users
What is /usr/bin directory?
Contains executable programs installed by linux itself
What is /usr/lib directory?
Contains shared libraries for /usr/bin dir
What is /usr/local?
Initialy empty, contains programs for system wide usage
What is /usr/sbin directory?
Contains more system administration programs