How to Install Go on CentOS 8

How to Install Go on CentOS 8

Install Go on centos 8; Through this tutorial, we will learn how to install and configure Go or Golang in centOS 8.

How to Install Go on CentOS 8

Follow the following steps below to download and install Go on CentOS 8:

  • Step 1 – Download the Go binary
  • Step 2 – Verify the tarball checksum
  • Step 3 – Extract the tarball
  • Step 4 –  Set $PATH environment variable

Step 1 – Download the Go binary

First of all, open your terminal or command line and execute the following command into it to download the go binary libraries into centos 8:

wget https://dl.google.com/go/go1.13.4.linux-amd64.tar.gz

Step 2 – Verify the tarball checksum

Once the archive is downloaded, verify the tarball checksum by executing the following command on command line or terminal:

sha256sum go1.13.4.linux-amd64.tar.gz

Step 3 – Extract the tarball

Then execute the following command on command line to extract the tarball to the /usr/local directory:

sudo tar -C /usr/local -xf go1.13.4.linux-amd64.tar.gz

Step 4 –  Set $PATH environment variable

Finally, set the path environment variable for go or golang into centos 8 system.

So, we can do this by adding the following line to the /etc/profile file (for a system-wide installation) or to the $HOME/.bash_profile file (for a current user installation):

export PATH=$PATH:/usr/local/go/bin

Save the file, and load the new PATH environment variable into the current shell session using the source command:

source ~/.bash_profile

Conclusion

Now that we have downloaded and installed Go in centos 8.

Recommended CentOS Tutorials

AuthorAdmin

Greetings, I'm Devendra Dode, a full-stack developer, entrepreneur, and the proud owner of Tutsmake.com. My passion lies in crafting informative tutorials and offering valuable tips to assist fellow developers on their coding journey. Within my content, I cover a spectrum of technologies, including PHP, Python, JavaScript, jQuery, Laravel, Livewire, CodeIgniter, Node.js, Express.js, Vue.js, Angular.js, React.js, MySQL, MongoDB, REST APIs, Windows, XAMPP, Linux, Ubuntu, Amazon AWS, Composer, SEO, WordPress, SSL, and Bootstrap. Whether you're starting out or looking for advanced examples, I provide step-by-step guides and practical demonstrations to make your learning experience seamless. Let's explore the diverse realms of coding together.

Leave a Reply

Your email address will not be published. Required fields are marked *