Skip to content

Commit

Permalink
Merge pull request #79 from humblec/release-prep-5
Browse files Browse the repository at this point in the history
Add details about the debugging of the driver
  • Loading branch information
k8s-ci-robot committed Dec 18, 2021
2 parents 62a068d + 1b2f7a8 commit 21866af
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions docs/csi-debug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
## CSI driver debug tips

### Case#1: volume create/delete failed
-
- locate csi iscsi driver pod
```
kubectl get csidriver
NAME ATTACHREQUIRED PODINFOONMOUNT STORAGECAPACITY TOKENREQUESTS REQUIRESREPUBLISH MODES AGE
iscsi.csi.k8s.io false false false <unset> false Persistent 22m
```

- get csi driver logs
```
kubectl logs -f csi-iscsi-node-klh5c -c iscsi
I1217 14:40:55.928307 7 driver.go:48] Driver: iscsi.csi.k8s.io version: 1.0.0
I1217 14:40:55.928339 7 driver.go:89] Enabling volume access mode: SINGLE_NODE_WRITER
I1217 14:40:55.928347 7 driver.go:100] Enabling controller service capability: UNKNOWN
I1217 14:40:55.929521 7 server.go:107] Listening for connections on address: &net.UnixAddr{Name:"//csi/csi.sock", Net:"unix"}
I1217 14:40:55.956864 7 utils.go:63] GRPC call: /csi.v1.Identity/GetPluginInfo
I1217 14:40:55.956877 7 utils.go:64] GRPC request: {}
I1217 14:40:55.957869 7 identityserver.go:32] Using default GetPluginInfo
I1217 14:40:55.957874 7 utils.go:69] GRPC response: {"name":"iscsi.csi.k8s.io","vendor_version":"1.0.0"}
I1217 14:40:56.767355 7 utils.go:63] GRPC call: /csi.v1.Identity/GetPluginInfo
I1217 14:40:56.767375 7 utils.go:64] GRPC request: {}
I1217 14:40:56.767437 7 identityserver.go:32] Using default GetPluginInfo
I1217 14:40:56.767445 7 utils.go:69] GRPC response: {"name":"iscsi.csi.k8s.io","vendor_version":"1.0.0"}
```

#### Update driver version quickly by editing driver deployment directly
- update daemonset deployment
```console
kubectl get ds
NAME DESIRED CURRENT READY UP-TO-DATE AVAILABLE NODE SELECTOR AGE
csi-iscsi-node 1 1 1 1 1 kubernetes.io/os=linux 51m

kubectl edit daemmonset csi-iscsi-node
```
change below config, e.g.
```console
image: gcr.io/k8s-staging-sig-storage/iscsiplugin:canary
imagePullPolicy: IfNotPresent

```

```console
$ kubectl logs -f csi-iscsi-node-klh5c -c iscsi
```

0 comments on commit 21866af

Please sign in to comment.