How to troubleshoot "could not detect velero" error

I’m trying to run “kubectl kots velero ensure-permissions” to inform KOTS where Velero is located on my cluster. However the command always returns:

Error: could not detect velero in ‘cluster-629e09268fb44b8f0499963a’ namespace

Kotsadm is installed in the “kots” namespace, Velero is installed in the “cluster-629e09268fb44b8f0499963a” namespace. The command I’m running is:

kubectl kots velero ensure-permissions --velero-namespace cluster-629e09268fb44b8f0499963a --namespace kots

I’ve looked at the checks here and added the “component” and “deploy” labels to the velero & restic pods, but this didn’t make a difference.
Is there any way to enable more verbose debugging output from “kubectl kots”, to figure out why it’s not detecting velero?

Hi Kevin!

Could you please validate that there is a backupstoragelocation object named default in the cluster-629e09268fb44b8f0499963a namespace?

Basically, check the output of the following command:

kubectl get bsl -n cluster-629e09268fb44b8f0499963a

The other thing I would recommend validating is that the user running the command should have access to the cluster-629e09268fb44b8f0499963a namespace.

Let me know if that helps.

Salah - Senior Software Engineer @ Replicated

1 Like

Ah indeed, ensuring a BSL called default exists, solves the problem. Thanks for the tip!

2 Likes