Install kubectl on Ubuntu 22.04 using bash
Getting started with Kubernetes you will need
kubectl command line tool.
1. Install kubectl binary
This command will bring down the latest version.
If you want a specific version do:
Validate the binary
You should validate your download by using the checksum file, get it here:
Validate the kubectl binary agains the checksum file:
If ok it should output:
If it failed for some reason
sha256 exits with nonzero status and outputs:
kubectl: FAILED sha256sum: WARNING: 1 computed checksum did NOT match
Check you URL and try again.
3. Finally Install kubectl
Command downloads the binary to you local bin to a folder called
kubectl with the required permissions.
✅ Owner can read
✅ Owner can write
✅ Owner can execute
✅ Group can read
❌ Group can't write
✅ Group can execute
✅ Others can read
❌ Others can't write
❌ Others can execute
4. Check to ensure all went well