~/talk

Tutorial: Back to Basics: Hands-On Deployment of Stateful Workloads on Kubernetes

Talkat KubeCon + CloudNativeCon Europe 2019 · on Tuesday, 2019-05-21· at 11:05· Hall 8.0 F5· [kubernetes, databases]
name:David Zhu
links:none on file
slides:none on file

Hands-on tutorial shows how Kubernetes primitives actually deploy stateful apps: use a StatefulSet with PVC template so each replica gets its own dynamically provisioned disk via a StorageClass, create a headless service DNS for stable pod names, and run a three‑node Cassandra cluster plus a simple counter web front end. Commands used: kubectl apply/describe/logs/exec. Demo provisions 3 PVs, scales to 4, kills a pod to prove restart with same DNS, and requires manual nodetool cleanup when removing replicas.

AI-written summary · about

  1. 0:00Start
  2. 0:23Basic Kubernetes Storage Concepts
  3. 0:54General Housekeeping
  4. 4:12Persistent Volume
  5. 5:40Dynamic Provisioning
  6. 7:03Benefits of Dynamic Provisioning
  7. 8:21Deployment
  8. 10:47Services
  9. 11:56Headless Service
  10. 12:48Useful Cube Control Commands
  11. 13:41Debugging
  12. 15:50Hands-on Demo
  13. 21:18Cassandra Database
  14. 34:44Create Cassandra State Forces
  15. 38:25Create Deployment and Service
  16. 52:52Installation
  17. 53:03How To Install Applications Better on Kubernetes
  18. 53:44Operator
  19. 58:07So You Should Probably Make Sure that They Spread Evenly across the Cluster Kubernetes Has a Concept for that Called Anti Affinity and It Can Also Help You To Spread the Path of Cassandra across Different Data Centers or Different Availability Zones so We Should Plan Ahead and Well I Hope Is the Last One It's Security Currently the Our Cassandra Ports Were Not Secure At All You Can Connect to It Just Knowing Its Ip Address They Will Not Know Username Password You Can Add Usernames Passwords Certificates or Whatever Easily It's Not the Different from Bell Metro
  20. 59:11And They Can Get inside the Container and if They Find some Security Issue and Security Fees Happen They Can Probably Escape the Container and Get to Other Processes on the Machine and Maybe They Can Get to My Database with Credit Card Numbers Instead Is this What I'M Going To Risk or Should I Do Something Better for Example I Can Dedicate some Nodes Just for the Database So All that You Should Consider before Deploying Anything Stateful in Kubernetes because It May Behave Completely Differently than Environmental Case
  21. 1:03:36Could You Describe What Happens When a Node Fails What's Supposed To Happen to the Peavey's That Are Attached to that Node so the Question Was What Happens to the Storage When the Node Fails Storage Storage You Can Remember What Is My Cloud Thingy You May Remember that I Skill I Scale the Cassandra'up and Scale It Down So I Have I Have Three Pots in My Cluster but Come on Get Pvc I Still Have Four Participant Claims What Kubernetes Does It Deletes the Pots but It Does Not Delete the Claims
  22. 1:05:26So if You Configure Your Cluster Correctly and You Bring Up Your Plot Your Workload That Uses that Storage Somewhere Else You'Re Actually Able To Then Attach to that Network Storage Again and Just Continue Using It Does that Answer Your Question this in Our Example on Google the Storage Is Somewhere in the Cloud Is Not on the Note so What Google Does Is Just Attaches the Storage to Different Note and Starts a Put There That's Easy in Kubernetes We Also Have Local Storage Which Where You Can Use Nodes That Are Attached That Are Physically on the Main on the Nodes but Then if the Node Goes Down Your Storage Goes Down Too so You Should Use some Storage Back-End That Does some Replication or Crowd or Something like that Right this Brings Up a Really Good Point that Choosing Your Storage Back-End Is Really Important Right like if Four Different Resiliency Needs You Can Choose Different Backends Right if You Use a Local if You Use Local Disk on a Node
  23. 1:10:3713 We Have Resize as Offline Resizes Beta so this Is a Thing That You Can Do Right Now Your Of Course Your Storage Back-End Has To Support It As Well but I Believe the Way You Interact with It Is Just by Changing the Size on Your Pv or Pvc What You Should Look Up the Documentation for this but You Change the Size on It and if Your Storage Back-End Supports It That Will Just Kick Off the Whole Process for Resizing Yeah and and another Plug Is We'Re Actually Working on Online Resize As Well
  24. 1:10:51The Size on Your Pv or Pvc What You Should Look Up the Documentation for this but You Change the Size on It and if Your Storage Back-End Supports It That Will Just Kick Off the Whole Process for Resizing Yeah and and another Plug Is We'Re Actually Working on Online Resize As Well So Offline Resizes while Your Workload Is Using the Pv You Can't Resize It You'Ll Have To Bring Your Workload Down First but Currently in Kubernetes We'Re Working on Online Resize As Well so if Your Storage Back-End Supports It and Your File System Supports It You'Ll Be Able To Resize Your Volumes on the Fly So in this Example I Can Like Resize the Pvc from 5 from 0 to 5
  25. 1:11:17You Can't Resize It You'Ll Have To Bring Your Workload Down First but Currently in Kubernetes We'Re Working on Online Resize As Well so if Your Storage Back-End Supports It and Your File System Supports It You'Ll Be Able To Resize Your Volumes on the Fly So in this Example I Can Like Resize the Pvc from 5 from 0 to 5 Why Well It Was Allowed that Means the Third Mission Plug-In Is Not There Right All Right Are There any Other Questions on the Floor I Think John Is Trying To Demonstrate Resize no no He's Not You Have a Disabled in Your Posture Yeah I Have a Disabled but You Just editable His Pvc and that's It
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.