Real-Time OpenShift Troubleshooting Questions (2027)

40 real-time OpenShift troubleshooting questions with answers: oc logs, oc debug node, must-gather, ClusterOperators, SCCs and on-call scenarios.

Sep 13, 2025 - 11:17
Nov 7, 2026 - 09:45
 0  69
TOPICInterview Q & APractical guide
Real-Time OpenShift Troubleshooting Questions (2027)

Real-time OpenShift interview questions put you in front of a live cluster problem and watch how you work it: which oc command you run first, what you read in the output, and when you escalate. This page has 40 troubleshooting questions with short answers, grouped by experience level, plus a set of on-call scenarios.

For definitions and architecture basics, start with our 120+ OpenShift interview questions guide. This page assumes you know what a pod, route and Operator are, and focuses on what you type when something is broken. Commands were checked against the Red Hat OpenShift Container Platform 4 and OKD documentation in November 2026.

Key takeaways

  • Interviewers care about order. Check cluster health (oc get clusterversion, oc get clusteroperators) before you blame a workload.
  • For pods, the sequence is oc get pods, oc describe pod, oc logs (with --previous after a restart), then events.
  • For nodes, Red Hat recommends oc debug node/<name> followed by chroot /host and oc adm node-logs, with SSH only when the API is down.
  • oc adm must-gather collects the data Red Hat Support usually asks for. Mention it whenever a case may need a support ticket.
  • Senior answers add prevention: alerts, quotas, PodDisruptionBudgets, MachineConfigPool pauses and a written runbook.

How this page differs from the other OpenShift guides

GuideBest for
120+ OpenShift interview questionsConcepts and broad coverage
Scenario-based OpenShift questionsDesign and decision scenarios
OpenShift administration questionsDay-2 admin tasks
This pageLive troubleshooting with oc, command by command

A first-five-minutes checklist

Many interviewers open with "the app is down, you have the terminal, go." A calm answer follows the same order every time:

oc whoami; oc project                 # confirm identity and namespace
oc get clusterversion                 # is an upgrade running or failing?
oc get clusteroperators               # any Degraded=True or Available=False?
oc get nodes                          # NotReady or SchedulingDisabled nodes
oc get pods -o wide                   # workload status and placement
oc get events --sort-by=.lastTimestamp | tail -20

Saying this out loud shows you separate platform problems from application problems before you start changing things.

Freshers (questions 1 to 14)

1. A pod shows CrashLoopBackOff. What do you run first?

Run oc logs <pod> --previous to read the output of the container that crashed, then oc describe pod <pod> for the exit code and last state. Exit code 137 usually points to an OOM kill or a failed liveness probe; exit code 1 is normally an application error.

2. Why does oc logs show nothing for a crashing pod?

Without --previous you see the current container, which may have just started and printed nothing yet. Add --previous, and for multi-container pods add -c <container>.

3. A pod is stuck in Pending. Where do you look?

The Events section of oc describe pod. The scheduler states why: insufficient CPU or memory, a node selector or taint with no matching node, or an unbound PersistentVolumeClaim.

4. What does ImagePullBackOff mean and how do you fix it?

The kubelet cannot pull the image. Check the image name and tag in the events, then whether the registry needs a pull secret linked to the service account (oc secrets link default <secret> --for=pull) and whether the node can reach the registry.

5. Your container fails with "permission denied" writing to a directory. Why does this happen on OpenShift more than on plain Kubernetes?

OpenShift runs containers under the restricted-v2 SecurityContextConstraint by default, with an arbitrary non-root UID. Images that expect to run as root or write to root-owned paths fail. The fix is in the image: make writable paths group-owned by root (GID 0) and group-writable, rather than granting a privileged SCC.

6. How do you open a shell inside a running pod?

oc rsh <pod>, or oc rsh -c <container> pod/<pod> for a specific container. Red Hat's docs note that oc rsh does not accept -n, so switch project first with oc project.

7. How do you debug a pod that crashes too fast to rsh into?

Use oc debug pod/<pod> or oc debug deployment/<name>. It starts a copy of the pod with a shell instead of the normal entrypoint, so you can inspect files, environment and mounts.

8. A route returns "Application is not available". What is wrong?

The router reached no healthy endpoint. Check that the route points to the right service (oc get route -o yaml), that the service selector matches pod labels (oc get endpoints <svc>), and that pods pass their readiness probes.

9. How do you test a service from inside the cluster?

Start a short-lived pod or use oc rsh into an existing one and call curl http://<svc>.<namespace>.svc:<port>. If that works but the route does not, the problem is at the router or route level.

10. How do you check recent events in a namespace?

oc get events --sort-by=.lastTimestamp. Events expire, so read them early in an incident.

11. A build fails in OpenShift. Where are the logs?

oc logs build/<build-name> or oc logs -f bc/<buildconfig> for the latest build. Common causes are a wrong Git URL or secret, a failing dependency download, or a base image that cannot be pulled.

