Introduction:
File systems are the backbone of data organization in modern computing, serving as the crucial interface between users, operating systems, and storage devices. This write-up explores the fundamentals of file systems, with a particular focus on Linux. We'll begin by comparing file system structures across popular operating systems like Windows and Linux, highlighting their organizational principles. Our journey will then narrow to the Linux file system, examining its standardized directory structure and the Filesystem Hierarchy Standard (FHS). We'll introduce common file system types, emphasizing the EXT file system prevalent in Linux environments. While touching on concepts like inodes and metadata, we'll keep our discussion at an introductory level, suitable for those new to system administration and cybersecurity.
By the end of this write-up, you'll have a solid grasp of file system basics, their importance in data management, and how they differ across operating systems. This foundation will prepare you for hands-on exploration of the Linux file system, setting the stage for more advanced topics in computing and cybersecurity.
Lab Questions and Answers: 1.1 Core Concepts
1. A file system is the way the OS organizes files, folders, _______, and peripherals.
Answer: storage
2. The highest level of directory in a Linux file system is _____.
Answer: root
3. The Linux ____ file system is the most common and the default file system in most cases.
Answer: EXT
4. Linux uses ____ to store file information and to point to the file's location in storage.
Answer: index nodes
Lab Questions and Answers: 1.2 Guided Exercise
1. Where does Linux store critical configuration files?
Answer: /etc
2. The ___ directory is used to mount other devices.
Answer: /mnt
3. Where are the man pages kept in Linux?
Answer: /usr/share
4. How large is the xvda hard disk? (In GB)
Answer: 30
Hint: Use this command: sudo fdisk -l | grep xvda
Lab Questions and Answers: 1.3 Challenge Exercise
1. There is a file called flag in the directory where Linux keeps device files. What is the flag?
Answer: hammer
Hint: Use this command: cat /dev/flag
2. There is a file called flag in the directory where Linux keeps administrative tools (tools that require elevated privileges). What is the flag?
Answer: straw
Hint: Use this command: cat /usr/sbin/flag
3. There is a file called flag in the directory where Linux keeps common commands. What is the flag?
Answer: zipper
Hint: Use this command: cat /usr/bin/flag
4. There is a file called flag in the directory where Linux keeps variable data. What is the flag?
Answer: dice
Hint: Use this command: cat /var/flag
Conclusion
In this lab, we explored the Linux file system and practiced navigating through key directories. We learned about the Filesystem Hierarchy Standard (FHS) and how it organizes files and directories in a Linux system. We used various commands such as cd, ls, tree, and cat to navigate and view the contents of different directories. We also learned about the different types of files and directories, including device files, administrative tools, common commands, and variable data.
Through this lab, we demonstrated our understanding of the Linux file system by retrieving flags from key directories. We successfully retrieved flags from the /dev, /usr/sbin, /usr/bin, and /var directories, showcasing our knowledge of the Linux file system hierarchy. This lab provided a solid foundation for understanding the Linux file system and its organization. We gained hands-on experience with navigating and viewing the contents of different directories, which is essential for working with Linux systems.