From c9e775a44cb316d578827f333531f5101aa29658 Mon Sep 17 00:00:00 2001 From: Minijackson Date: Sun, 27 Sep 2020 10:27:15 +0200 Subject: add 2020-09-22 slides --- 2020-09-22.md | 177 ++++++++++++++++++++++++++++++++++++ bibliography.bib | 25 +++++ res/Fat32_structure.png | Bin 0 -> 120115 bytes res/GParted_1.0_screenshot.png | Bin 0 -> 106008 bytes res/GUID-Partition-Table-Scheme.png | Bin 0 -> 43838 bytes res/fat32.jpg | Bin 0 -> 25837 bytes 6 files changed, 202 insertions(+) create mode 100644 2020-09-22.md create mode 100644 res/Fat32_structure.png create mode 100644 res/GParted_1.0_screenshot.png create mode 100644 res/GUID-Partition-Table-Scheme.png create mode 100644 res/fat32.jpg diff --git a/2020-09-22.md b/2020-09-22.md new file mode 100644 index 0000000..f9f83de --- /dev/null +++ b/2020-09-22.md @@ -0,0 +1,177 @@ +--- +title: WTF is Linux +author: Rémi Nicole +date: 2020-09-22 +slide-level: 2 +aspectratio: 169 + +theme: metropolis +colortheme: owl +beameroption: "show notes on second screen=right" + +toc: true +highlightstyle: breezedark +lang: en-US + +bibliography: ../bibliography.bib +--- + +# Before we get started + +## Requirements for the practical works + +- A GNU/Linux machine +- An SD card reader +- A partner (if you want to) + +## The website + +- In here: +- Please contribute! +- Learn Git: + + +::: notes + +- If you have already used Git before, try to use the send-email approach +- If not, you can use the pull request method + +::: + +## Where were we? + +::: notes + +- Some history of computer science +- Downloaded, configured and build a kernel +- Tried to boot a Linux system, without success + +::: + +# The file system + +## Purpose + +- Organize ones and zeroes into files and directories +- It is therefore a "format" +- We can ask the kernel to represent the files and directories somewhere + +::: notes + +- Storage devices (HDDs, SSDs) just store ones and zeroes +- Representing the files is what is called "mounting" + +::: + +## Storage devices + +- HDDs, SSDs, Flash Memory, everything is different +- We don't care about their differences +- Thank you device drivers + + +## Well-known file systems + +- FAT32 +- ext4 +- NTFS + +::: notes + +- FAT32 works everywhere but + - Fragmentation + - no files bigger than 4 GB + - no advanced features (FAT is quite old) +- ext4 is the de facto Linux file system +- NTFS is the standard Windows file system + +::: + + +## Anatomy of a file system + +- Need to store the content of files +- Need to store metadata + - File names + - File permissions + - Where the content is + - etc. + +--- + +![FAT32 format [@mdpi:fat32]](../res/fat32.jpg){ width=70% } + +--- + +![FAT32 table [@wikimedia:fat32_table]](../res/Fat32_structure.png){ height=70% } + +## Partitions + +- We need a way to store **several** file systems in a single hard drive +- This is quite similar to file systems + - But we store partitions instead of files +- We call the format a "partitioning scheme" + +::: notes + +- Similar in that: + - This is a format + - We need metadata + - And we need space for the partitions + +::: + +## Well-known partitioning scheme + +- MBR +- GPT + +## Anatomy of a partitioning scheme + +![GPT format [@wikimedia:gpt]](../res/GUID-Partition-Table-Scheme.png){ height=80% } + +## Block devices + +- We need a way for the kernel to present us devices +- You can't directly present files + - We may not have a file system in a partition + - The kernel doesn't automatically where to "mount" the files + + +::: notes + +- Philosophy of "everything is a file" +- Look at `/dev` +- `/dev/sda` is the first SCSI disk +- `/dev/sda1` is the first partition in the first SCSI disk +- Theses special files behave a lot like normal files + +::: + +## Mounting + +- To the terminal! + + +::: notes + +- Also talk about mount options + +::: + +## Special file system + +- Common examples: `tmpfs`, `devtmpfs`, `sysfs` & `proc` + +# Init + +## Purpose + +- We need a process launched by the kernel +- A process can launch other processes +- So let's make it 1 + +## Busybox + + +# References diff --git a/bibliography.bib b/bibliography.bib index 1560d34..df9700c 100644 --- a/bibliography.bib +++ b/bibliography.bib @@ -59,3 +59,28 @@ url = "https://www.needpix.com/photo/1276416/boots-shoe-hiking-broken-leather-footwear-obsolete-dirty-vintage", } +@article{ mdpi:fat32, + author = "Wan Yeon Lee, Kyong Hoon Kim, and Heejo Lee", + title = "Extraction of Creation-Time for Recovered Files on Windows FAT32 File System", + journal = "Applied Sciences", + year = 2019, + volume = 9, + issue = 24, + pages = 5522, + doi = "10.3390/app9245522", +} + +@misc{ wikimedia:fat32_table, + title = "Fat32 structure", + year = "2010", + author = "MrDrBob", + url = "https://commons.wikimedia.org/wiki/File:Fat32_structure.svg", +} + +@misc{ wikimedia:gpt, + title = "GUID Partition Table Scheme", + year = "2007", + author = "Kbolino", + url = "https://commons.wikimedia.org/wiki/File:GUID_Partition_Table_Scheme.svg", +} + diff --git a/res/Fat32_structure.png b/res/Fat32_structure.png new file mode 100644 index 0000000..7da07ea Binary files /dev/null and b/res/Fat32_structure.png differ diff --git a/res/GParted_1.0_screenshot.png b/res/GParted_1.0_screenshot.png new file mode 100644 index 0000000..461701f Binary files /dev/null and b/res/GParted_1.0_screenshot.png differ diff --git a/res/GUID-Partition-Table-Scheme.png b/res/GUID-Partition-Table-Scheme.png new file mode 100644 index 0000000..9d3ef40 Binary files /dev/null and b/res/GUID-Partition-Table-Scheme.png differ diff --git a/res/fat32.jpg b/res/fat32.jpg new file mode 100644 index 0000000..0fc3277 Binary files /dev/null and b/res/fat32.jpg differ -- cgit v1.2.3