I set up a small Kubernetes cluster for testing, and for storage I use glusterfs. No CSI, I just create the volumes manually for now.
Now, I added a Windows node to the cluster. It works fine so far, but I can't get any volumes to mount in the container.
I did a very simple pod definition:
--- apiVersion: v1 kind: Pod metadata: name: windows-test labels: name: windows-test spec: containers: - name: sample image: mcr.microsoft.com/windows/servercore:ltsc2019 resources: limits: cpu: "1.0" memory: "1Gi" command: - cmd - "/c" - "dir" - "/s" - 'c:\' volumeMounts: - mountPath: "foo" name: testvol nodeSelector: "kubernetes.io/os": windows volumes: - name: testvol glusterfs: path: wintest endpoints: glusterfs-cluster readOnly: false
When I run this, the pod never starts and when I describe it, I get:
Warning FailedMount <invalid> kubelet, node09 MountVolume.SetUp failed for volume "testvol" : mount failed: only cifs mount is supported now, fstype: "glusterfs", mounting source ("10.93.111.35:wintest"), target ("c:\\var\\lib\\kubelet\\pods\\6d207138-09fb-4e1f-86e7-6a71cef5ce7e\\volumes\\kubernetes.io~glusterfs\\testvol"), with options (["auto_unmount" "backup-volfile-servers=10.93.111.31:10.93.111.32:10.93.111.33:10.93.111.34:10.93.111.35:10.93.111.36:10.93.111.37:10.93.111.38" "log-file=\\var\\lib\\kubelet\\plugins\\kubernetes.io\\glusterfs\\testvol\\windows-test-glusterfs.log" "log-level=ERROR"]), the following error information was pulled from the glusterfs log to help diagnose this issue: could not open log file for pod windows-test
It seems that Windows pods do not support glusterfs, but only "cifs". Can anyone guide me how to mount a volume via cifs? The only information I found in the docs was about the
azure-file storage but I couldn't figure out if that can also mount CIFS shares on-prem.