Skip to content
tezvyn:

All bites

The whole library, newest first. Filter by what you are here for, or pick a topic if you already know.

4330 bites

Page 38

Docker & Kubernetes1 min read

How do Sealed Secrets enable GitOps for secrets?

Kubeseal encrypts a Secret with the controller's public key into a SealedSecret CR safe for Git; only the in-cluster controller's private key can decrypt it into a real Secret.

Docker & Kubernetes1 min read

What are PersistentVolumes and PersistentVolumeClaims for?

A PV is a cluster storage resource the admin provisions; a PVC is a user's request for size and access mode; Kubernetes binds them, decoupling Pods from storage details.

Docker & Kubernetes1 min read

What happens to volume data when a Pod is deleted?

EmptyDir is tied to the Pod and erased when the Pod is deleted; a PVC-backed PV with Retain keeps the data after the PVC is released for manual recovery.

Docker & Kubernetes1 min read

Bind mounts vs named volumes for persisting Docker data?

Persist data outside the writable container layer via a bind mount (a host path you control) or a named volume (Docker-managed under its data dir, portable and the recommended default).

Docker & Kubernetes1 min read

StatefulSet vs Deployment: what's the difference?

Deployments treat Pods as interchangeable; StatefulSets give stable ordinal names, stable per-Pod storage via volumeClaimTemplates, and ordered rollout.

Docker & Kubernetes1 min read

What is a StorageClass and dynamic provisioning?

A StorageClass names a provisioner and parameters; a PVC referencing it triggers on-demand PV creation, so admins do not pre-create volumes.

Docker & Kubernetes1 min read

What do PersistentVolume accessModes mean?

RWO mounts read-write by one node, ROX read-only by many nodes, RWX read-write by many nodes; block storage usually only supports RWO while shared filesystems enable RWX.

Docker & Kubernetes1 min read

How does a StatefulSet give stable identity and storage?

Ordinal Pod names plus a headless Service yield stable per-Pod DNS; volumeClaimTemplates give each ordinal its own persistent PVC that follows it on reschedule.

Docker & Kubernetes1 min read

Why is a Pod with a PVC stuck Pending?

PVC may be unbound from missing StorageClass, no matching PV, mismatched access mode or size, zone or capacity limits, or WaitForFirstConsumer; diagnose with describe on Pod and PVC plus events.

Docker & Kubernetes1 min read

How does a StatefulSet recover a Pod after node failure?

Node goes NotReady, Pod is marked for deletion, the same-ordinal Pod is recreated and reattaches its existing PVC from volumeClaimTemplates, preserving data; safety needs the old Pod confirmed…

Docker & Kubernetes1 min read

How do you resize a live PersistentVolume?

Edit the PVC's requested size upward; the StorageClass must set allowVolumeExpansion true and the CSI driver must support expansion, ideally online so no Pod restart is needed; shrinking is not allowed.

Docker & Kubernetes1 min read

Requests vs limits for CPU and memory?

Requests guide scheduling and reservation, limits cap usage; exceeding a CPU limit throttles the container, while exceeding a memory limit triggers an OOMKill since memory is incompressible.

Docker & Kubernetes1 min read

How do you pin a Pod to nodes with a given label?

The simplest tool is nodeSelector, a key-value map in the Pod spec requiring matching node labels; node affinity is the richer alternative for complex rules.

Docker & Kubernetes1 min read

How do you stop new Pods scheduling on a node?

Kubectl cordon marks the node unschedulable so no new Pods land, while existing Pods keep running; drain is the follow-up that also evicts them.

Docker & Kubernetes1 min read

What are the three Pod QoS classes?

Guaranteed when every container sets equal requests and limits for CPU and memory; Burstable when requests are set but not matching limits; BestEffort when none are set; lower classes are evicted first under…

Docker & Kubernetes1 min read

Required vs preferred node affinity rules

Required is a mandatory filter, preferred is a weighted preference, and IgnoredDuringExecution means rules apply only at scheduling time.

Docker & Kubernetes1 min read

Spreading replicas across availability zones

Use topologySpreadConstraints on topology.kubernetes.io/zone with a small maxSkew, choose DoNotSchedule or ScheduleAnyway, and confirm nodes carry zone labels.

Docker & Kubernetes1 min read

Taints and tolerations versus node affinity

Taints repel pods from nodes (reserve hardware), affinity attracts pods to nodes, and you combine both so only tolerating pods land AND only those pods seek the node.

Docker & Kubernetes1 min read

Pinning exclusive CPU cores to a pod

Set kubelet CPU Manager policy to static, make the pod Guaranteed QoS with integer CPU limits equal to requests, so it gets exclusive dedicated cores.

Docker & Kubernetes1 min read

tolerationSeconds and graceful eviction on NoExecute

TolerationSeconds is how long a tolerating pod may stay after the taint applies; once it elapses eviction starts, then terminationGracePeriodSeconds governs the SIGTERM-to-SIGKILL window.