0Pricing
MLOps Academy · Lektion

CPU, Arbeitsspeicher und GPU anfordern

Legen Sie Ressourcenlimits fest, damit Pods korrekt eingeplant werden.

CPU, Arbeitsspeicher und GPU anfordern ist eine kostenlose MLOps Academy-Lektion auf CoddyKit. Dies ist Lektion 2 von 4. Du kannst die komplette Lektion unten kostenlos lesen – dann übst du sie direkt im Browser mit einem integrierten Code-Editor und einem KI-Tutor rund um die Uhr. Sie ist Teil des MLOps Academy-Lernpfads, und dein Fortschritt wird über Web und CoddyKit-App synchronisiert. Der MLOps Academy-Kurs umfasst insgesamt 4 Lektionen.

Teile dieser Lektion wurden noch nicht übersetzt und werden auf Englisch angezeigt.

The Scheduler Needs Numbers

Kubernetes places Pods onto nodes that have room. To decide, the scheduler needs you to declare how much CPU and memory each model Pod will use.

Requests vs Limits

A request is the amount guaranteed and used for scheduling. A limit is the ceiling a container may not cross. You almost always set both.

CPU Is Measured in Millicores

CPU is counted in millicores: 1000m equals one full core. Asking for 500m means your model Pod is promised half of one CPU core.

resources:
  requests:
    cpu: "500m"
    memory: "512Mi"
  limits:
    cpu: "1"
    memory: "1Gi"

Memory Uses Mi and Gi

Memory is set in mebibytes or gibibytes, like 512Mi or 2Gi. Size it to your model plus its runtime, with a little headroom on top.

Too Low and the Pod Stays Pending

If no node can satisfy your requests, the Pod sits in Pending forever. Big GPU models often wait simply because nothing free is large enough.

OOMKilled When You Exceed Memory

Cross your memory limit and the kernel kills the container with an OOMKilled status. Right-sizing limits keeps your model server from being reaped mid-request. 💥

CPU Limits Throttle, Not Kill

Unlike memory, breaching a CPU limit does not kill the Pod. The container is just throttled, so latency climbs instead of the process dying.

GPUs Are Requested as Limits

GPUs are an extended resource. You ask for them only under limits with nvidia.com/gpu, and the value must be a whole number, never a fraction.

resources:
  limits:
    nvidia.com/gpu: 1

A GPU Is Not Time-Shared

One GPU request grabs the entire device for that Pod by default. Two Pods cannot casually share a card without special MIG or time-slicing setup.

The Device Plugin Makes GPUs Visible

Nodes only advertise GPUs after the NVIDIA device plugin runs on them. No plugin, no nvidia.com/gpu resource, and your GPU Pod stays Pending.

Right-Sizing Saves Money

Over-requesting wastes whole nodes; under-requesting risks evictions. Watching real usage and tuning requests is how you keep serving both stable and cheap.

Quick Check

What happens when a container exceeds its memory limit?

Recap

Declare requests and limits for CPU and memory, ask for whole GPUs under limits, and right-size from real usage to keep model Pods healthy. ✅

Häufig gestellte Fragen

Ist die Lektion „CPU, Arbeitsspeicher und GPU anfordern“ kostenlos?

Ja — der vollständige Text von „CPU, Arbeitsspeicher und GPU anfordern“ ist hier im Web kostenlos zu lesen. Um sie interaktiv zu üben (integrierter Code-Editor und 24/7 KI-Tutor) und den Rest des MLOps Academy-Kurses freizuschalten, upgrade auf CoddyKit PRO. Der MLOps Academy-Kurs umfasst insgesamt 4 Lektionen.

Was lerne ich in „CPU, Arbeitsspeicher und GPU anfordern“?

Legen Sie Ressourcenlimits fest, damit Pods korrekt eingeplant werden. Du übst MLOps Academy mit praktischem Code, den du direkt im Browser ausführst, und ein 24/7 KI-Tutor beantwortet deine Fragen während du die Lektion bearbeitest.

Brauche ich Erfahrung, um MLOps Academy zu starten?

Keine Vorkenntnisse erforderlich. MLOps Academy auf CoddyKit ist für Anfänger bis fortgeschrittene Lernende strukturiert, sodass du hier starten oder von Anfang an beginnen und in deinem eigenen Tempo voranschreiten kannst. Dies ist Lektion 2 von 4.

Wie lange dauert die Lektion „CPU, Arbeitsspeicher und GPU anfordern“?

Die meisten CoddyKit-Lektionen dauern etwa 5–10 Minuten. Jede ist kompakt und interaktiv, sodass du stetig Fortschritte machst und genau dort weitermachst, wo du aufgehört hast – im Web und in der App.

Kann ich in dieser MLOps Academy-Lektion Code schreiben und ausführen?

Ja. Jede MLOps Academy-Lektion enthält einen integrierten Code-Editor, sodass du echten Code direkt in deinem Browser schreibst und ausführst und sofort KI-Feedback erhältst — ohne lokale Einrichtung erforderlich.

Alle Lektionen in diesem Kurs

  1. Pods, Deployments und Services für Modelle
  2. CPU, Arbeitsspeicher und GPU anfordern
  3. Mit ConfigMaps und Secrets konfigurieren
  4. Training als Kubernetes-Job ausführen
← Zurück zu MLOps Academy