confluentinc / confluentinc/cli

CLI-3562: Error: update client failure: error updating CLI binary

Open
#1,896 6 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Go
Stars
80
Forks
35
Avg merge
2d 10h
Merged PRs (30d)
33

Description

I'm seeing the following error when trying to update confluent locally on Apple M1 using macOS 13.3.1 (a) (Ventura):

```zsh
➜ confluent update
Checking for updates...
New version of confluent is available
Current Version: v3.11.0
Latest Version: v3.12.0
[5/4/2023] Confluent CLI v3.12.0 Release Notes
==============================================

New Features
------------
- Add `--topics` flag to `confluent asyncapi export` to only export specified topics

Do you want to download and install this update? (y/n): y
Downloading confluent version 3.12.0...
Done. Downloaded 43.31 MB in 1 seconds. (32.41 MB/s)
Error: update client failure: error updating CLI binary: unable to copy /var/folders/0_/nkh8mcg92pq1fft8mrzcg98w0000gn/T/confluent3475877262/confluent-v3.12.0-darwin-arm64 to /usr/local/bin/confluent: remove /usr/local/bin/confluent: permission denied

Suggestions:
Please submit a support ticket.
In the meantime, see link for other ways to download the latest CLI version:
https://docs.confluent.io/current/cli/installing.html
```

However, I'm not seeing the issue Intel macOS 11.7.6 (Big Sur):

```zsh
➜ confluent update
Checking for updates...
New version of confluent is available
Current Version: v3.11.0
Latest Version: v3.12.0
[5/4/2023] Confluent CLI v3.12.0 Release Notes
==============================================

New Features
------------
- Add `--topics` flag to `confluent asyncapi export` to only export specified topics

Do you want to download and install this update? (y/n): y
Downloading confluent version 3.12.0...
Done. Downloaded 45.67 MB in 3 seconds. (14.25 MB/s)
```

In short, one needs do `sudo confluent update` instead `confluent update`. Thus, I believe that the `confluent` binary executable should invoke `sudo` in such situations.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.