Ever gotten a "
besu command not found" on your terminal? Well, read on...
Although there are many ways to install software on a Linux machine, an accepted startard practice is to install on your Linux user's
The following will help you install Hyperledger Besu on Ubuntu, and can be tweaked to many other distributions.
The Java JDK is a requirement for running Besu. Make sure its already installed and higher than version 11 by typing
java --version. If it isn't installed, follow these install instructions or type
sudo apt install default-jdk into the terminal.
Download the latest binary from a trusted website (ie. the PegaSys website).
If it doesn't exist, make the home
cd ~ mkdir bin
- Move the binary to the bin folder. Remember to replace <binary-filename> with the name of the file you've downloaded from step 1.
cd ~ cd Downloads mv <binary-filename> ~/bin
- Untar/unzip the downloaded binary. Depending on which file type you've downloaded, choose the extraction type.
If not present in your system, install unzip with
sudo apt-get install unzip.
cd ~ cd bin tar xf <binary-filename>.tar.gz
cd ~ cd bin unzip <binary-filename>.zip
- Rename the folder to
You may now remove the original tar/zip file.
mv <besu-version>/ besu
Your bin folder should look like this now:
~/tmp/bin $ tree -L 2 . └── besu ├── bin ├── lib ├── LICENSE └── license-dependency.html
- Add Besu to your PATH environment variable. Adding a binary to your PATH allows you to run the executable from any folder on your machine, without having to point to it directly at each call.
Using your text editor of choice, add the following line to your
.zshrc, etc) file.
- Restart your terminal.
You should now be able to run Besu from any folder, open a terminal window and type
besu -h and you will get the besu help output in the terminal.
Get more information on Besu here: