<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>go Archives - Linux Windows and android Tutorials</title>
	<atom:link href="https://www.osradar.com/tag/go/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.osradar.com</link>
	<description>tutorials and news and Seurity</description>
	<lastBuildDate>Wed, 10 Jun 2020 19:11:52 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.8.12</generator>
	<item>
		<title>How to install GO language on Ubuntu 20.04 / 18.04?</title>
		<link>https://www.osradar.com/install-go-language-ubuntu-20-04-18-04/</link>
					<comments>https://www.osradar.com/install-go-language-ubuntu-20-04-18-04/#respond</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Wed, 10 Jun 2020 22:33:00 +0000</pubDate>
				<category><![CDATA[Featured]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[go]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[Tutorial]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=8607</guid>

					<description><![CDATA[<p>The world of software development is a complex world. Every day new and better features emerge that force developers to broaden their range of knowledge. However, not all these technologies are complex to assimilate, and for this purpose, I will teach you how to install GO language in Ubuntu 20.04 / 18.04. Go is an [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-go-language-ubuntu-20-04-18-04/">How to install GO language on Ubuntu 20.04 / 18.04?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>The world of software development is a complex world. Every day new and better features emerge that force developers to broaden their range of knowledge. However, not all these technologies are complex to assimilate, and for this purpose, I will teach you how to install GO language in Ubuntu 20.04 / 18.04.</p>
<p><a href="https://golang.org" rel="noopener">Go</a> is an open-source (<a href="https://golang.org/LICENSE" rel="noopener">BSD license</a>) programming language that was born with the objective of allowing the creation of efficient and easily distributable applications. So, it has binaries for Windows, Mac OS, and of course, for Linux.</p>
<p>So, in this post, I will install it and create a &#8220;Hello World&#8221; file for the test.</p>
<h1>1. Install GO Language</h1>
<p>The installation of GO is quite simple, just download the binaries and move them to the preferred location. Of course, you can also check that the installation is correct through the key.</p>
<p>So, install <a href="https://www.osradar.com/the-wget-command/" target="_blank" rel="noopener noreferrer">wget</a> package.</p>
<pre class="">:~$ sudo apt install wget</pre>
<p>Then, download GO binaries.</p>
<pre class="">:~$ wget -c https://dl.google.com/go/go1.14.4.linux-amd64.tar.gz
--2020-06-08 23:47:29--  https://dl.google.com/go/go1.14.4.linux-amd64.tar.gz
Resolving dl.google.com (dl.google.com)... 142.250.64.206, 2607:f8b0:4008:80c::200e
Connecting to dl.google.com (dl.google.com)|142.250.64.206|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 123711003 (118M) [application/octet-stream]
Saving to: ‘go1.14.4.linux-amd64.tar.gz’
go1.14.4.linux-amd64.tar.gz                100%[=====================================================================================&gt;] 117,98M   162KB/s    in 17m 45s 
2020-06-09 00:05:17 (113 KB/s) - ‘go1.14.4.linux-amd64.tar.gz’ saved [123711003/123711003]</pre>
<figure id="attachment_20995" aria-describedby="caption-attachment-20995" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-20995 size-full" src="https://www.osradar.com/wp-content/uploads/2018/12/1-21.png" alt="1.- Download and install GO" width="1365" height="271" srcset="https://www.osradar.com/wp-content/uploads/2018/12/1-21.png 1365w, https://www.osradar.com/wp-content/uploads/2018/12/1-21-300x60.png 300w, https://www.osradar.com/wp-content/uploads/2018/12/1-21-1024x203.png 1024w, https://www.osradar.com/wp-content/uploads/2018/12/1-21-768x152.png 768w, https://www.osradar.com/wp-content/uploads/2018/12/1-21-696x138.png 696w, https://www.osradar.com/wp-content/uploads/2018/12/1-21-1068x212.png 1068w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-20995" class="wp-caption-text">1.- Download and install GO</figcaption></figure>
<p><em>Note: At the time of writing this post the latest stable version of GO is 1.14.4.</em></p>
<p>Now, it is necessary to decompress the file.</p>
<pre class="">:~$ tar xvf go1.14.4.linux-amd64.tar.gz</pre>
<p>Next, Next, change the owner of the folder and move it to <code>/usr/local/</code>.</p>
<pre class="">:~$ sudo chown -R root:root go
:~$ sudo mv go /usr/local</pre>
<p>Many people prefer to change the route to another, but the recommended one is <code>/usr/local/</code>.</p>
<h1>2. Working with the paths</h1>
<p>Now you need to make some adjustments to your GO routes. For example, set Go&#8217;s root value, which tells Go where to look for its files.</p>
<pre class="">:~$ sudo nano ~/.profile</pre>
<p>At the end of the file add the following:</p>
<pre class="">export GOROOT=$HOME/go
export GOPATH=$HOME/work
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin</pre>
<p><em>Note: These parameters work if GO was installed in the personal folder. If this is not the case, you must specify the paths. </em></p>
<p>In this case:</p>
<pre class="">export GOROOT=/usr/local/go    
export GOPATH=$HOME/work/
export PATH=$GOPATH/bin:$GOROOT/bin:$PATH</pre>
<figure id="attachment_8613" aria-describedby="caption-attachment-8613" style="width: 540px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-8613" src="https://www.osradar.com/wp-content/uploads/2018/12/8-13.png" alt="Setting the paths" width="540" height="152" srcset="https://www.osradar.com/wp-content/uploads/2018/12/8-13.png 540w, https://www.osradar.com/wp-content/uploads/2018/12/8-13-300x84.png 300w" sizes="(max-width: 540px) 100vw, 540px" /><figcaption id="caption-attachment-8613" class="wp-caption-text">2.- Setting the paths</figcaption></figure>
<p>Now, for the changes to take effect, it is necessary to refresh your bash profile.</p>
<pre class="">:~$ source ~/.profile</pre>
<p>Check the GO version installed.</p>
<pre class="">:~$ go version
go version go1.14.4 linux/amd64</pre>
<figure id="attachment_20996" aria-describedby="caption-attachment-20996" style="width: 780px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-20996 size-full" src="https://www.osradar.com/wp-content/uploads/2018/12/3-20.png" alt="Checking the GO version" width="780" height="130" srcset="https://www.osradar.com/wp-content/uploads/2018/12/3-20.png 780w, https://www.osradar.com/wp-content/uploads/2018/12/3-20-300x50.png 300w, https://www.osradar.com/wp-content/uploads/2018/12/3-20-768x128.png 768w, https://www.osradar.com/wp-content/uploads/2018/12/3-20-696x116.png 696w" sizes="(max-width: 780px) 100vw, 780px" /><figcaption id="caption-attachment-20996" class="wp-caption-text">3.- Checking the GO version</figcaption></figure>
<h1>3. Creating a Hello World file</h1>
<p>Now to check that everything is OK, you need to create a GO file and run it.</p>
<p>First, create the GO workspace. Don&#8217;t worry, it is a folder. I will call it <code>work</code>. Look at the above image.</p>
<pre class="">:~$ mkdir -p $HOME/work/src/hello</pre>
<p>Then, create the first GO file.</p>
<pre class="">:~$ nano ~/work/src/hello/hello.go</pre>
<p>Now, add these lines.</p>
<pre class="">package main 
import "fmt"
func main() {
fmt.Printf("hello, world\n")
}</pre>
<figure id="attachment_20997" aria-describedby="caption-attachment-20997" style="width: 974px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-20997 size-full" src="https://www.osradar.com/wp-content/uploads/2018/12/4-20.png" alt="3.- Creating the hello world file" width="974" height="156" srcset="https://www.osradar.com/wp-content/uploads/2018/12/4-20.png 974w, https://www.osradar.com/wp-content/uploads/2018/12/4-20-300x48.png 300w, https://www.osradar.com/wp-content/uploads/2018/12/4-20-768x123.png 768w, https://www.osradar.com/wp-content/uploads/2018/12/4-20-696x111.png 696w" sizes="(max-width: 974px) 100vw, 974px" /><figcaption id="caption-attachment-20997" class="wp-caption-text">4.- Creating the hello world file</figcaption></figure>
<p>Now, compile the file, install the package generated, and then run it.</p>
<pre class="">:~$ go build hello
:~$ go install hello
:~$ hello</pre>
<figure id="attachment_20998" aria-describedby="caption-attachment-20998" style="width: 776px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-20998 size-full" src="https://www.osradar.com/wp-content/uploads/2018/12/5-18.png" alt="Go working on Ubuntu 20.04 / Ubuntu 18.04" width="776" height="145" srcset="https://www.osradar.com/wp-content/uploads/2018/12/5-18.png 776w, https://www.osradar.com/wp-content/uploads/2018/12/5-18-300x56.png 300w, https://www.osradar.com/wp-content/uploads/2018/12/5-18-768x144.png 768w, https://www.osradar.com/wp-content/uploads/2018/12/5-18-696x130.png 696w" sizes="(max-width: 776px) 100vw, 776px" /><figcaption id="caption-attachment-20998" class="wp-caption-text">Go working on Ubuntu 20.04 / Ubuntu 18.04</figcaption></figure>
<p>And that&#8217;s it.</p>
<h1>Conclusion</h1>
<p>GO is a very popular language and every day it is more and more popular. It&#8217;s simple but very powerful, besides being open source. As you have seen, its installation is really simple.</p>
<p>Please share this article on your social networks. Also, join our <a href="https://t.me/osradar" target="_blank" rel="noopener noreferrer">Telegram Channel</a> and buy us a coffee.</p>
<p>You can also read &#8220;<a href="https://www.osradar.com/install-pgadmin4-ubuntu-20-04/">How to install pgAdmin4 on Ubuntu 20.04</a>&#8220;.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-go-language-ubuntu-20-04-18-04/">How to install GO language on Ubuntu 20.04 / 18.04?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/install-go-language-ubuntu-20-04-18-04/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to install Go Language on FreeBSD 12?</title>
		<link>https://www.osradar.com/how-to-install-go-language-freebsd-12/</link>
					<comments>https://www.osradar.com/how-to-install-go-language-freebsd-12/#respond</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Fri, 06 Mar 2020 00:56:00 +0000</pubDate>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[freebsd12]]></category>
		<category><![CDATA[go]]></category>
		<category><![CDATA[GoLang]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[Tutorial]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=18767</guid>

					<description><![CDATA[<p>Hi, friends in this post, you will learn how to install Go on FreeBSD 12. This popular programming language is gaining more and more followers every day. Go is an open source (BSD license) programming language that was born with the objective of allowing the creation of efficient and easily distributable applications. So, it has [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-go-language-freebsd-12/">How to install Go Language on FreeBSD 12?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Hi, friends in this post, you will learn how to install Go on <a href="https://www.osradar.com/tag/freebsd/" target="_blank" rel="noopener noreferrer">FreeBSD</a> 12. This popular programming language is gaining more and more followers every day.</p>
<p><a href="https://golang.org" rel="noopener">Go</a> is an open source (<a href="https://golang.org/LICENSE" rel="noopener">BSD license</a>) programming language that was born with the objective of allowing the creation of efficient and easily distributable applications. So, it has binaries for Windows, Mac OS and of course, for Linux.</p>
<p>One of the main features of Go is the efficiency with which it manages computer resources. To the extent that many claims to be the natural replacement of C.</p>
<p>On the other hand, Go is a compiled language and has a garbage collector that tries to reduce the latency to the minimum guaranteeing optimal performance.</p>
<p>For this and many other reasons is that more and more developers have it as their main language.</p>
<h2>Install Go language on FreeBSD 12</h2>
<p>One of the main advantages of FreeBSD is that it has a large number of packages available from the official repositories. However, not all of them are up-to-date.</p>
<p>So in this post, we will download and install the latest stable version of Go which is 1.14.</p>
<p>First, open a terminal session. Once you have it open, you need to install curl to download Go.</p>
<pre>:~$ sudo pkg install curl
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
The following 2 package(s) will be affected (of 0 checked):
New packages to be INSTALLED:
	curl: 7.67.0
	ca_root_nss: 3.50
Number of packages to be installed: 2
The process will require 4 MiB more space.
1 MiB to be downloaded.
Proceed with this action? [y/N]: y</pre>
<figure id="attachment_18776" aria-describedby="caption-attachment-18776" style="width: 691px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-18776" src="https://www.osradar.com/wp-content/uploads/2020/03/1.png" alt="1.- Install curl on FreeBSD 12" width="691" height="270" srcset="https://www.osradar.com/wp-content/uploads/2020/03/1.png 691w, https://www.osradar.com/wp-content/uploads/2020/03/1-300x117.png 300w" sizes="(max-width: 691px) 100vw, 691px" /><figcaption id="caption-attachment-18776" class="wp-caption-text">1.- Install curl on FreeBSD 12</figcaption></figure>
<p>Once you have installed curl, we can start the download of Go with the following command:</p>
<pre>:~$ curl https://dl.google.com/go/go1.14.freebsd-amd64.tar.gz --output go.tar.gz</pre>
<figure id="attachment_18777" aria-describedby="caption-attachment-18777" style="width: 765px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-18777 size-full" src="https://www.osradar.com/wp-content/uploads/2020/03/2.png" alt="2.- Download Go language on FreeBSD 12" width="765" height="144" srcset="https://www.osradar.com/wp-content/uploads/2020/03/2.png 765w, https://www.osradar.com/wp-content/uploads/2020/03/2-300x56.png 300w, https://www.osradar.com/wp-content/uploads/2020/03/2-696x131.png 696w" sizes="(max-width: 765px) 100vw, 765px" /><figcaption id="caption-attachment-18777" class="wp-caption-text">2.- Download Go language on FreeBSD 12</figcaption></figure>
<p>When the download is finished we have to unzip it and move it to the /usr/local/ directory</p>
<pre>:~$ tar xvf go.tar.gz
:~$ sudo mv go /usr/local</pre>
<p>Go is ready for action, but it is convenient to make it available globally in our terminal. To do this, you have to edit the profile file.</p>
<pre>:~$ sudo nano ~/.profile</pre>
<p>And add the following content at the end:</p>
<pre>export GOROOT=/usr/local/go 
export GOPATH=$HOME/work/
export PATH=$GOPATH/bin:$GOROOT/bin:$PATH</pre>
<figure id="attachment_18778" aria-describedby="caption-attachment-18778" style="width: 608px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-18778" src="https://www.osradar.com/wp-content/uploads/2020/03/3.png" alt="3.- Configuring go" width="608" height="260" srcset="https://www.osradar.com/wp-content/uploads/2020/03/3.png 608w, https://www.osradar.com/wp-content/uploads/2020/03/3-300x128.png 300w" sizes="(max-width: 608px) 100vw, 608px" /><figcaption id="caption-attachment-18778" class="wp-caption-text">3.- Configuring go</figcaption></figure>
<p>I&#8217;ll explain something quickly. The second line refers to a folder called &#8220;work&#8221; in that folder is where we have to include all our Go projects. Of course, you can replace the name &#8220;work&#8221; with whatever you want.</p>
<p>Save the changes and close the file.</p>
<p>Now you can see the version of Go installed with the following command:</p>
<pre>:~$ go version
go version go1.14 freebsd/amd64</pre>
<figure id="attachment_18780" aria-describedby="caption-attachment-18780" style="width: 845px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-18780" src="https://www.osradar.com/wp-content/uploads/2020/03/5.png" alt="5.- Go 1.14 installed" width="845" height="189" srcset="https://www.osradar.com/wp-content/uploads/2020/03/5.png 845w, https://www.osradar.com/wp-content/uploads/2020/03/5-300x67.png 300w, https://www.osradar.com/wp-content/uploads/2020/03/5-768x172.png 768w, https://www.osradar.com/wp-content/uploads/2020/03/5-696x156.png 696w" sizes="(max-width: 845px) 100vw, 845px" /><figcaption id="caption-attachment-18780" class="wp-caption-text">5.- Go 1.14 installed</figcaption></figure>
<p>This indicates that Go is available from the console no matter where the prompt is located.</p>
<h2>Testing Go</h2>
<p>Now that Go is installed, let&#8217;s do the classic Hello World program to check that everything is okay.</p>
<p>First, we&#8217;ll create the project folders. Remember that it will be inside the work folder. Inside it, the project folder and inside it, the src folder where we will create the source file.</p>
<pre>:~$ mkdir -p $HOME/work/src/hello</pre>
<p>Then, create the source file and add the following content</p>
<pre>:~$ nano ~/work/src/hello/hello.go
package main 
 import "fmt"
 func main() {
 fmt.Printf("hello, world\n")
 }

</pre>
<figure id="attachment_18781" aria-describedby="caption-attachment-18781" style="width: 845px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-18781" src="https://www.osradar.com/wp-content/uploads/2020/03/5-1.png" alt="5.- Creating the hello world program in Go language" width="845" height="189" srcset="https://www.osradar.com/wp-content/uploads/2020/03/5-1.png 845w, https://www.osradar.com/wp-content/uploads/2020/03/5-1-300x67.png 300w, https://www.osradar.com/wp-content/uploads/2020/03/5-1-768x172.png 768w, https://www.osradar.com/wp-content/uploads/2020/03/5-1-696x156.png 696w" sizes="(max-width: 845px) 100vw, 845px" /><figcaption id="caption-attachment-18781" class="wp-caption-text">5.- Creating the hello world program in Go language</figcaption></figure>
<p>Finally, we build the project, compile the source code and execute it:</p>
<pre>:~$ go build hello
:~$ go install hello
:~$ hello
hello, world</pre>
<figure id="attachment_18782" aria-describedby="caption-attachment-18782" style="width: 789px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-18782" src="https://www.osradar.com/wp-content/uploads/2020/03/6.png" alt="6.- Go language on FreeBSD 12" width="789" height="125" srcset="https://www.osradar.com/wp-content/uploads/2020/03/6.png 789w, https://www.osradar.com/wp-content/uploads/2020/03/6-300x48.png 300w, https://www.osradar.com/wp-content/uploads/2020/03/6-768x122.png 768w, https://www.osradar.com/wp-content/uploads/2020/03/6-696x110.png 696w" sizes="(max-width: 789px) 100vw, 789px" /><figcaption id="caption-attachment-18782" class="wp-caption-text">6.- Go language on FreeBSD 12</figcaption></figure>
<p>So, Go is ready to use.</p>
<h2>Conclusion</h2>
<p>There are many programming languages but there is always room for innovation and that is what Go gives us. An efficient language and with the support of a giant like Google.</p>
<p>Please share this post and join <a href="https://t.me/osradar" target="_blank" rel="noopener noreferrer">our Telegram channel.</a></p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-go-language-freebsd-12/">How to install Go Language on FreeBSD 12?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/how-to-install-go-language-freebsd-12/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Install GO language on CentOS 7</title>
		<link>https://www.osradar.com/install-go-language-on-centos-7/</link>
					<comments>https://www.osradar.com/install-go-language-on-centos-7/#respond</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Thu, 21 Feb 2019 11:16:03 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CentOS]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[go]]></category>
		<category><![CDATA[GoLang]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[learn]]></category>
		<category><![CDATA[Tutorial]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=10971</guid>

					<description><![CDATA[<p>Many people are passionate about programming and use Linux as a learning platform for it. In addition, Linux being a free system lends itself to this type of educational projects. However, although it is free, it does not leave aside security and stability, to be a whole software platform. In this sense, it also adapts [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-go-language-on-centos-7/">Install GO language on CentOS 7</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Many people are passionate about programming and use Linux as a learning platform for it. In addition, Linux being a free system lends itself to this type of educational projects. However, although it is free, it does not leave aside security and stability, to be a whole software platform. In this sense, it also adapts to many programming languages that are emerging as an alternative to the existing ones that have dominated the sector for a long time as Java or C++. With this in mind, I will teach you how to install Go on CentOS7.</p>
<p>In the past, <a href="https://www.osradar.com/install-go-language-ubuntu-18-04/" rel="noopener">we&#8217;ve talked</a> about GO. GO is a programming language that is becoming increasingly popular among developers and sysadmin. Initially, it was created by Google but has been expanding to be used by many current developers. It is inspired by <a href="https://www.osradar.com/how-to-compile-a-c-code-on-gnu-linux/" rel="noopener">C++</a> and has binaries for Windows, Linux and Mac OS. It is also open source under the <a href="https://www.osradar.com/how-to-install-gnome-or-plasma5-kde-on-freebsd-12/" rel="noopener">BSD</a> license.</p>
<h2>1.- Upgrade the system</h2>
<p>First of all, it is necessary to make a complete update to the system. For this, run the following command:</p>
<pre>:~$ su
:~# yum update</pre>
<figure id="attachment_10973" aria-describedby="caption-attachment-10973" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10973" src="https://www.osradar.com/wp-content/uploads/2019/02/1-15.png" alt="1.- Upgrade the system" width="1365" height="299" srcset="https://www.osradar.com/wp-content/uploads/2019/02/1-15.png 1365w, https://www.osradar.com/wp-content/uploads/2019/02/1-15-300x66.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/1-15-768x168.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/1-15-1024x224.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/1-15-696x152.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/1-15-1068x234.png 1068w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-10973" class="wp-caption-text">1.- Upgrade the system</figcaption></figure>
<p>The main objective of this is to make your system have the latest security patches available. This way it will be more stable and you will be ready to continue with the process.</p>
<h2>2.- Download and install GO</h2>
<p>CentOS 7 is a 64-bit system, so we will download the corresponding binaries using wget. If you do not have it installed, do it first.</p>
<pre>:~# yum install wget
:~# wget https://dl.google.com/go/go1.11.5.linux-amd64.tar.gz</pre>
<figure id="attachment_10974" aria-describedby="caption-attachment-10974" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10974" src="https://www.osradar.com/wp-content/uploads/2019/02/2-14.png" alt="2.- Download and install GO" width="1365" height="280" srcset="https://www.osradar.com/wp-content/uploads/2019/02/2-14.png 1365w, https://www.osradar.com/wp-content/uploads/2019/02/2-14-300x62.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/2-14-768x158.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/2-14-1024x210.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/2-14-696x143.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/2-14-1068x219.png 1068w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-10974" class="wp-caption-text">2.- Download and install GO</figcaption></figure>
<p>At the time of writing this post, the latest stable version of GO is 1.11.5. Check the GO website for the latest version.</p>
<p>After doing this, it is necessary to unzip the downloaded folder. We will do it in the <code>/usr/local</code> directory.</p>
<pre>:~# tar -zxvf go1.11.5.linux-amd64.tar.gz -C /usr/local</pre>
<figure id="attachment_10975" aria-describedby="caption-attachment-10975" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10975" src="https://www.osradar.com/wp-content/uploads/2019/02/3-14.png" alt="3.- Decompress GO" width="1366" height="768" srcset="https://www.osradar.com/wp-content/uploads/2019/02/3-14.png 1366w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-300x169.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-768x432.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-1024x576.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-696x391.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-1068x600.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/3-14-747x420.png 747w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-10975" class="wp-caption-text">3.- Decompress GO</figcaption></figure>
<p>So that the installation does not have problems. It is necessary to define environment variables. I mean <code>GOROOT</code> and <code>PATH</code>.</p>
<pre>:~# echo 'export GOROOT=/usr/local/go' | tee -a /etc/profile
:~# echo 'export PATH=$PATH:/usr/local/go/bin' | tee -a /etc/profile</pre>
<p>Finally, refresh your bash profile.</p>
<pre>:~# source /etc/profile</pre>
<figure id="attachment_10976" aria-describedby="caption-attachment-10976" style="width: 961px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10976" src="https://www.osradar.com/wp-content/uploads/2019/02/4-10.png" alt="4.- Setting the environment variables" width="961" height="183" srcset="https://www.osradar.com/wp-content/uploads/2019/02/4-10.png 961w, https://www.osradar.com/wp-content/uploads/2019/02/4-10-300x57.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/4-10-768x146.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/4-10-696x133.png 696w" sizes="(max-width: 961px) 100vw, 961px" /><figcaption id="caption-attachment-10976" class="wp-caption-text">4.- Setting the environment variables</figcaption></figure>
<p>So, test GO.</p>
<h2>3.- Test the installation</h2>
<p>To verify that the installation has been correct, it is first necessary to show the version of GO. To do it, run this command:</p>
<pre>:~# go version
:~# go env</pre>
<figure id="attachment_10977" aria-describedby="caption-attachment-10977" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10977" src="https://www.osradar.com/wp-content/uploads/2019/02/5-12.png" alt="5.- Showing the GO version" width="1365" height="571" srcset="https://www.osradar.com/wp-content/uploads/2019/02/5-12.png 1365w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-300x125.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-768x321.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-1024x428.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-696x291.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-1068x447.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/5-12-1004x420.png 1004w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-10977" class="wp-caption-text">5.- Showing the GO version</figcaption></figure>
<p>However, the best way to check if your GO is correctly installed is to make a program and run it.</p>
<p>First, create a folder where the program will be located.</p>
<pre>:~# mkdir -p src/test
:~# cd src/test</pre>
<figure id="attachment_10978" aria-describedby="caption-attachment-10978" style="width: 855px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10978" src="https://www.osradar.com/wp-content/uploads/2019/02/6-11.png" alt="6.- Creating the folder" width="855" height="129" srcset="https://www.osradar.com/wp-content/uploads/2019/02/6-11.png 855w, https://www.osradar.com/wp-content/uploads/2019/02/6-11-300x45.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/6-11-768x116.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/6-11-696x105.png 696w" sizes="(max-width: 855px) 100vw, 855px" /><figcaption id="caption-attachment-10978" class="wp-caption-text">6.- Creating the folder</figcaption></figure>
<p>Next, create the file. I will name it test.go.</p>
<pre>:~# nano test.go</pre>
<p>And add the following:</p>
<pre>package main
import "fmt"
func main() {
    fmt.Printf("Hi, I am Angelo. Thanks for visit Osradar\n")
}</pre>
<figure id="attachment_10979" aria-describedby="caption-attachment-10979" style="width: 874px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10979" src="https://www.osradar.com/wp-content/uploads/2019/02/7-11.png" alt="7.- Creating a new file to test GO" width="874" height="199" srcset="https://www.osradar.com/wp-content/uploads/2019/02/7-11.png 874w, https://www.osradar.com/wp-content/uploads/2019/02/7-11-300x68.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/7-11-768x175.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/7-11-696x158.png 696w" sizes="(max-width: 874px) 100vw, 874px" /><figcaption id="caption-attachment-10979" class="wp-caption-text">7.- Creating a new file to test GO</figcaption></figure>
<p>Finally, run the file.</p>
<pre>:~# go run test.go</pre>
<figure id="attachment_10980" aria-describedby="caption-attachment-10980" style="width: 897px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10980" src="https://www.osradar.com/wp-content/uploads/2019/02/8-12.png" alt="8.- GO is running properly" width="897" height="130" srcset="https://www.osradar.com/wp-content/uploads/2019/02/8-12.png 897w, https://www.osradar.com/wp-content/uploads/2019/02/8-12-300x43.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/8-12-768x111.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/8-12-696x101.png 696w" sizes="(max-width: 897px) 100vw, 897px" /><figcaption id="caption-attachment-10980" class="wp-caption-text">8.- GO is running properly</figcaption></figure>
<p>So, GO is ready for the action.</p>
<h2>Conclusion</h2>
<p>Learning to program using GO is a good idea these days. The project is quite mature and more and more people are interested in this language. Installing GO on CentOS 7 is not complicated at all.</p>
<p>Please share this post with your friends.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-go-language-on-centos-7/">Install GO language on CentOS 7</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/install-go-language-on-centos-7/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Using Gotop a graphical system monitor</title>
		<link>https://www.osradar.com/using-gotop-a-graphical-system-monitor/</link>
					<comments>https://www.osradar.com/using-gotop-a-graphical-system-monitor/#respond</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Mon, 04 Feb 2019 05:00:09 +0000</pubDate>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[cli]]></category>
		<category><![CDATA[go]]></category>
		<category><![CDATA[gotop]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[htop]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[terminal]]></category>
		<category><![CDATA[top]]></category>
		<category><![CDATA[Tutorial]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=10489</guid>

					<description><![CDATA[<p>It is always a good idea to know various tools for monitoring systems from the terminal. Of course, they can not be compared to professional tools like Zabbix, but neither do many users really need them. We&#8217;ve already talked about Hegemon. Now it is Gotop&#8217;s turn. Using Gotop you can see the resources spent by [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/using-gotop-a-graphical-system-monitor/">Using Gotop a graphical system monitor</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>It is always a good idea to know various tools for monitoring systems from the terminal. Of course, they can not be compared to professional tools like Zabbix, but neither do many users really need them. We&#8217;ve already talked about Hegemon. Now it is Gotop&#8217;s turn. Using Gotop you can see the resources spent by the system in a very friendly way.</p>
<p><a href="https://github.com/cjbassi/gotop" rel="noopener">Gotop is another terminal based graphical</a> activity monitor, inspired by gtop and vtop, this time written in Go. With this tool, you can visualize the resources that your system consumes in a very friendly way. It is written in <a href="https://www.osradar.com/install-go-language-ubuntu-18-04/" rel="noopener">Go</a> with many advantages in execution time. It is quite fast and does not consume almost resources.</p>
<p>Some of its main features are:</p>
<ul>
<li>It is available for all Linux distributions. As well as for Mac OS and BSD.</li>
<li>You can customize the color scheme of the application adapting it to your needs.</li>
<li>It is open source. The program is released under the <a href="https://github.com/cjbassi/gotop/blob/master/LICENSE" rel="noopener">GNU Affero General Public License</a>.</li>
<li>You can monitor CPU, Network, RAM, battery level and processes.</li>
</ul>
<p>And many more.</p>
<p>So, let using Gotop.</p>
<h2>1. Upgrade the system</h2>
<p>The first step is to update the system so that it has the best possible performance and you will be able to show more accurate data when running Gotop.</p>
<p>So, in <a href="https://www.osradar.com/set-up-dhcp-server-debian-9/" rel="noopener">Debian</a>, <a href="https://www.osradar.com/install-apachemq-ubuntu-18-04/" rel="noopener">Ubuntu</a>, and derivates:</p>
<pre class="">:~$ sudo apt update &amp;&amp; sudo apt upgrade</pre>
<figure id="attachment_10490" aria-describedby="caption-attachment-10490" style="width: 991px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10490" src="https://www.osradar.com/wp-content/uploads/2019/02/1-1.png" alt="1.- Upgrade the system" width="991" height="363" srcset="https://www.osradar.com/wp-content/uploads/2019/02/1-1.png 991w, https://www.osradar.com/wp-content/uploads/2019/02/1-1-300x110.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/1-1-768x281.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/1-1-696x255.png 696w" sizes="(max-width: 991px) 100vw, 991px" /><figcaption id="caption-attachment-10490" class="wp-caption-text">1.- Upgrade the system</figcaption></figure>
<p>&nbsp;</p>
<p>For <a href="https://www.osradar.com/how-to-install-zabbix-server-4-on-centos-7/" rel="noopener">CentOS</a> 7 and RHEL:</p>
<pre class="">:~$ sudo yum update</pre>
<p>If you are using <a href="https://osradar.com/tag/fedora/" rel="noopener">Fedora</a> 28, 29:</p>
<pre class="">:~$ sudo dnf update</pre>
<p>Finally, if you are using OpenSUSE, you can update the system with this command:</p>
<pre class="">:~$ sudo zypper up</pre>
<p>Once you have updated the system, you can move on.</p>
<h2>2. Installing and using Gotop</h2>
<p>Now it is time for installation. To do this, first, you have to download the binaries from the <a href="https://github.com/cjbassi/gotop/releases" rel="noopener">download section</a> of the project website.</p>
<p>At the time of writing this post, the latest stable version of Gotop is 2.0 which introduces new features such as the ability to monitor the battery of a laptop.</p>
<p>So, download it.</p>
<pre class="">:~$ wget -c https://github.com/cjbassi/gotop/releases/download/2.0.0/gotop_2.0.0_linux_amd64.tgz</pre>
<figure id="attachment_10491" aria-describedby="caption-attachment-10491" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10491" src="https://www.osradar.com/wp-content/uploads/2019/02/2-1.png" alt="2.- Download Gotop" width="1365" height="504" srcset="https://www.osradar.com/wp-content/uploads/2019/02/2-1.png 1365w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-300x111.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-768x284.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-1024x378.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-696x257.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-1068x394.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/2-1-1138x420.png 1138w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-10491" class="wp-caption-text">2.- Download Gotop</figcaption></figure>
<p>Of course, if you do not have wget installed, you have to do it.</p>
<p>For Debian, Ubuntu, Linux Mint and derivates:</p>
<pre class="">:~$ sudo apt install wget</pre>
<p>In case, you are using CentOS 7 and RHEL:</p>
<pre class="">:~$ yum install wget</pre>
<p>For Fedora 29:</p>
<pre class="">:~$ sudo dnf install wget</pre>
<p>Finally, if you are using OpenSUSE:</p>
<pre class="">:~$ sudo zypper in wget</pre>
<p>However, wget is a main component of the system. It is likely installed by default.</p>
<p>Next, decompress the file.</p>
<pre class="">:~$ tar -xvzf gotop_2.0.0_linux_amd64.tgz</pre>
<figure id="attachment_10492" aria-describedby="caption-attachment-10492" style="width: 826px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10492" src="https://www.osradar.com/wp-content/uploads/2019/02/3-1.png" alt="3.- Decompress the file" width="826" height="141" srcset="https://www.osradar.com/wp-content/uploads/2019/02/3-1.png 826w, https://www.osradar.com/wp-content/uploads/2019/02/3-1-300x51.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/3-1-768x131.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/3-1-696x119.png 696w" sizes="(max-width: 826px) 100vw, 826px" /><figcaption id="caption-attachment-10492" class="wp-caption-text">3.- Decompress the file</figcaption></figure>
<p>Now, run it.</p>
<pre class="">:~$ ./gotop</pre>
<figure id="attachment_10494" aria-describedby="caption-attachment-10494" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10494" src="https://www.osradar.com/wp-content/uploads/2019/02/5-1.png" alt="5.- Using Gotop" width="1366" height="768" srcset="https://www.osradar.com/wp-content/uploads/2019/02/5-1.png 1366w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-300x169.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-768x432.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-1024x576.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-696x391.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-1068x600.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/5-1-747x420.png 747w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-10494" class="wp-caption-text">5.- Using Gotop</figcaption></figure>
<p>To exit, press CTRL + C.</p>
<p>If you want more options, you can show the help.</p>
<pre class="">:~$ ./gotop --help</pre>
<figure id="attachment_10496" aria-describedby="caption-attachment-10496" style="width: 764px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10496" src="https://www.osradar.com/wp-content/uploads/2019/02/6-1.png" alt="6.- Gotop help" width="764" height="368" srcset="https://www.osradar.com/wp-content/uploads/2019/02/6-1.png 764w, https://www.osradar.com/wp-content/uploads/2019/02/6-1-300x145.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/6-1-696x335.png 696w" sizes="(max-width: 764px) 100vw, 764px" /><figcaption id="caption-attachment-10496" class="wp-caption-text">6.- Gotop help</figcaption></figure>
<p>So, you can change the color schemes. For example:</p>
<pre class="">:~$ ./gotop --color=monokai</pre>
<figure id="attachment_10497" aria-describedby="caption-attachment-10497" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10497" src="https://www.osradar.com/wp-content/uploads/2019/02/7-1.png" alt="7.- Gotop with another color scheme" width="1366" height="768" srcset="https://www.osradar.com/wp-content/uploads/2019/02/7-1.png 1366w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-300x169.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-768x432.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-1024x576.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-696x391.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-1068x600.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/7-1-747x420.png 747w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-10497" class="wp-caption-text">7.- Gotop with another color scheme</figcaption></figure>
<p>Or, enable the averages.</p>
<pre class="">:~$ ./gotop -a</pre>
<figure id="attachment_10498" aria-describedby="caption-attachment-10498" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-10498" src="https://www.osradar.com/wp-content/uploads/2019/02/8-1.png" alt="8.- Show the average use of cpu" width="1366" height="768" srcset="https://www.osradar.com/wp-content/uploads/2019/02/8-1.png 1366w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-300x169.png 300w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-768x432.png 768w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-1024x576.png 1024w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-696x391.png 696w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-1068x600.png 1068w, https://www.osradar.com/wp-content/uploads/2019/02/8-1-747x420.png 747w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-10498" class="wp-caption-text">8.- Show the average use of CPU</figcaption></figure>
<h2>Conclusion</h2>
<p>It is always good to have tools to monitor the state of our system. Now we have another tool that will help us with the task in a simple and friendly.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/using-gotop-a-graphical-system-monitor/">Using Gotop a graphical system monitor</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/using-gotop-a-graphical-system-monitor/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
