[BUG] Volume attachment related error logs in uninstaller pod #6197
Closed
Description
Describe the bug (🐛 if you encounter this issue)
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior:
- Install Longhorn 1.5.0-rc2
- Create a volume and attach it.
- Set deletion confirmation flag:
kubectl -n longhorn-system patch -p '{"value": "true"}' --type=merge lhs deleting-confirmation-flag
- Uninstall Longhorn using kubectl command
- Check the uninstaller pod logs, they have error like below
W0626 20:39:03.417023 1 reflector.go:533] github.com/longhorn/longhorn-manager/k8s/pkg/client/informers/externalversions/factory.go:117: failed to list *v1beta2.VolumeAttachment: volumeattachments.longhorn.io is forbidden: User "system:serviceaccount:longhorn-system:longhorn-uninstall-service-account" cannot list resource "volumeattachments" in API group "longhorn.io" at the cluster scope
E0626 20:39:03.417071 1 reflector.go:148] github.com/longhorn/longhorn-manager/k8s/pkg/client/informers/externalversions/factory.go:117: Failed to watch *v1beta2.VolumeAttachment: failed to list *v1beta2.VolumeAttachment: volumeattachments.longhorn.io is forbidden: User "system:serviceaccount:longhorn-system:longhorn-uninstall-service-account" cannot list resource "volumeattachments" in API group "longhorn.io" at the cluster scope
Expected behavior
Uninstaller should not have problem in getting/reading the volumeAttachment
Log or Support bundle
Environment
- Longhorn version: 1.5.0-rc2
- Installation method (e.g. Rancher Catalog App/Helm/Kubectl): kubectl
Metadata
Assignees
Labels
Type
Projects
Status
Closed