Unable to execute anything inside pod when runsc used as runtimeclass

68 views
Skip to first unread message

anvitha haviligi

unread,
Apr 3, 2023, 8:57:09 AM4/3/23
to gVisor Users [Public]
Hi All,

Im unable to run anything inside pod when runsc is used as runtimeclass.

Setup details :
OS - centos7
kubernetes: "v1.22.5"

step1 : I have configured gvisor on centos7 following below link.

step2: created runtime class with below configuration
apiVersion: node.k8s.io/v1
kind: RuntimeClass
metadata:
  # The name the RuntimeClass will be referenced by.
  # RuntimeClass is a non-namespaced resource.
  name: gvisor
# The name of the corresponding CRI configuration
handler: runsc

Step3: created pod using above runtimeclass
apiVersion: v1
kind: Pod
metadata:
  labels:
    run: anvitest
  name: anvitest
spec:
  runtimeClassName: gvisor
  containers:
  - image: docker.io/praqma/network-multitool
    name: anvitest
    resources: {}
  dnsPolicy: ClusterFirst
  restartPolicy: Always

Container came to running state
kubectl get pods
NAME                                     READY   STATUS             RESTARTS           AGE
anvitest                                 1/1     Running            0                  19m

Step3: Tried logging to pod and executed few things, i see there is no output printing
kubectl exec -it anvitest  -- /bin/bash
bash-5.1# dmesg
bash-5.1# ls
bash-5.1# ps
ps: write error
bash-5.1#

Note: All above commands works without runtimeclass

Please help me what im doing wrong

Regards,
Anvitha

Fabricio Voznika

unread,
Apr 3, 2023, 8:57:03 PM4/3/23
to anvitha haviligi, gVisor Users [Public]
It seems like the RuntimeClass configuration worked fine given that your pod is up and running. Did you also install containerd-shim-runsc-v1? If not, you can follow the instructions here to install it: https://gvisor.dev/docs/user_guide/containerd/quick_start/. If you installed the shim and it still doesn't work, then please collect a full set of debug logs and attach them to a new Github issue. You can use this link to create one.

Thanks,
Fabricio.

--
You received this message because you are subscribed to the Google Groups "gVisor Users [Public]" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gvisor-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gvisor-users/e7852205-774b-488e-af46-c2f81d46282an%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages