Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commit389b68f2386eaf35550dee5e63e5d88860828f58 (patch)
Author
 Kamen Mladenov <kamen@syndamia.com>
2023-01-22 15:56:53 +0000
Committer
 Kamen Mladenov <kamen@syndamia.com>
2023-01-22 15:56:53 +0000
Files34b5bd6194c309184c5ab7b2549c11ac87392704
syndamia.com-389b68f2386eaf35550dee5e63e5d88860828f58.tar
syndamia.com-389b68f2386eaf35550dee5e63e5d88860828f58.tar.gz
syndamia.com-389b68f2386eaf35550dee5e63e5d88860828f58.zip
Parent17407b5e8cbef35bcc1e0389e344107724813ebe (diff)
Parent6eb7a8fff01c6814253a0e738efb53734d297be9 (diff)
Merge branch 'talks/linuxgraphy-by-strabo' into 'master'
[talks/lbs] Updated slide text to not be so close to edge and doubled... See merge request Syndamia/syndamiadotcom!5
10 files changed, 910 insertions, 39 deletions
-rw-r--r--awk-edits/Flags.awk2
-rw-r--r--awk-edits/Pagenav.awk2
-rw-r--r--awk-edits/Presentation.awk86
-rw-r--r--src/img/bg.svg7
-rw-r--r--src/presentation.css51
-rw-r--r--src/styles.css2
-rw-r--r--src/talks/demo/index.md (renamed from src/talks/demo.md)0
-rw-r--r--src/talks/linuxgraphy-by-strabo/img/unix-dir-tree.pngbin0 -> 7674 bytes
-rw-r--r--src/talks/linuxgraphy-by-strabo/img/unix-layers.pngbin0 -> 8473 bytes
-rw-r--r--src/talks/linuxgraphy-by-strabo/index.md799
diff --git a/awk-edits/Flags.awk b/awk-edits/Flags.awk
index 6f62916..928b586 100644
--- a/awk-edits/Flags.awk
+++ b/awk-edits/Flags.awk
@@ -16,6 +16,8 @@
BEGIN {
flag[1] = "gb"
flagTitle[1] = "ENG"
+ flag[2] = "bg"
+ flagTitle[2] = "BG"
for (i = 1; i <= length(flag); i++) {
flagExp[i] = "&#38;&#38;" flag[i]
diff --git a/awk-edits/Pagenav.awk b/awk-edits/Pagenav.awk
index 46589fb..ddf74ff 100644
--- a/awk-edits/Pagenav.awk
+++ b/awk-edits/Pagenav.awk
@@ -14,7 +14,7 @@
BEGIN {
fileCheck = ARGV[1] # FILENAME isn't available in BEGIN
- if (match(fileCheck, /(blog|tutorials)\/.*\//) == 0) {
+ if (match(fileCheck, /(blog|tutorials|talks)\/.*\//) == 0) {
found = 1
}
else {
diff --git a/awk-edits/Presentation.awk b/awk-edits/Presentation.awk
index f0bbb4a..171ec7e 100644
--- a/awk-edits/Presentation.awk
+++ b/awk-edits/Presentation.awk
@@ -48,6 +48,14 @@
# Available values for SIZE: 18, 20, 27, 30, 37
# &&/font Text between &&fontSIZE and &&/font is sized accordingly
#
+# &&frcen Shorthand for "&&frow &&flexer &&centered"
+# Useful for horizontally centered items
+# &&/frcen Shorthand for "&&/centered &&flexer &&/frow"
+#
+# &&clide Shorthand for "&&slide &&flexer &&centered"
+# Useful for section pages
+# &&/clide Shorthand for "&&/centered &&flexer &&/slide"
+#
# -- Surroundings --
#
# As stated, there can only be one presentation per page.
@@ -74,29 +82,58 @@ BEGIN {
ended[ 1] = 0
names[ 2] = "&#47;font" # all font ftags can be closed with a &&/font
ended[ 2] = 0
-
- names[ 3] = "slide"
+ names[ 3] = "table"
ended[ 3] = 1
- names[ 4] = "centered"
+ names[ 4] = "ftable"
ended[ 4] = 1
- names[ 5] = "flexer"
- ended[ 5] = 2
- names[ 6] = "frow"
- ended[ 6] = 1
- names[ 7] = "fcol"
- ended[ 7] = 1
- names[ 8] = "font18"
- ended[ 8] = 0
- names[ 9] = "font20"
- ended[ 9] = 0
- names[10] = "font27"
- ended[10] = 0
- names[11] = "font30"
- ended[11] = 0
- names[12] = "font35"
- ended[12] = 0
- names[13] = "fright"
- ended[13] = 1
+ names[ 5] = "tarow"
+ ended[ 5] = 0
+
+ # Line breaks
+ names[ 6] = "lineb1"
+ ended[ 6] = 2
+ names[ 7] = "lineb2"
+ ended[ 7] = 2
+ names[ 8] = "lineb3"
+ ended[ 8] = 2
+ names[ 9] = "lineb4"
+ ended[ 9] = 2
+ names[10] = "lineb5"
+ ended[10] = 2
+ names[11] = "lineb6"
+ ended[11] = 2
+ names[12] = "lineb7"
+ ended[12] = 2
+ names[13] = "lineb8"
+ ended[13] = 2
+ names[14] = "lineb9"
+ ended[14] = 2
+
+ # Font sizes
+ names[15] = "font18"
+ ended[15] = 0
+ names[16] = "font20"
+ ended[16] = 0
+ names[17] = "font25"
+ ended[17] = 0
+ names[18] = "font27"
+ ended[18] = 0
+ names[19] = "font30"
+ ended[19] = 0
+ names[20] = "font35"
+ ended[20] = 0
+
+ # Everything else
+ names[21] = "slide"
+ ended[21] = 1
+ names[22] = "clide"
+ ended[22] = 1
+ names[23] = "centered"
+ ended[23] = 1
+ names[24] = "cont"
+ ended[24] = 1
+ names[25] = "fright"
+ ended[25] = 1
pres = ORS \
"<nav id=\"presentCont\">" ORS \
@@ -124,6 +161,13 @@ BEGIN {
rep[i] = rep[i] "</div>"
}
}
+
+ rep[3] = "<div class=\"layout-table\"><div class=\"layout-row\">"
+ crep[3] = "</div></div>"
+ rep[4] = "<div class=\"layout-table fixed-layout\"><div class=\"layout-row\">"
+ rep[5] = "</div><div class=\"layout-row\">"
+ rep[22] = "<div class=\"slide clide\"><div></div><div>"
+ crep[22] = "</div><div></div></div>"
}
function presentationSubstitute(ind) {
diff --git a/src/img/bg.svg b/src/img/bg.svg
new file mode 100644
index 0000000..b100dd0
--- /dev/null
+++ b/src/img/bg.svg
@@ -0,0 +1,7 @@
+<svg xmlns="http://www.w3.org/2000/svg" id="flag-icons-bg" viewBox="0 0 640 480">
+ <g fill-rule="evenodd" stroke-width="1pt">
+ <path fill="#d62612" d="M0 320h640v160H0z"/>
+ <path fill="#fff" d="M0 0h640v160H0z"/>
+ <path fill="#00966e" d="M0 160h640v160H0z"/>
+ </g>
+</svg>
diff --git a/src/presentation.css b/src/presentation.css
index 5e6e24a..5206c9f 100644
--- a/src/presentation.css
+++ b/src/presentation.css
@@ -19,8 +19,6 @@ h2, h3, h4, h5, h6 {
.slide {
box-sizing: border-box;
- display: flex;
- flex-direction: column;
height: 210mm;
padding: 1em;
width: 297mm; /* Size of landscape A4 paper */
@@ -29,37 +27,58 @@ h2, h3, h4, h5, h6 {
height: auto;
max-height: 100%;
max-width: 100%;
- width: auto;
+ /* width: auto; */
}
+ .slide > p:first-child, .slide > ul:first-child { margin-top: 0; }
.slide .svg { max-height: 1em !important; }
- .frow, .fcol { display: flex; flex-wrap: nowrap; }
- .frow, .fcol, .frow > *, .fcol > *, .slide > * {
- min-height: 0;
- min-width: 0;
- }
- .frow > *, .fcol > * { flex: 1; }
- .frow { flex-direction: row; }
- .frow > *:not(:last-child) { margin-right: 0.5em; }
- .fcol { flex-direction: column; }
- .fcol > *:not(:last-child) { margin-bottom: 0.5em; }
+ .clide { display: flex; flex-direction: column; }
+ .clide > * { flex: 1; }
.centered { text-align: center; }
.centered h1::after, .centered h2::after, .centered h3::after {
content: " \2550"
}
- .flexer { flex: 1; }
.fright { float: right; text-align: right; }
- .font35, .font30, .font27, .font20, .font18 {
- line-height: 1.5em;
+ .font35, .font30, .font27, .font25, .font20, .font18 {
+ line-height: 1.2em;
}
.font35 { font-size: 35px; }
.font30 { font-size: 30px; }
.font27 { font-size: 27px; }
+ .font25 { font-size: 25px; }
.font20 { font-size: 20px; }
.font18 { font-size: 18px; }
+ .layout-table {
+ margin: 0;
+ padding: 0;
+ display: table;
+ width: 100%;
+ }
+ .layout-table > .layout-row {
+ display: table-row;
+ }
+ .layout-row > * {
+ display: table-cell;
+ border: none;
+ padding: 0;
+ vertical-align: middle;
+ }
+ .fixed-layout { table-layout: fixed; }
+
+ .lineb1 { padding: 0.5em; }
+ .lineb2 { padding: 1.0em; }
+ .lineb3 { padding: 1.5em; }
+ .lineb4 { padding: 2.0em; }
+ .lineb5 { padding: 2.5em; }
+ .lineb6 { padding: 3.0em; }
+ .lineb7 { padding: 3.5em; }
+ .lineb8 { padding: 4.0em; }
+ .lineb9 { padding: 4.5em; }
+
+
/* Presenting mode */
.absolute-slide {
diff --git a/src/styles.css b/src/styles.css
index c0247f5..db2771d 100644
--- a/src/styles.css
+++ b/src/styles.css
@@ -122,7 +122,7 @@ img {
max-height: none !important;
object-fit: contain;
padding: 1em;
- position: absolute;
+ position: fixed;
top: 0;
width: 100vw;
z-index: 2;
diff --git a/src/talks/demo.md b/src/talks/demo/index.md
index 7640979..7640979 100644
--- a/src/talks/demo.md
+++ b/src/talks/demo/index.md
diff --git a/src/talks/linuxgraphy-by-strabo/img/unix-dir-tree.png b/src/talks/linuxgraphy-by-strabo/img/unix-dir-tree.png
new file mode 100644
index 0000000..38e5a9d
--- /dev/null
+++ b/src/talks/linuxgraphy-by-strabo/img/unix-dir-tree.png
Binary files differ
diff --git a/src/talks/linuxgraphy-by-strabo/img/unix-layers.png b/src/talks/linuxgraphy-by-strabo/img/unix-layers.png
new file mode 100644
index 0000000..77ea8f9
--- /dev/null
+++ b/src/talks/linuxgraphy-by-strabo/img/unix-layers.png
Binary files differ
diff --git a/src/talks/linuxgraphy-by-strabo/index.md b/src/talks/linuxgraphy-by-strabo/index.md
new file mode 100644
index 0000000..4f68b16
--- /dev/null
+++ b/src/talks/linuxgraphy-by-strabo/index.md
@@ -0,0 +1,799 @@
+# Linuxgraphy by Strabo
+
+&&presentation
+
+
+
+&&centered &&clide
+
+&&font35
+# Linuxgraphy by Strabo
+&&/font
+*Made by [Syndamia](https://syndamia.com)*
+
+&&lineb4 &&ftable
+
+&&lineb1
+
+2000 years ago [Strabo](https://en.wikipedia.org/wiki/Strabo) published [Geography](https://en.wikipedia.org/wiki/Geography), in which he laid out the world as it was known to the Romans and Greeks.
+<br><br>
+Today, I'll lay out Linux as it is known to me.
+
+![](https://upload.wikimedia.org/wikipedia/commons/thumb/e/ed/Strabo.jpg/199px-Strabo.jpg)
+
+&&lineb1
+
+&&/table
+
+
+&&/clide &&/centered
+
+
+
+&&font35 &&slide
+
+# Contents
+
+&&ftable &&cont
+
+1. Brief timeline
+2. Structure of UNIX-likes
+ 1. Shell
+ 2. UNIX-style file system
+ 2. Kernel
+&&lineb2
+3. Linux from the inside
+ 1. Shells
+ 2. Files and directories
+ 3. Common configuration files
+ 4. System management
+4. Software licensing
+
+&&/cont &&cont
+
+5. What makes up a useful OS
+ 1. Bootloader
+ 1. Init system
+ 2. Package manager
+ 3. Desktop manager
+6. War on distros
+&&lineb5
+7. Demo - setup from zero
+
+&&/cont &&/table
+
+&&/slide &&/font
+
+
+
+&&slide
+
+# 1. Brief timeline
+
+&&font27
+
+#### 1945 - 1955
+
+You directly loaded instructions into memory and let it execute your "code" (processor instructions).
+Nothing else ran on the machine.
+
+This process was labor intensive, a qualified operator had to load your program, then after completion he would have to dump the memory contents, remove any tapes, punch cards, etc., reset the machine and load the next job.
+
+#### 1956 - 1959
+
+By the late 1950s, as computers became faster, a lot of time was spend on operators managing jobs.
+
+This was automated via [resident monitors](https://en.wikipedia.org/wiki/Resident_monitor): very small programs, which always *resided* in memory, and *monitored* what the state of the current job was.
+If a job finished, it would automatically load and start the next program.
+
+Since a monitor could run the next program at any time, series (batches) of jobs would be grouped together and execute one after another by the monitor.
+This process is called [batch processing](https://en.wikipedia.org/wiki/Batch_processing).
+
+&&/font &&/slide
+
+
+
+&&font27 &&slide
+
+#### 1960s
+
+But by far the biggest bottle neck were peripherals, tapes and punch cards were extremely slow.
+[Multiprogramming](https://en.wikipedia.org/wiki/Computer_multitasking#Multiprogramming) was born: while the current job is waiting for a peripheral, doing nothing, another job would be started.
+
+&&lineb2
+
+American Airlines (in collaboration with IBM) created a [travel reservation system](https://en.wikipedia.org/wiki/Sabre_%28travel_reservation_system%29), where travel agents would search, price and book services provided by the airline.
+Such systems increased the requirements of a computer system:
+
+- User accounts with concurrent access
+- Response time needed to be slower and ease of use had to be improved
+- Storage organization, also following the rise of disks
+- Data communication links (were often phone lines)
+
+&&lineb2
+
+Another important factor is the rise of minicomputers: much smaller and incredibly cheap (compared to the alternatives) computers, which lead to an increase in digital technology usage by businesses.
+
+&&/slide &&/font
+
+
+
+&&font27 &&slide
+
+#### 1964 - 1969
+
+It is important to talk about IBM's [System/360](https://en.wikipedia.org/wiki/IBM_System/360).
+A line of computers, each with great expansion capabilities, redesigned hardware of unparalleled speed, simulators and emulators for backwards compatibility, all under one instruction set and operating system (mostly job management).
+
+This is also the time when the mouse, alongside bit-mapped displays, graphical user interface concepts, teleconferencing and hypertext, [was invented](https://en.wikipedia.org/wiki/The_Mother_of_All_Demos).
+
+Our final stop is [Multics](https://en.wikipedia.org/wiki/Multics), an operating system that influenced all modern operating systems.
+Some of it's novel ideas include, but are not limited to:
+
+- [Time-sharing](https://en.wikipedia.org/wiki/Time-sharing): sharing resources of a singular machine among many users (via [multiprogramming](https://en.wikipedia.org/wiki/Multiprogramming) and [multi-tasking](https://en.wikipedia.org/wiki/Computer_multitasking))
+- [Single level store](https://en.wikipedia.org/wiki/Single-level_store) (aka [virtual memory](https://en.wikipedia.org/wiki/Virtual_memory)): Processes would write into contiguous memory, but in reality it is scattered and managed by the operating system.
+- [Protection rings](https://en.wikipedia.org/wiki/Protection_ring): Allowing different levels of access to different resources (programs). In general, this also often requires a [CPU protected mode](https://en.wikipedia.org/wiki/Protected_mode).
+- [Hierarchical file system](https://en.wikipedia.org/wiki/Directory_%28computing%29): Arbitrary directories with subdirectories, rather than just having files next to each other or having directories which could only contain files.
+- [Command processor](https://en.wikipedia.org/wiki/Shell_%28computing%29) (that is separated from the OS): More on that later
+
+&&/slide &&/font
+
+
+
+&&font27 &&slide
+
+#### 1969: Death of Multics and birth of UNIX
+
+Multics was very ambitious and had a lot of great ideas and minds behind it, but it ultimately grew too large and failed.
+Programming was done mostly in [Bell Labs](TODO), who pulled pretty quickly from the project.
+
+&&lineb1 &&ftable
+
+&&font18
+![](https://upload.wikimedia.org/wikipedia/commons/f/f8/Ken-Thompson-2019.png =250x)
+*Ken Thompson image by National Inventors Hall of Fame*
+![](https://upload.wikimedia.org/wikipedia/commons/1/1b/Ken_Thompson_and_Dennis_Ritchie--1973.jpg)
+*Ken Thompson and Dennis Ritchie in 1973*
+&&/font
+
+&&cont
+
+[Ken Thompson](TODO), one of the programmers that worked on it, still had some desire to work on operating systems.
+After Bell Labs left Multics, he made a program for maximizing the throughput of a disk on a PDP-7.
+To test it, he wrote some programs over time and eventually realised an operating system could easily be made.
+
+This marked the birth of UNIX, an operating system, based and expanded on many of Multic's ideas (except the "grow too large" one).
+
+&&/cont
+
+&&/table
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+# 2. Structure of UNIX-likes
+
+Ignoring [standards](https://unix.stackexchange.com/questions/14368/difference-between-posix-single-unix-specification-and-open-group-base-specifi/14415) and [specifications](https://unix.stackexchange.com/questions/87686/what-makes-an-operating-system-unix-like), in my opinion, from the point of a user, a UNIX-like OS has the following components:
+
+&&lineb1
+
+1. **shell**: A programmable replaceable command-line interpreter, with utilities for managing the whole system and support for pipelines and I/O redirection
+2. **UNIX-style file system**: [Filesystem](https://en.wikipedia.org/wiki/Unix_filesystem) as a rooted tree (even for all separate volumes), objects (nodes) in the file system are [inodes](TODO) and an inode can be [(at least)](https://en.wikipedia.org/wiki/Unix_file_types) either a regular file, directory or devices. Permissions are set per owner, group members and other users.
+3. **kernel**: Program that manages all communication and operations between the hardware and software
+
+&&lineb3
+
+&&font20 *For now we'll generally just look over some of the common stuff and go into detail later, while in Linux.* &&/font
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+## 2.1. shell
+
+&&lineb2 &&ftable
+
+&&cont
+Our operating system is divided into layers, [like an onion](https://youtu.be/-FtCTW2rVFM?t=57).
+Only the kernel has access to the hardware.
+shells and executables (binaries) have access to the kernel.
+
+shells provide user interfaces, [both](http://en.wikipedia.org/wiki/Shell_%28computing%29) command-line and graphical.
+While on the topic of UNIX, we'll only discuss the former.
+&&/cont
+
+&&centered ![](./img/unix-layers.png) &&/centered
+
+&&/table &&/slide &&/font
+
+
+
+&&font27 &&slide
+
+Command-line shells operate solely with text, preferably without too fancy formatting (there are very modern ones that can handle images, but these are an exception, rather than the norm).
+
+&&lineb1 &&ftable
+
+Historically, video displays (at first [CRT](TODO) ones) became widely available in the late 1970s, but before that the "mainstream" way to access a computer was with a teleprinter (commonly known as teletype): effectively a (typewriter) keyboard and a fast text printer, connected to a computer.
+
+&&font18 &&fright
+![](https://upload.wikimedia.org/wikipedia/commons/thumb/d/df/ASR-33_at_CHM.agr.jpg/1280px-ASR-33_at_CHM.agr.jpg =320x)
+*Teletype Model 33 by [Arnold Reinhold](https://commons.wikimedia.org/wiki/User:ArnoldReinhold)*
+&&/fright &&/font
+
+&&tarow
+
+&&font18
+![](https://upload.wikimedia.org/wikipedia/commons/thumb/9/99/DEC_VT100_terminal.jpg/675px-DEC_VT100_terminal.jpg?20131106192408 =320x)
+*DEC VT100 by [Jason Scott](https://www.flickr.com/people/54568729@N00)*
+&&/font
+
+Later, those were replaced by terminals, a "normal" keyboard and a display, connected to a computer.
+**The** most popular and influential one was the [VT100](TODO), with it's most influential feature being never seen before support of [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code): special text that would modify the cursor position and later being able to, for example, change colors for specific text.
+
+&&/table &&/slide &&/font
+
+
+
+&&font27 &&slide
+
+In UNIX CLI shells, most of the commands are just regular programs.
+These programs could exist in more than one folder: `/bin` and `/usr/bin` for example, so we store every location in a variable called "PATH".
+
+Command-line UNIX shells always have the following features:
+
+- pipelines: being able to redirect the output from one command to another without limit
+
+ ```
+ command1 [args...] | command 2 [args...] | ...
+ ```
+
+- I/O redirection: redirection of input and output, allowing use to use a file as (user) input:
+
+ ```
+ command [args...] < filepath
+ ```
+
+ or to put output into a file
+
+ ```
+ command [args...] > filepath
+ ```
+
+&&font18
+*A lot of modern ones also support [heredocs](https://en.wikipedia.org/wiki/Here_document), [job control](https://en.wikipedia.org/wiki/Job_control_%28Unix%29), built-in [test command](https://en.wikipedia.org/wiki/Test_%28Unix%29) and more, we'll explore them later.*
+&&/font
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+## 2.2. UNIX-style file system
+
+- Rooted singular tree of directories. Disk partitions, removable media, etc. all live in that tree.
+- Each tree object (node) is an [i(ndex)node](TODO), containing type, ownership, access, internal data and any other metadata, but **not** name!
+- Directory inodes (files) contain a table with rows of names and inode numbers, mapping a file name to it's contents. Each row is called a [hard link](https://en.wikipedia.org/wiki/Hard_link). Every directory has a hard link to itself, called ".", and a hard link to it's parent, called "..".
+
+![](./img/unix-dir-tree.png)
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+The main attributes that every inode has are as follows:
+
+- [file type](https://en.wikipedia.org/wiki/Unix_file_types): Each inode represents some sort of file (data), but a "file" can also be a directory or device, so we need to know how to handle it.
+ There are 7 main types (but there can exist more, depending on OS):
+ + **regular**: just a plain old file
+ + **directory**: as explained, a file containing hard links to other files. Each directory is allowed to appear only once in a single parent.
+ + **symbolic link**: points to any file (or directory). It contains the (relative) path to that object (as a simple string), so a symlink could even not be valid.
+ + **FIFO special**: aka [named pipe](https://en.wikipedia.org/wiki/Named_pipe), a special type of regular file, where at any moment only one process can read from it and one can write to it. It takes the concept of shell pipes to inter-process communication.
+ + **block special**: a device which is randomly accessible, like a hard drive or cdrom drive.
+ + **character special**: devices which are accessed via serial streams of input or output, like keyboards, mice, graphics cards and teletypes
+ + **sockets**: file for inter-process communication. Compared to FIFO specials, they can be used by more than two processes, used in both direction and support [file descriptors](https://en.wikipedia.org/wiki/File_descriptor) and packets
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+- [file permissions](https://en.wikipedia.org/wiki/File_system_permissions): control the ability of a user to read (navigate for directories), change and execute a file.
+ A user in UNIX is essentially a small collection of data, most important of it being an ID (number), a name (string), a group id (number; files created by the user are in that group) and a password.
+ Groups are also small collections of data, but much simpler, comprised only of an ID (number), a name (string) and a list of users that are "in" the group. Their main purpose is to simplify access control.
+ The data for each is stored in `/etc/passwd` and `/etc/group` respectively.
+ <br>
+ File permissions are split into three sets: what the owner can do, what group members can do and what anyone else can do.
+ Each set contains a mix of three permissions: **r**ead, **w**rite and e**x**ecute, and each set stores some combination of them.
+- link count: the amount of hard links that point to the inode. Every directory inode contains (normally) exactly two: one from the parent and one from itself ("."). A file is only deleted where there are no hard links left to it (or when there is only one for a directory).
+- User ID of owner and Group ID
+- file size and timestamps for modification
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+## 2.3. Kernel
+
+&&lineb2
+
+The kernel is completely separated from everything else, it only communicates with hardware and exposes an API to have other programmes communicate with it.
+
+&&lineb2
+
+Linux is **not** an operating system, it is a kernel!!!
+
+&&/slide &&/font
+
+
+
+&&font27 &&slide
+
+# 3. Linux from the inside
+
+Enough theory, time to have some fun and learn Linux!
+
+We'll be using [Linux Minimal Live](https://ivandavidov.github.io/minimal/#home) because:
+
+- it's very small, comprised of only the Linux kernel, GNU C library and Busybox
+ so confusion, distractions and distro-specific configs will be minimal
+- made by a fellow Bulgarian &&bg
+
+It's important to note that it isn't an installable OS, but just a bootable disk image.
+
+We're going to explore and look around the following stuff:
+
+&&lineb1
+
+- **Shells**: What a modern shell would often support on a Linux based OS
+- **Files and directories**: Naming conventions and commands to work with them
+- **Common configuration files**: Relevant configuration files, their purpose and syntax
+- **System management**: Other commands with which to modify your system
+
+&&/slide &&/font
+
+
+
+&&slide
+
+## 3.1. Shells
+
+- [Job control](https://en.wikipedia.org/wiki/Job_control_%28Unix%29): Management of currently running groups of processes
+ + `&`: A process can be ran in the background with an ampersand (&) at the end of the command:
+
+ ```
+ command [args...] &
+ ```
+
+ + `Ctrl+z`: suspend (stop but leave in the background) the currently running (foreground) job
+ + `bg`: start a suspended job in the background
+ + `fg`: resume the last job to be put in the background and make it the current job with which we're interacting
+ + `jobs`: list all active (background) jobs
+ &&lineb2
+ + Every job is identified with a Job ID (number), which you can use by prepending a percentage sign. Example, to resume the job with JID 4:
+
+ ```
+ fg %4
+ ```
+ + For managing everything, usually there is a job table.
+ Upon shell termination, the shell tells all jobs in that table to terminate and waits for them.
+ `disown`: remove a job from the job table
+ + `kill`: send a signal to the process or job. Then that process will have to handle it accordingly.
+ Common ones are `-KILL` to immediately stop the process, `-QUIT` to quit it, `-ABRT` to cancel the current action, `-TERM` shut down (orderly), `-STOP` shut down (forcefully)
+
+&&/slide
+
+
+
+&&font27 &&slide
+
+- [heredoc](https://en.wikipedia.org/wiki/Here_document): File literal, meaning it is a user "string" which is interpreted as a file
+ + start with `<< NAME`, where NAME can be anything you want, it is used to mark the beginning and end of a heredoc. `<<` is also a redirection symbol
+ + on every new line write out your text, all characters will be preserved
+ + to end it, write out `NAME` on the beginning of a new empty line. Example:
+
+ ```
+ cat << MYFILE
+ This is
+ some
+ text
+ MYFILE
+ ```
+
+- control operators: Control what command is executed, depending on [exit status](https://en.wikipedia.org/wiki/Exit_status)
+ + `expr1 && expr2`: Run expr2, only if expr1 exited successfully
+ + `expr1 || expr2`: Run expr2 if expr1 exited unsuccessfully
+ + `expr1 ; expr2`: Run expr2 after expr1 finished (no matter how)
+ + Every program returns an exit status (number) to the shell, zero being a successful closing, and all others indicating failure.
+
+&&/slide &&/font
+
+
+
+&&font27 &&slide
+
+&&lineb1
+
+- [redirection](https://en.wikipedia.org/wiki/Redirection_%28computing%29): Outside of having `<` and `>` for I/O redirection, often there is also
+ + `>>`: Acts like `>`, putting text into a file, but rather than overwriting everything, it appends it
+ + `<<`: As explained, for heredocs
+ + `<<<`: To the right is a string ([herestring](https://en.wikipedia.org/wiki/Here_document#Here_strings)), and it is interpreted as a file
+
+ ```
+ cat <<< "Hello World!"
+ ```
+
+ + Standard input, standard output and standard error are all files with which the shell works.
+ Typing text in the shell puts it into stdin, command output are put into stdout (and shown to the user) and errors are put into stderr (also shown to the user).
+ Each one of them is numbered from 0 to 2, and you can specify redirection by appending or prepending it to the redirection symbol.
+ * `N>outputfile`: redirects the output from standard stream N into outputfile
+ * `N>&M`: redirects the output from standard stream N into standard stream M
+ * `N<inputfile`: redirects input file contents to standard stream N
+ * `N<&M`: redirects standard stream M to standard stream N
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+&&lineb1
+
+- [built-in test command](https://en.wikipedia.org/wiki/Test_%28Unix%29): With `test` you can do conditional expressions. You can also often use brackets `[ args... ]` instead of `test args...`
+ + Some of the available file checks
+ * `-e FILENAME`: FILENAME exists
+ * `-d FILENAME`: if FILENAME is a directory
+ * `-h FILENAME`: if FILENAME is a symbolic link
+ * `-w FILENAME`: you can write in FILENAME
+ + Some of the available string checks
+ * `-n STR`: string STR has nonzero length
+ * `-z STR`: string STR has length zero
+ * `STR1 = STR2` and `STR1 != STR2`: self explanatory
+ + Some of the available number checks
+ * `INT1 -eq INT2`: equal integers
+ * `INT1 -gt INT2`: INT1 > INT2
+ * `INT1 -gt INT2`: INT1 >= INT2
+ + Operators: `!` - negation, `-a` - binary AND, `-o` - binary OR, parentheses for grouping (escaped with `\`)
+
+
+&&/slide &&/font
+
+
+
+&&slide
+
+- [scripting support](https://en.wikipedia.org/wiki/Shell_script): Rather than running a series of commands manually, you can put them all in a file and run that
+ + `#`: Everything between a # and the end of the line denotes a comment
+ + `#!`: If on the first line of the file, is treated as a [shebang](https://en.wikipedia.org/wiki/Shebang_%28Unix%29), which specifies what interpreter to be used for the script
+ + Each command (line) is executed in series, from top to bottom
+
+- [compound commands](TODO): Shells also often offer more advanced structured, with which to more easily write complex expressions
+
+&&/slide
+
+
+
+&&font30 &&slide
+
+## 3.2. Files and directories
+
+&&lineb1
+
+- `/bin`: main command programs (binaries), used by users
+- `/etc`: system configuration files
+- `/sbin`: command programs, used for the system operation
+- `/usr`: other system resources
+ + `/usr/bin`: all other user command binaries
+ + `/usr/lib`: library files
+ + `/usr/local`: local, system software
+ + `/usr/share`: architecture independent data, like manuals
+- `/var`: variable data, like logs and cache
+- `/dev`: devices
+- `/home`: home directories of all users
+- `/lib`: libraries and kernel modules
+- `/mnt`: mounted temporary filesystems
+- `/proc`: process information
+- `/root`: home directory for the root user
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+### General file system commands
+
+&&lineb1
+
+- `mkdir`: create directories
+- `rm`: remove a (hardlink to) file or directory
+- `shred`: overwrite file contents
+- `mv`: move file (or directory) to another directory
+- `cp`: copy a file
+- `ln`: create hard (or soft, with `-s`) links to files (inodes)
+- `ls`: list directory contents
+- `dd`: do many things with files, like modifying and duplicating data across devices and partitions, (basic) data recovery and generating files
+- `du`: estimate file usage
+- `stat`: display status for file system or file system
+- `chwon`: change owner of an inode
+- `chgrp`: change group of an inode
+- `chmod`: change file modes
+- `find`: search for a file inside a directory (recursively)
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+### Working with text (files)
+
+&&lineb1
+
+- `echo`: prints a given string to standard output
+- `cat`: sequentially prints files to standard output
+- `less`: view files with support for scrolling
+- `grep`: searches for matches in a file, using simplified regular expressions. Often there is `egrep`, which allows for extended regex and `fgrep` where strings are matched as-is.
+- `sed`: filter and transform text from files, according to regex
+- `tr`: translate, map (more than one to one for example) and delete characters
+- `cut`: remove parts of text from each line
+- `head`: print the first lines (or characters) of a file
+- `tail`: print the last lines (or characters) of a file
+- `strings`: find embedded text inside binary files
+- `truncate`: shrink or extend the size of a file
+- `wc`: count words inside file
+- `diff`: compare files and show their differences
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+### Working with devices
+
+&&lineb1
+
+- `mount`: bind another file system to a location in the file system
+- `umount`: remove binding to a file system
+
+&&/slide &&/font
+
+
+
+&&font25 &&slide
+
+## 3.3 Common configuration files
+
+- `/etc/group`: the data for all groups is stored here, in the format
+
+ ```
+ GROUPNAME:PASSWORD:GID:USERS...
+ ```
+
+- `/etc/passwd`: the data for all users is stored here, in the format
+
+ ```
+ USERNAME:PASSWORD:UID:GID:USERINFO:HOMEDIR:SHELL
+ ```
+
+- `/etc/shadow`: stores other user data, especially the password as an encrypted string, in the format
+
+ ```
+ USERNAME:PASSWORD:LASTCHANGED:MINBETWEENCHANGES:MAXBETWEENCHANGES:WARNEXPIRE:INACTIVEDAYS:EXPIRE
+ ```
+
+- `/etc/fstab`: mountings of devices to the file system, read on boot by mount
+- `/etc/hosts`: list of host names (domain names) and their corresponding IP address, when a DNS server doesn't do the job
+- `/etc/bashrc`: global defaults and aliases used by the bash shell
+
+&&/slide &&/font
+
+
+
+&&font25 &&slide
+
+## 3.4. System management
+
+- System information
+ + `date`: display current date and time
+ + `hostname`: show (or set) the systems hostname (network name)
+ + `free`: display free memory on the system
+
+- Users and groups
+ + `useradd`: creates a new user (with a password)
+ + `userdel`: remove a user and all of his files
+ + `usermod`: modify a user account, including his name and groups
+ + `passwd`: change password of a user. With `-l` user could be locked (impossible to log in)
+ &&lineb1
+ + `groupadd`: create a new group
+ + `groupdel`: remove a group
+ + `groupmod`: modify an existing group
+ &&lineb1
+ + `w`: show who is logged in and what they are doing
+ + `who`: show who is logged in
+ + `whomai`: print username
+ + `login`: establish a new connection to the system
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+# 4. Software licensing
+
+It is important to note that most software in Linux, including the kernel itself, is under a variety of open licenses.
+An open license is a license which allows others to reuse the original work, under some restrictions.
+
+For software, such a license is applied to the source code from which the original application was made.
+Some commonly used ones, with a (NON-LEGALLY BINDING) summary include:
+
+- MIT: the author is not responsible for anything that the code does
+- BSD-3-Clause: use the same license (copyleft), the author is not responsible for anything that the code does
+- GNU GPL: disclose the original project and use the same license (copyleft)
+
+This is important, since pretty much everything can be freely modified by anyone (for the better or worse, but generally better).
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+# 5. What makes up a useful OS
+
+We talked about the modularity of a Linux-based operating system.
+Overall, these are the main elements that make up a desktop operating system you might want to use:
+
+&&lineb1
+
+1. **Bootloader**: load the kernel and operating system
+2. **Init system**: well managed way to start everything inside the OS
+3. **Package manager**: way to manage our binaries
+4. **Desktop manager**: graphical shell
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+## 5.1. Bootloader
+
+&&lineb2
+
+When a computer boots, it needs to start an operating system, but you can't expect it to know how to boot any operating system.
+Skipping over the details, the computer starts a small program called the bootloader, which handles loading the OS.
+
+On Linux, the most used one is called [GRUB](TODO).
+With it you can also specify which kernel to load, with which parameters to load the kernel and which OS to start.
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+## 5.2. Init system
+
+&&lineb1
+
+In Minimal Linux Live, the whole system is started by some hard written scripts, this isn't very modular and extensible, that is why we need a special system.
+
+Generally, the [init system](https://en.wikipedia.org/wiki/Init) loads a series of services, where each service is just a file that specifies what and how something needs to be ran.
+
+The most common init systems are
+
+- [systemd](https://en.wikipedia.org/wiki/Systemd), which also aims to also provide easy system configuration
+- [openrc](https://en.wikipedia.org/wiki/OpenRC), a simple and modern system
+
+&&/slide &&/font
+
+
+
+&&font35 &&slide
+
+## 5.3. Package manager
+
+&&lineb1
+
+Running a program is as simple as putting the executable in a nice folder, like `/usr/bin`.
+However this process isn't very convenient if you're only using a shell and more tedious if using a graphical shell.
+
+The solution is to have all programs in one location, where you can download, install and potentially update a program with one simple command, just using the program's name.
+Other good features include installing dependencies and checking if a package is tampered with.
+
+There is another "type" of package managers, those similar to `portage`, where packages are actually instructions on how to download and compile a specific version of the program.
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+## 5.4. Window systems
+
+&&lineb2
+
+A widow system is your graphical shell: the graphical way to interact with your computer (the kernel).
+It's main components are:
+
+- **Window manager**: the overall system with which you create, remove, resize, etc. windows. They are generally separated into two types:
+ + Stacked: this is what you know, a windows are just rectangles floating about, and can be put one over each other
+ + Tiled: windows take up a predefined (but changeable) portion of the screen
+- **Compositor**: windows have an unseen buffer, allowing them to be be processed beforehand. This allows for adding transparency, animation effects and more.
+- **Session manager**: application that manages the window managers, allowing to use different managers or for multiple users to start their own graphical sessions.
+
+&&/slide &&/font
+
+
+
+&&font27 &&slide
+
+# 6. War on distros
+
+A distribution is a complete set of of all applications that we've talked so far.
+
+Overall, there are five distributions from which 90% of all other distros are based upon:
+
+1. Slackware: as the oldest still maintained distro, it served as inspiration for a lot of other distros. It aims to be as simple and as close to UNIX as possible.
+2. Debian (and Ubuntu): it is the most popular distribution (if we also include Ubuntu, since they're so similar). Ubuntu aims to be modern and fancy, while Debian aims to be as stable as possible, which makes it the most popular in server usage.
+4. Gentoo: the distribution which defined non-binary software distribution
+5. Arch Linux: a very popular and modern distribution with the goal of providing the latest and greatest software.
+
+We haven't touched too much, but Linux distributions aren't limited to desktop or server computers.
+Two more uncommon ones are:
+
+1. AOSP: the base of the whole Android operating system
+2. OpenWRT: a router operating system
+
+&&/slide &&/font
+
+
+
+&&font30 &&slide
+
+# 7. Demo - setup from zero
+
+&&lineb4
+
+Now for the best part: we'll be installing a Linux distribution from a laptop running Windows 10!
+
+I've chosen to install [Linux Mint](TODO), since it is generally targeted towards newcomers and will feel familiar enough to Windows users.
+
+Currently there won't be an official recording of the process, you should've been here live!
+
+&&/slide &&/font
+
+
+
+&&font35 &&clide &&centered
+
+# Thank you for your time
+
+&&/centered &&/clide &&/font
+
+
+
+&&slide
+
+## Sources
+
+- [wikipedia.org](https://en.wikipedia.org/) has been used extensively.
+- [CS416 - Operating Systems Design](https://people.cs.rutgers.edu/~pxk/416/index.html) by [Paul Krzyzanowski](https://people.cs.rutgers.edu/~pxk/rutgers/) at [Rutgers State University](https://www.cs.rutgers.edu/)
+- [Origins and History of UNIX, 1969-1995](https://web.archive.org/web/20220713165958/https://homepage.cs.uri.edu/~thenry/resources/unix_art/ch02s01.html) from [The Art of Unix Programming](TODO) by Eric Steven Raymond
+- [Ken Thompson interviewed by Brian Kernighan at VCF East 2019](https://www.youtube.com/watch?v=EY6q5dv_B-o) by [Vintage Computer Federation](https://vcfed.org/)
+- [Hard links and Unix file system nodes](https://teaching.idallen.com/dat2330/04f/notes/links_and_inodes.html) from [DAT 2330 Introduction to Operating Systems](https://teaching.idallen.com/dat2330/04f/) by [Ian D. Allen](http://www.idallen.com/)
+
+&&/slide