12. How do you forward a pod port to your laptop for testing?

oc port-forward <pod> 8080:8080. Press Ctrl+C to end the session. It bypasses services and routes, which helps isolate where traffic breaks.

13. How do you see resource usage of pods?

oc adm top pods and oc adm top nodes, which read from the cluster metrics stack. The web console's Observe section shows the same data over time.

14. What is the quickest way to check if a deployment rollout is stuck?

oc rollout status deployment/<name>. If it hangs, compare old and new ReplicaSets with oc get rs and describe the new pods to see why they are not becoming ready.

2 to 5 years (questions 15 to 28)

15. oc get clusteroperators shows one operator Degraded. What next?

Run oc describe clusteroperator <name> and read the Degraded condition message. It names the failing component. Then check pods in the operator's namespace (for example openshift-ingress-operator) and their logs.

16. What do the Available, Progressing and Degraded conditions mean on a ClusterOperator?

Available means the component works. Progressing means it is rolling out a change. Degraded means it is not in its desired state. During an upgrade Progressing is normal; Degraded for a long time is not.

17. A node is NotReady. How do you investigate without SSH?

Start with oc describe node <node> for conditions such as MemoryPressure or DiskPressure. Then run oc debug node/<node> and chroot /host to use host tools, and read kubelet logs with oc adm node-logs <node> -u kubelet. Use SSH only if the API itself is unavailable.

18. How do you read CRI-O logs on a node?

oc adm node-logs <node> -u crio. The OKD troubleshooting docs suggest this when a debug shell cannot start on the node.

19. When would you run oc adm must-gather?

When the issue may need Red Hat Support or a deeper offline review. It collects cluster resource definitions, operator logs and other debug data into a local directory. Use --image to collect data for a specific add-on, such as storage or logging operators.

20. How do you collect data for a single namespace instead of the whole cluster?

oc adm inspect ns/<namespace> gathers resources and logs for that namespace. It is lighter than a full must-gather.

21. A PersistentVolumeClaim stays Pending. What do you check?

Check the StorageClass named in the claim exists and has a working provisioner (oc get storageclass), the requested access mode is supported (RWX is not available on many block storage drivers), and the CSI driver pods in their namespace are healthy. With WaitForFirstConsumer, the claim stays Pending until a pod uses it, which is expected.

22. Pods cannot resolve service names. How do you narrow it down?

From inside a pod, check /etc/resolv.conf and try resolving a service FQDN. Then check the DNS operator (oc get clusteroperator dns) and the pods in openshift-dns. Also check whether a NetworkPolicy blocks egress to DNS.

23. Traffic between two namespaces stopped after a security change. What is the likely cause?

A NetworkPolicy. Once any policy selects a pod, traffic not explicitly allowed is denied. List policies with oc get networkpolicy -n <ns> on both sides and look for a default-deny without a matching allow rule.

24. A deployment is OOMKilled repeatedly. How do you decide between a limit increase and a code fix?

Compare actual usage over time in the metrics console with the configured limit. If usage climbs steadily until the kill, suspect a memory leak and involve developers. If usage sits near a too-tight limit under normal load, raise the limit and request together, and check the namespace ResourceQuota allows it.

25. A pod is blocked from starting by an SCC error. How do you find which SCC applied?

Look at the openshift.io/scc annotation on a running pod, or the admission error in the ReplicaSet events. To check what a service account may use, run oc adm policy who-can use scc <name>. Fix the workload before granting a broader SCC.

26. An Operator installed from OperatorHub is stuck installing. What do you check?

Check the Subscription (oc get subs), the InstallPlan (oc get installplan, which may need manual approval), the ClusterServiceVersion phase (oc get csv) and the CatalogSource pod health in openshift-marketplace.

27. A cluster upgrade is stuck. Where do you look first?

oc get clusterversion and oc describe clusterversion for the failing step, then oc get clusteroperators to see which operator has not finished. Nodes updating through the Machine Config Operator show progress in oc get mcp.

28. Two pods on the same node cannot reach the internet, but other nodes are fine. What do you suspect?

A node-level network issue: the node's egress path, its OVN-Kubernetes components, or a host firewall change. Compare with a debug pod on a healthy node, then check the network operator status and the node's network pods.

Senior (questions 29 to 34)

29. How do you run an incident on OpenShift so evidence is not lost?

Capture first, change second. Save events, describes and logs (or run oc adm inspect) before restarting anything, because restarts and event expiry remove the evidence. Keep a timeline in the incident channel.

30. A MachineConfig change is about to roll out to all workers. How do you limit risk?

Pause the MachineConfigPool (spec.paused: true), test the change on a separate custom pool with a few nodes, then unpause the main pool. Tune maxUnavailable so capacity stays above what workloads need, and make sure PodDisruptionBudgets exist for critical apps.

31. How do you stop one team's runaway workload from hurting others?

Use ResourceQuotas and LimitRanges per project so defaults exist and totals are capped. Combine them with priority classes for platform components. Then alert on quota usage so teams hear about it before the scheduler refuses pods.

