From 30ca940eeb9e2c317d4b624f0a6b487fd2565991 Mon Sep 17 00:00:00 2001 From: Jerome Petazzoni Date: Mon, 4 Jun 2018 05:49:24 -0500 Subject: [PATCH 1/4] Opt-out a bunch of slides in the deep dive section --- slides/intro/Namespaces_Cgroups.md | 36 ++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/slides/intro/Namespaces_Cgroups.md b/slides/intro/Namespaces_Cgroups.md index 981ef5ae..ff85a9ac 100644 --- a/slides/intro/Namespaces_Cgroups.md +++ b/slides/intro/Namespaces_Cgroups.md @@ -76,6 +76,8 @@ The last item should be done for educational purposes only! --- +class: extra-details, deep-dive + ## Manipulating namespaces - Namespaces are created with two methods: @@ -94,6 +96,8 @@ The last item should be done for educational purposes only! --- +class: extra-details, deep-dive + ## Namespaces lifecycle - When the last process of a namespace exits, the namespace is destroyed. @@ -114,6 +118,8 @@ The last item should be done for educational purposes only! --- +class: extra-details, deep-dive + ## Namespaces can be used independently - As mentioned in the previous slides: @@ -150,6 +156,8 @@ The last item should be done for educational purposes only! --- +class: extra-details, deep-dive + ## Creating our first namespace Let's use `unshare` to create a new process that will have its own UTS namespace: @@ -166,6 +174,8 @@ $ sudo unshare --uts --- +class: extra-details, deep-dive + ## Demonstrating our uts namespace In our new "container", check the hostname, change it, and check it: @@ -398,6 +408,8 @@ class: extra-details --- +class: extra-details, deep-dive + ## Setting up a private `/tmp` Create a new mount namespace: @@ -435,6 +447,8 @@ The mount is automatically cleaned up when you exit the process. --- +class: extra-details, deep-dive + ## PID namespace in action Create a new PID namespace: @@ -453,10 +467,14 @@ Check the process tree in the new namespace: -- +class: extra-details, deep-dive + 🤔 Why do we see all the processes?!? --- +class: extra-details, deep-dive + ## PID namespaces and `/proc` - Tools like `ps` rely on the `/proc` pseudo-filesystem. @@ -471,6 +489,8 @@ Check the process tree in the new namespace: --- +class: extra-details, deep-dive + ## PID namespaces, take 2 - This can be solved by mounting `/proc` in the namespace. @@ -570,6 +590,8 @@ Check `man 2 unshare` and `man pid_namespaces` if you want more details. --- +class: extra-details, deep-dive + ## User namespace challenges - UID needs to be mapped when passed between processes or kernel subsystems. @@ -686,6 +708,8 @@ cpu memory --- +class: extra-details, deep-dive + ## Cgroups v1 vs v2 - Cgroups v1 are available on all systems (and widely used). @@ -759,6 +783,8 @@ cpu memory --- +class: extra-details, deep-dive + ## Avoiding the OOM killer - For some workloads (databases and stateful systems), killing @@ -778,6 +804,8 @@ cpu memory --- +class: extra-details, deep-dive + ## Overhead of the memory cgroup - Each time a process grabs or releases a page, the kernel update counters. @@ -796,6 +824,8 @@ cpu memory --- +class: extra-details, deep-dive + ## Setting up a limit with the memory cgroup Create a new memory cgroup: @@ -823,6 +853,8 @@ The current process *and all its future children* are now limited. --- +class: extra-details, deep-dive + ## What's `<<<`? - This is a "here string". (It is a non-POSIX shell extension.) @@ -847,6 +879,8 @@ The current process *and all its future children* are now limited. --- +class: extra-details, deep-dive + ## Writing to cgroups pseudo-files requires root Instead of: @@ -874,6 +908,8 @@ echo $$ > $CG/tasks --- +class: extra-details, deep-dive + ## Testing the memory limit Start the Python interpreter: From 6e35162788ec3aa793f7625c2145534259072633 Mon Sep 17 00:00:00 2001 From: Jerome Petazzoni Date: Mon, 4 Jun 2018 05:50:21 -0500 Subject: [PATCH 2/4] Remove 'kubernetes in action' demo --- slides/intro/Orchestration_Overview.md | 5 ----- 1 file changed, 5 deletions(-) diff --git a/slides/intro/Orchestration_Overview.md b/slides/intro/Orchestration_Overview.md index b07b3418..5be67d90 100644 --- a/slides/intro/Orchestration_Overview.md +++ b/slides/intro/Orchestration_Overview.md @@ -420,8 +420,3 @@ It depends on: - false, if we focus on what matters. ---- - -## Kubernetes in action - -.center[![Demo stamp](images/demo.jpg)] \ No newline at end of file From cc6f36b50f5bf9f027de7de2aef426a61892b0c9 Mon Sep 17 00:00:00 2001 From: Jerome Petazzoni Date: Mon, 4 Jun 2018 05:54:02 -0500 Subject: [PATCH 3/4] Wording (non-native speakers probably don't know boo-boo) --- slides/kube/rollout.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slides/kube/rollout.md b/slides/kube/rollout.md index a6120b9f..0637d0fe 100644 --- a/slides/kube/rollout.md +++ b/slides/kube/rollout.md @@ -133,7 +133,7 @@ That rollout should be pretty quick. What shows in the web UI? --- -## Rolling out a boo-boo +## Rolling out something invalid - What happens if we make a mistake? From a21e8b0849aae43510f625c6aa87012ae3d8e70f Mon Sep 17 00:00:00 2001 From: Jerome Petazzoni Date: Mon, 4 Jun 2018 06:11:00 -0500 Subject: [PATCH 4/4] Image and title size fixes --- slides/intro/Ambassadors.md | 2 ++ slides/intro/Compose_For_Dev_Stacks.md | 2 +- slides/intro/Local_Development_Workflow.md | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/slides/intro/Ambassadors.md b/slides/intro/Ambassadors.md index 136d7453..261b866d 100644 --- a/slides/intro/Ambassadors.md +++ b/slides/intro/Ambassadors.md @@ -40,6 +40,8 @@ ambassador containers. --- +class: pic + ![ambassador](images/ambassador-diagram.png) --- diff --git a/slides/intro/Compose_For_Dev_Stacks.md b/slides/intro/Compose_For_Dev_Stacks.md index 39065520..2e0a6a3e 100644 --- a/slides/intro/Compose_For_Dev_Stacks.md +++ b/slides/intro/Compose_For_Dev_Stacks.md @@ -49,7 +49,7 @@ Before diving in, let's see a small example of Compose in action. --- -## Compose in action +class: pic ![composeup](images/composeup.gif) diff --git a/slides/intro/Local_Development_Workflow.md b/slides/intro/Local_Development_Workflow.md index 11f53e22..648dfe18 100644 --- a/slides/intro/Local_Development_Workflow.md +++ b/slides/intro/Local_Development_Workflow.md @@ -17,7 +17,7 @@ At the end of this section, you will be able to: --- -## Containerized local development environments +## Local development in a container We want to solve the following issues: