Error: The brew link step did not complete successfully The formula built, but is not symlinked into /usr/local Could not symlink bin/kubectl

0 votes

Hi Guys,

I am trying to upgrade my kubectl, but it is showing me the below error.

$ brew upgrade kubectl
Updating Homebrew...
Auto packing the repository in background for optimum performance.
See "git help gc" for manual housekeeping.
==> Auto-updated Homebrew!
Updated 2 taps (homebrew/core and homebrew/cask)
==> Pouring kubernetes-cli-1.17.3.mojave.bottle.tar.gz
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink bin/kubectl
Target /usr/local/bin/kubectl
already exists. You may want to remove it:
rm '/usr/local/bin/kubectl'To force the link and overwrite all conflicting files:
brew link --overwrite kubernetes-cliTo list all files that would be deleted:
brew link --overwrite --dry-run kubernetes-cli
May 19 in Kubernetes by akhtar
• 25,210 points
275 views

1 answer to this question.

0 votes

Hi@akhtar,

You may get this error because of older kubectl version. It is conflicting with newer version. You can use the below given command to avoid this conflict.

$ brew link --overwrite kubernetes-cli

Hope this will help.

answered May 19 by MD
• 56,940 points

Related Questions In Kubernetes

0 votes
2 answers

Error saying “Error from server (NotFound): the server could not find the requested resource”

official Documentation says: A client should be skewed ...READ MORE

answered Sep 19, 2018 in Kubernetes by Nilesh
• 6,980 points
2,458 views
0 votes
1 answer

Error saying "the program 'curl' is currently not installed"

Install curl using this command: apt-get update && ...READ MORE

answered Nov 23, 2018 in Kubernetes by Hannah
• 18,410 points
209 views
0 votes
1 answer

Error from server (NotFound): the server could not find the requested resource

Hi@akhatr, The following error might indicate that something ...READ MORE

answered Jul 15 in Kubernetes by MD
• 56,940 points
201 views
0 votes
1 answer

Error saying "The specified bucket does not exist" in kubernetes

Bucket is created in another region. Looks like ...READ MORE

answered Aug 31, 2018 in Kubernetes by Kalgi
• 51,950 points
1,834 views
0 votes
1 answer

permissions related to AWS ECR

if you add allowContainerRegistry: true, kops will add those permissions ...READ MORE

answered Oct 9, 2018 in Kubernetes by Kalgi
• 51,950 points
142 views
+1 vote
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17, 2019 in Others by anonymous
8,384 views
0 votes
1 answer

kubectl info: exec: fork/exec /usr/local/bin/kubectl: exec format error

Hi@akhtar, The most common reason for this error ...READ MORE

answered May 19 in Kubernetes by MD
• 56,940 points
331 views
0 votes
1 answer