32. The etcd cluster reports high latency. What do you check and who do you involve?

Check the etcd operator status and the etcd disk and network latency metrics on control plane nodes. Slow storage under etcd is a common cause. Red Hat documents disk performance requirements for etcd, so involve the infrastructure team for storage before touching etcd itself, and open a support case early with must-gather data.

33. How do you decide whether to roll back an application or fix forward during an outage?

Roll back when the last change is the clear trigger and rollback is tested (oc rollout undo deployment/<name> or a Git revert under GitOps). Fix forward only when rollback is riskier, for example after a schema migration. State this rule before the incident in the runbook.

34. What would you add after an incident so the same issue is caught earlier?

An alert on the symptom users felt (error rate or latency on the route), a dashboard panel for the cause, a runbook entry with the exact commands used, and a ticket for the root cause fix. Interviewers look for this habit in senior candidates.

On-call scenarios (questions 35 to 40)

35. Scenario: after a deploy, half of the requests return 503.

Check endpoints for the service. Likely only some pods are ready, or a new ReplicaSet has pods failing readiness. Compare old and new pods with oc get pods -l app=<name> -o wide, read probe failures in describe output, and roll back if the new version is at fault.

36. Scenario: the web console is unreachable but oc works.

Check the console and ingress cluster operators, the console pods in openshift-console, and the router pods in openshift-ingress. A certificate problem on the default ingress controller can also break the console route.

37. Scenario: a worker node keeps going NotReady every few hours.

Collect kubelet and CRI-O logs with oc adm node-logs around the failure times and check DiskPressure or MemoryPressure conditions. Look for a noisy pod filling the disk with logs or images. Cordon and drain the node (oc adm cordon, oc adm drain) while you investigate.

38. Scenario: builds started failing for every team at once.

Something shared changed: the internal image registry, a proxy, an expired pull secret, or a base image tag. Check the image-registry cluster operator, cluster-wide proxy settings, and one build log in detail before touching individual BuildConfigs.

39. Scenario: a stateful database pod will not start after a node failure.

The volume may still be attached to the failed node. Check the VolumeAttachment and the PVC events. Confirm the old node is really down before forcing anything, because two writers on one volume can corrupt data. Follow the storage vendor's documented recovery steps.

40. Scenario: an interviewer asks what you would never do on a production cluster during an incident.

Grant cluster-admin or a privileged SCC to make an error go away, delete etcd members or operator-managed resources by hand, or restart everything before collecting logs. Each one hides the cause or creates a second incident.

How to practise these questions

Reading answers is not enough for troubleshooting rounds. Break things on purpose in a lab and fix them while talking through your steps:

  1. Set up OpenShift Local (formerly CodeReady Containers) or an OKD lab cluster.
  2. Deploy a sample app with a route, then break it: wrong image tag, bad service selector, a tight memory limit, a default-deny NetworkPolicy.
  3. For each break, write the commands you used and the line of output that told you the cause.
  4. Run oc adm must-gather once so you know what it produces.

If you want a guided lab environment, our OpenShift training in Pune runs in the Kharadi classroom and live online. Kubernetes fundamentals help too; see the advanced OpenShift interview questions for deeper platform topics.

FAQ

What does "real-time OpenShift interview questions" mean?

Questions based on live production problems, where you explain what you would check and in what order. Interviewers often give a symptom, such as a 503 on a route, and ask you to talk through the commands.

Which oc commands should I know by heart for troubleshooting?

oc get, oc describe, oc logs --previous, oc get events, oc rsh, oc debug, oc adm top, oc adm node-logs, oc get clusteroperators and oc adm must-gather.

Is SSH to nodes allowed in OpenShift 4?

It is possible, but Red Hat recommends oc debug node and oc adm node-logs first and SSH only when the API is not working.

What is must-gather used for?

It collects cluster data that is most often needed to debug problems, and Red Hat Support usually asks for it when you open a case.

Why do images that work in Docker fail on OpenShift?

OpenShift runs containers as a random non-root UID under the restricted-v2 SCC by default. Images that need root or write to root-owned paths fail until they are made group-writable for GID 0.

How can I practise OpenShift troubleshooting for free?

Use OpenShift Local or an OKD cluster in a lab, deploy a sample app and break it in controlled ways, then fix each fault while noting the commands you used.

Official references

Interested in learning more?Get a callback from our training advisors.

What's Your Reaction?

Like Like 0
Dislike Dislike 0
Love Love 0
Funny Funny 0
Angry Angry 0
Sad Sad 0
Wow Wow 0
Mridul I am a passionate technology enthusiast with a strong focus on DevOps, Cloud Computing, and Cybersecurity. Through my blogs at DevOps Training Institute, I aim to simplify complex concepts and share practical insights for learners and professionals. My goal is to empower readers with knowledge, hands-on tips, and industry best practices to stay ahead in the ever-evolving world of DevOps.