minikube: error: You must be logged in to the server (Unauthorized)
The exact command to reproduce the issue:
minikube start
kubectl get nodes
The full output of the command that failed:
error: You must be logged in to the server (Unauthorized)
The operating system version:
Ubuntu 18.04
I have deleted the cluster using minikube delete.
Cleared everything from the config:
kubectl config delete-context minikube
kubectl config delete-cluster minikube
kubectl config unset.users minikube
rm -rf ~/.kube/config
rm -rf ~/.minikube
Created a new cluster using minikube start
Yet - still get the same error.
Checking the config:
kubectl config view --minify | grep /.minikube | xargs stats
stat: cannot stat 'certificate-authority:': No such file or directory
File: /home/tomerle/.minikube/ca.crt
Size: 1066 Blocks: 8 IO Block: 4096 regular file
Device: 802h/2050d Inode: 9837419 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 1000/ tomerle) Gid: ( 1000/ tomerle)
Access: 2019-06-11 23:37:00.930257345 +0300
Modify: 2019-06-11 23:37:00.778257705 +0300
Change: 2019-06-11 23:37:00.778257705 +0300
Birth: -
stat: cannot stat 'client-certificate:': No such file or directory
File: /home/tomerle/.minikube/client.crt
Size: 1103 Blocks: 8 IO Block: 4096 regular file
Device: 802h/2050d Inode: 9837423 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 1000/ tomerle) Gid: ( 1000/ tomerle)
Access: 2019-06-11 23:38:13.242084809 +0300
Modify: 2019-06-11 23:37:01.410256208 +0300
Change: 2019-06-11 23:37:01.410256208 +0300
Birth: -
stat: cannot stat 'client-key:': No such file or directory
File: /home/tomerle/.minikube/client.key
Size: 1679 Blocks: 8 IO Block: 4096 regular file
Device: 802h/2050d Inode: 9837424 Links: 1
Access: (0600/-rw-------) Uid: ( 1000/ tomerle) Gid: ( 1000/ tomerle)
Access: 2019-06-11 23:38:13.242084809 +0300
Modify: 2019-06-11 23:37:01.410256208 +0300
Change: 2019-06-11 23:37:01.410256208 +0300
Birth: -
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 32 (5 by maintainers)
We were facing the similar issue. Deleting the http-cache helped. rm -rf ~/.kube/http-cache/*
I also reproduce it with minikube version: v1.6.2, running k8s 1.16.0 on ubuntu 18.04.
@CVirus Thanks for providing more info, we will look into it ! I am curious are you using a corporate network ?