<?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>graylog Archives - Linux Windows and android Tutorials</title>
	<atom:link href="https://www.osradar.com/tag/graylog/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.osradar.com</link>
	<description>tutorials and news and Seurity</description>
	<lastBuildDate>Fri, 09 Oct 2020 14:20:24 +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 Graylog On Ubuntu 20.04</title>
		<link>https://www.osradar.com/how-to-install-graylog-on-ubuntu-20-04/</link>
					<comments>https://www.osradar.com/how-to-install-graylog-on-ubuntu-20-04/#respond</comments>
		
		<dc:creator><![CDATA[sabi]]></dc:creator>
		<pubDate>Mon, 05 Oct 2020 09:58:50 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[focal]]></category>
		<category><![CDATA[Focal Fossa]]></category>
		<category><![CDATA[graylog]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[Tutorial]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=23209</guid>

					<description><![CDATA[<p>Today we are going to learn that how to install graylog on Ubuntu 20.04. Graylog provides the logs about the system and manage the system logs centrally. It contains three parts as Graylog server, Elasticsearch and the MongoDB. Simply follow the below steps for an easy and optimal installation. Step 1: Update Your System First [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-graylog-on-ubuntu-20-04/">How To Install Graylog On Ubuntu 20.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>Today we are going to learn that how to install graylog on Ubuntu 20.04. Graylog provides the logs about the system and manage the system logs centrally. It contains three parts as Graylog server, Elasticsearch and the MongoDB. Simply follow the below steps for an easy and optimal installation.</p>



<h3>Step 1: Update Your System</h3>



<p>First of all as usual we do, update your system to have the latest packages installed.</p>



<pre class="wp-block-verse">sudo apt update &amp;&amp; sudo apt upgrade</pre>



<h3>Step 2: Install Java on Ubuntu 20.04</h3>



<p>As Java is required for the graylog server so install it by visiting the below tutorial and proceed further.</p>



<p><a href="https://www.osradar.com/how-to-install-java-on-ubuntu-20-04/" target="_blank" rel="noreferrer noopener">How To Install Java On Ubuntu 20.04</a></p>



<p>Install the other required packages by typing</p>



<pre class="wp-block-verse">sudo apt install -y apt-transport-https openjdk-11-jre-headless uuid-runtime pwgen curl dirmngr</pre>



<p>Verify the java version installed by hitting</p>



<pre class="wp-block-verse">java -version</pre>



<p>Output:</p>



<pre class="wp-block-verse">sabi@sabi20:~$ java --version
openjdk 11.0.8 2020-07-14
OpenJDK Runtime Environment (build 11.0.8+10-post-Ubuntu-0ubuntu120.04)
OpenJDK 64-Bit Server VM (build 11.0.8+10-post-Ubuntu-0ubuntu120.04, mixed mode, sharing)</pre>



<h3>Step 3: Install Elasticsearch on Ubuntu 20.04</h3>



<p>Now, install the elasticsearch as it provides the facility of storing the logs coming from the external sources so it is very useful to use with graylog. Install it by following the below steps.</p>



<p>Hit the below command to download and install the GPG signing key.</p>



<pre class="wp-block-verse">wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -</pre>



<p>Then type the below command to add the Elasticsearch repository on your system.</p>



<pre class="wp-block-verse">echo "deb https://artifacts.elastic.co/packages/oss-6.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-6.x.list</pre>



<p>Finally type the following command to install the Elasticsearch on Ubuntu 20.04.</p>



<pre class="wp-block-verse">sudo apt update<br>sudo apt install -y elasticsearch-oss</pre>



<h3>Step 4: Configure Elasticsearch with Graylog Server on Ubuntu 20.04</h3>



<p>To configure the elasticsearch with graylog, edit the <strong>/etc/elasticsearch/elasticsearch.yml</strong> file and set up the cluster name as graylog.</p>



<pre class="wp-block-verse">cluster.name: graylog</pre>



<p>Then add or uncomment the following line.</p>



<pre class="wp-block-verse">action.auto_create_index: false</pre>



<p>After it reload the Elasticsearch services to take effect of updated configs.</p>



<pre class="wp-block-verse">sudo systemctl daemon-reload
sudo systemctl start elasticsearch
sudo systemctl enable elasticsearch</pre>



<p>It&#8217;ll take maximum 1 minutes to start the services.</p>



<p>Elasticsearch listen to the port 9200. You can use the curl command to verify it.</p>



<pre class="wp-block-verse">curl -X GET http://localhost:9200</pre>



<p>Output:</p>



<p>You&#8217;ll see the similar result. Make sure that the cluster name is graylog.</p>



<p></p>



<h3>Step 5:Install MongoDB on Ubuntu 20.04</h3>



<p>Install the MongoDB v3.6 by running the below commands in your terminal.</p>



<pre class="wp-block-verse">sudo apt update<br>sudo apt install -y mongodb-server</pre>



<p>And start the MogoDB services.</p>



<pre class="wp-block-verse">sudo systemctl start mongodb
sudo systemctl enable mongodb</pre>



<h3>Step 6: Install Graylog Server on Ubuntu 20.04</h3>



<p>As graylog gets data from the elasticsearch and show it on its web interface so it&#8217;s easy to read and go through.</p>



<p>Hit the below commands to add the repository of graylog and install it in Ubuntu 20.04.</p>



<pre class="wp-block-verse">wget https://packages.graylog2.org/repo/packages/graylog-3.3-repository_latest.deb<br>sudo dpkg -i graylog-3.3-repository_latest.deb<br>sudo apt update<br>sudo apt install -y graylog-server</pre>



<p>As for security reasons, enable the secret to secure the user passwords. To do this hit the below command in your terminal.</p>



<pre class="wp-block-verse">pwgen -N 1 -s 96</pre>



<p>Result:</p>



<pre class="wp-block-verse">sabi@sabi20:~$ pwgen -N 1 -s 96
LmnaUmCKUmBgA2mwYpPNoC9FQP8YVR1ijerL00W00oB3scJrwk4CCpIQo3uI2llBlqug5v13UVIx5kXSrvExZ28gGRZlRulC</pre>



<p>Now, edit the server.conf file and paste the above secret as seen below:</p>



<pre class="wp-block-verse">sudo nano /etc/graylog/server/server.conf
password_secret = LmnaUmCKUmBgA2mwYpPNoC9FQP8YVR1ijerL00W00oB3scJrwk4CCpIQo3uI2llBlqug5v13UVIx5kXSrvExZ28gGRZlRulC</pre>



<p>Then generate a hash password for the admin user of graylog that can be used to log in to web interface.</p>



<pre class="wp-block-verse">echo -n Your_Password | sha256sum</pre>



<p>Replace <strong>Your_Password</strong> with your desired password.</p>



<p>Result:</p>



<pre class="wp-block-verse">99e87ec1196275a0c4ef6e5dd1cabd34f0c9a6ed680f24914b773295babd5da2 -</pre>



<p>Now, edit the server.conf file and paste the hash password generated above.</p>



<pre class="wp-block-verse">root_password_sha2 = 99e87ec1196275a0c4ef6e5dd1cabd34f0c9a6ed680f24914b773295babd5da2 -</pre>



<h3>Step 7: Setup Graylog Web Interface on Ubuntu 20.04</h3>



<p>To use the graylog web interface, enable it by editing server.conf file.</p>



<pre class="wp-block-verse">sudo nano /etc/graylog/server/server.conf</pre>



<p>And replace the below line with your system IP.</p>



<pre class="wp-block-verse">http_bind_address = 192.168.0.10:9000</pre>



<p>Finally start the graylog services by running below commands.</p>



<pre class="wp-block-verse">sudo systemctl daemon-reload<br>sudo systemctl start graylog-server<br>sudo systemctl enable graylog-server</pre>



<p>If you got any error during the installation, you can follow up the graylog logs at startup by typing.</p>



<pre class="wp-block-verse">sudo tail -f /var/log/graylog-server/server.log</pre>



<p>You&#8217;ll see the similar output upon successful installation.</p>



<pre class="wp-block-verse">2020-09-29T16:03:06.326-04:00 INFO [ServerBootstrap] Graylog server up and running.</pre>



<h3>Step 8: Access Graylog on Ubuntu 20.04</h3>



<p>Type the IP:9000 in your browser to access graylog web interface.</p>



<p>Provide the  credentials (username=&#8221;admin&#8221; and password=&#8221;root_password_sha2&#8243; created earlier) to log in to the dashboard.</p>



<figure class="wp-block-image size-large"><img loading="lazy" width="1024" height="610" src="//1081754738.rsc.cdn77.org/wp-content/uploads/2020/10/1-1024x610.jpg" alt="" class="wp-image-24210" srcset="https://www.osradar.com/wp-content/uploads/2020/10/1-1024x610.jpg 1024w, https://www.osradar.com/wp-content/uploads/2020/10/1-300x179.jpg 300w, https://www.osradar.com/wp-content/uploads/2020/10/1-768x457.jpg 768w, https://www.osradar.com/wp-content/uploads/2020/10/1-696x414.jpg 696w, https://www.osradar.com/wp-content/uploads/2020/10/1.jpg 1043w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>After the logged in, you&#8217;ll see the welcome page.</p>



<figure class="wp-block-image size-large"><img loading="lazy" width="1024" height="697" src="//1081754738.rsc.cdn77.org/wp-content/uploads/2020/10/2-1024x697.png" alt="" class="wp-image-24211" srcset="https://www.osradar.com/wp-content/uploads/2020/10/2-1024x697.png 1024w, https://www.osradar.com/wp-content/uploads/2020/10/2-300x204.png 300w, https://www.osradar.com/wp-content/uploads/2020/10/2-768x523.png 768w, https://www.osradar.com/wp-content/uploads/2020/10/2-696x474.png 696w, https://www.osradar.com/wp-content/uploads/2020/10/2.png 1048w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>Then, navigate to the <strong>System&gt;&gt;Overview</strong> to see the status of graylog server.</p>



<figure class="wp-block-image size-large"><img loading="lazy" width="1041" height="704" src="//1081754738.rsc.cdn77.org/wp-content/uploads/2020/10/3-1024x693.png" alt="" class="wp-image-24212" srcset="https://www.osradar.com/wp-content/uploads/2020/10/3-1024x693.png 1024w, https://www.osradar.com/wp-content/uploads/2020/10/3-300x203.png 300w, https://www.osradar.com/wp-content/uploads/2020/10/3-768x519.png 768w, https://www.osradar.com/wp-content/uploads/2020/10/3-696x471.png 696w, https://www.osradar.com/wp-content/uploads/2020/10/3.png 1041w" sizes="(max-width: 1041px) 100vw, 1041px" /></figure>



<p>So, this is how you can install Graylog on Ubuntu 20.04</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-graylog-on-ubuntu-20-04/">How To Install Graylog On Ubuntu 20.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/how-to-install-graylog-on-ubuntu-20-04/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to install Graylog on Ubuntu 18.04?</title>
		<link>https://www.osradar.com/how-to-install-graylog-on-ubuntu-18-04/</link>
					<comments>https://www.osradar.com/how-to-install-graylog-on-ubuntu-18-04/#comments</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Sat, 11 Aug 2018 09:50:05 +0000</pubDate>
				<category><![CDATA[Featured]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[graylog]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[logs tutorial]]></category>
		<category><![CDATA[server]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=5185</guid>

					<description><![CDATA[<p>In large corporations you have many systems and applications running at the same time making error logging a bit complicated. In order to manage these records efficiently, specialized tools are used to centralize them. Graylog is a professional application that provides a unified and centralized system of messages from different sources: operating system, application servers, [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-graylog-on-ubuntu-18-04/">How to install Graylog on Ubuntu 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>In large corporations you have many systems and applications running at the same time making error logging a bit complicated. In order to manage these records efficiently, specialized tools are used to centralize them.</p>
<p><strong>Graylog</strong> is a professional application that provides a unified and centralized system of messages from different sources: operating system, application servers, information systems with the aim of centralizing and making easier the administration of error logs or logs.</p>
<p>In this tutorial we are going to install a Graylog server in Ubuntu 18.04.</p>
<h2>Let&#8217;s get to work</h2>
<h3>1.-Upgrading the system and Installing Oracle JDK</h3>
<p>First we proceed to update the system. Open a terminal emulator and type<strong> sudo -i</strong>, after entering the password, we can now update the system.</p>
<pre class="">:~# apt update &amp;&amp; apt upgrade</pre>
<p><figure id="attachment_5186" aria-describedby="caption-attachment-5186" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5186" src="https://www.osradar.com/wp-content/uploads/2018/08/1-2.png" alt="1.- Upgrading the system" width="1366" height="738" srcset="https://www.osradar.com/wp-content/uploads/2018/08/1-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-300x162.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-768x415.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-1024x553.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-696x376.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-1068x577.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/1-2-777x420.png 777w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5186" class="wp-caption-text">1.- Upgrading the system</figcaption></figure></p>
<p>Now we proceed to install Oracle JDK. We write for them:</p>
<pre class="">:~# apt install apt-transport-https uuid-runtime pwgen openjdk-8-jre-headless</pre>
<p><figure id="attachment_5188" aria-describedby="caption-attachment-5188" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5188" src="https://www.osradar.com/wp-content/uploads/2018/08/2-3.png" alt="2.- Installing jdk" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/2-3.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/2-3-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5188" class="wp-caption-text">2.- Installing jdk</figcaption></figure></p>
<h3>2.- Installing Elasticsearch</h3>
<p>Graylog requires the installation of <strong>elasticsearch</strong> which is a highly scalable application that allows us to perform real time searches, in addition to storing and analyzing them.</p>
<p>We will then perform a basic installation of ElasticSearch so that Graylog can run. First download and install GPG signing key.</p>
<pre class="">:~# wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -</pre>
<p><figure id="attachment_5189" aria-describedby="caption-attachment-5189" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5189" src="https://www.osradar.com/wp-content/uploads/2018/08/3-3.png" alt="3.- Adding GPG key" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/3-3.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/3-3-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5189" class="wp-caption-text">3.- Adding GPG key</figcaption></figure></p>
<p>Now we write:</p>
<pre class="">:~# echo "deb https://artifacts.elastic.co/packages/5.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-5.x.list</pre>
<p><figure id="attachment_5190" aria-describedby="caption-attachment-5190" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5190" src="https://www.osradar.com/wp-content/uploads/2018/08/4-2.png" alt="4.- Adding Elasticsearch repo" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/4-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/4-2-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5190" class="wp-caption-text">4.- Adding Elasticsearch repo</figcaption></figure></p>
<p>Next we update the repositories and install the ElasticSearch package</p>
<pre class="">:~# apt update &amp;&amp; apt install elasticsearch</pre>
<p><figure id="attachment_5191" aria-describedby="caption-attachment-5191" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5191" src="https://www.osradar.com/wp-content/uploads/2018/08/5-2.png" alt="5.- Installing elasticsearch" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/5-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/5-2-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5191" class="wp-caption-text">5.- Installing elasticsearch</figcaption></figure></p>
<p>Then we proceed to enable the service and start it.</p>
<pre class="">:~# systemctl enable elasticsearch
:~# systenctl start elasticsearch</pre>
<p><figure id="attachment_5192" aria-describedby="caption-attachment-5192" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5192" src="https://www.osradar.com/wp-content/uploads/2018/08/6-2.png" alt="6.- Enabling elasticsearch" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/6-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/6-2-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5192" class="wp-caption-text">6.- Enabling elasticsearch</figcaption></figure></p>
<p>Now we must edit the <strong>elasticsearch.yml</strong> file in order to define the name of the cluster to graylog.</p>
<pre class="">:~# nano /etc/elasticsearch/elasticsearch.yml</pre>
<p>And in the &#8220;cluster.name&#8221; and define it as graylog.</p>
<p><figure id="attachment_5193" aria-describedby="caption-attachment-5193" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5193" src="https://www.osradar.com/wp-content/uploads/2018/08/7-2.png" alt="7.- Editing elasticsearch config file" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/7-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/7-2-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5193" class="wp-caption-text">7.- Editing elasticsearch config file</figcaption></figure></p>
<p>We must also add these lines:</p>
<pre class="">script.inline: false
script.indexed: false
script.file: false</pre>
<p><figure id="attachment_5194" aria-describedby="caption-attachment-5194" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5194" src="https://www.osradar.com/wp-content/uploads/2018/08/8-1.png" alt="8.- Editing elasticsearch config file" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/8-1.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/8-1-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5194" class="wp-caption-text">8.- Editing elasticsearch config file</figcaption></figure></p>
<p>Finally we restart the elasticsearch service</p>
<pre class="">:~# systemctl restart elasticsearch</pre>
<h3>3.- MongoDB&#8217;s turns</h3>
<p>Now we must install mongoDB. To do this, we will first add the gpg key.</p>
<pre class="">:~# apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5</pre>
<p><figure id="attachment_5196" aria-describedby="caption-attachment-5196" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5196" src="https://www.osradar.com/wp-content/uploads/2018/08/9-3.png" alt="9.- importing gpg key" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/9-3.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/9-3-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5196" class="wp-caption-text">9.- importing gpg key</figcaption></figure></p>
<p>Then we add the mongoDB repository</p>
<pre class="">:~# echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.6 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list</pre>
<p><figure id="attachment_5197" aria-describedby="caption-attachment-5197" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5197" src="https://www.osradar.com/wp-content/uploads/2018/08/10-1.png" alt="10.- Adding repository" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/10-1.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/10-1-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5197" class="wp-caption-text">10.- Adding repository</figcaption></figure></p>
<p>We update the repository cache and then install mongodb</p>
<pre class="">:~# apt update &amp;&amp; apt install mongodb-org</pre>
<p><figure id="attachment_5198" aria-describedby="caption-attachment-5198" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5198" src="https://www.osradar.com/wp-content/uploads/2018/08/11-1.png" alt="11.- Installing mongoDB" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/11-1.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/11-1-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5198" class="wp-caption-text">11.- Installing mongoDB</figcaption></figure></p>
<p>Now we start the service and make sure it starts with the system</p>
<pre class="">:~# systemctl start mongod
:~# systemctl enable mongod</pre>
<p><figure id="attachment_5228" aria-describedby="caption-attachment-5228" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5228" src="https://www.osradar.com/wp-content/uploads/2018/08/12-2.png" alt="12.- Enabling mongodb service" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/12-2.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/12-2-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5228" class="wp-caption-text">12.- Enabling mongodb service</figcaption></figure></p>
<h3>4.- Installing Graylog</h3>
<p>At last it&#8217;s GRaylog&#8217;s turn, first we download the package that adds the repository.</p>
<pre class="">:~#  wget https://packages.graylog2.org/repo/packages/graylog-2.4-repository_latest.deb</pre>
<p>Then we install it:</p>
<pre class="">:~# dpkg -i graylog-2.4-repository_latest.deb</pre>
<p><figure id="attachment_5229" aria-describedby="caption-attachment-5229" style="width: 1363px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5229" src="https://www.osradar.com/wp-content/uploads/2018/08/13.png" alt="13.- adding graylog repository" width="1363" height="428" srcset="https://www.osradar.com/wp-content/uploads/2018/08/13.png 1363w, https://www.osradar.com/wp-content/uploads/2018/08/13-300x94.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/13-768x241.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/13-1024x322.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/13-696x219.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/13-1068x335.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/13-1338x420.png 1338w" sizes="(max-width: 1363px) 100vw, 1363px" /><figcaption id="caption-attachment-5229" class="wp-caption-text">13.- adding graylog repository</figcaption></figure></p>
<p>And now we install the Graylog package:</p>
<pre class="">:~# apt update &amp;&amp; apt install graylog-server</pre>
<p><figure id="attachment_5230" aria-describedby="caption-attachment-5230" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5230" src="https://www.osradar.com/wp-content/uploads/2018/08/14.png" alt="13.- adding graylog repository" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/14.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/14-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/14-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/14-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/14-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/14-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/14-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5230" class="wp-caption-text">14.- installing graylog package</figcaption></figure></p>
<p>Once the installation of the Graylog package is finished, we will have to edit the configuration file to set our password in it. in the same file, we are told that it must be 64 characters, to generate it, we will use pwgen:</p>
<pre class="">:~# pwgen -N 1 -s 96</pre>
<p><figure id="attachment_5250" aria-describedby="caption-attachment-5250" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5250" src="https://www.osradar.com/wp-content/uploads/2018/08/15.png" alt="15.- Generating the password" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/15.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/15-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/15-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/15-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/15-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/15-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/15-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5250" class="wp-caption-text">15.- Generating the password</figcaption></figure></p>
<p>And we put it in the file.</p>
<p><figure id="attachment_5251" aria-describedby="caption-attachment-5251" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5251" src="https://www.osradar.com/wp-content/uploads/2018/08/16.png" alt="16.- setting the password" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/16.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/16-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/16-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/16-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/16-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/16-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/16-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5251" class="wp-caption-text">16.- setting the password</figcaption></figure></p>
<p>Next we must generate a hash for the password.</p>
<pre class="">:~# echo -n your_password | sha256sum</pre>
<p><figure id="attachment_5252" aria-describedby="caption-attachment-5252" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5252" src="https://www.osradar.com/wp-content/uploads/2018/08/17.png" alt="17.- Hashing the password" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/17.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/17-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/17-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/17-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/17-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/17-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/17-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5252" class="wp-caption-text">17.- Hashing the password</figcaption></figure></p>
<p>Place the hash password. Additionally, we can put the email address of the root user, and their time zone.</p>
<p><figure id="attachment_5253" aria-describedby="caption-attachment-5253" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5253" src="https://www.osradar.com/wp-content/uploads/2018/08/18.png" alt="18.- Editing graylog server conf file" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/18.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/18-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/18-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/18-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/18-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/18-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/18-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5253" class="wp-caption-text">18.- Editing graylog server conf file</figcaption></figure></p>
<p>Then we must add this line to the end of the file:</p>
<pre class="">elasticsearch_discovery_zen_ping_unicast_hosts = ip_server:9300</pre>
<p>Next, in elasticsearch_shards we define the number of nodes; in our case 1. And in elasticsearch_replicas the number of replica nodes that are in our cluster. 0 in this case.</p>
<p><figure id="attachment_5254" aria-describedby="caption-attachment-5254" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5254" src="https://www.osradar.com/wp-content/uploads/2018/08/19.png" alt="19.- editing graylog server conf file" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/19.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/19-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/19-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/19-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/19-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/19-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/19-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5254" class="wp-caption-text">19.- editing graylog server conf file</figcaption></figure></p>
<h3>5.- Graylog web interface</h3>
<p>Since version 2 of Graylog, its web interface is incorporated, we only have to edit the server.conf file to define some important parameters.</p>
<pre class="">:~#  nano /etc/graylog/server/server.conf</pre>
<p>And we edit the file with these two parameters</p>
<pre class="">web_listen_uri = http://ip_server:9000/
web_listen_uri = http://ip_server:9000/</pre>
<p>We then restart the service</p>
<pre class="">:~# systemctl restart graylog-server</pre>
<p><figure id="attachment_5255" aria-describedby="caption-attachment-5255" style="width: 1366px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5255" src="https://www.osradar.com/wp-content/uploads/2018/08/20.png" alt="20.- restarting graylog" width="1366" height="740" srcset="https://www.osradar.com/wp-content/uploads/2018/08/20.png 1366w, https://www.osradar.com/wp-content/uploads/2018/08/20-300x163.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/20-768x416.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/20-1024x555.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/20-696x377.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/20-1068x579.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/20-775x420.png 775w" sizes="(max-width: 1366px) 100vw, 1366px" /><figcaption id="caption-attachment-5255" class="wp-caption-text">20.- restarting graylog</figcaption></figure></p>
<p>Now we only have to access our graylog from the web.</p>
<p><strong>http://Ip_server:9000</strong></p>
<p>And that&#8217;s it, we&#8217;re done, just start configuring graylog from your web interface.</p>
<p><figure id="attachment_5256" aria-describedby="caption-attachment-5256" style="width: 1238px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-5256" src="https://www.osradar.com/wp-content/uploads/2018/08/21.png" alt="21.- Accessing graylog" width="1238" height="584" srcset="https://www.osradar.com/wp-content/uploads/2018/08/21.png 1238w, https://www.osradar.com/wp-content/uploads/2018/08/21-300x142.png 300w, https://www.osradar.com/wp-content/uploads/2018/08/21-768x362.png 768w, https://www.osradar.com/wp-content/uploads/2018/08/21-1024x483.png 1024w, https://www.osradar.com/wp-content/uploads/2018/08/21-696x328.png 696w, https://www.osradar.com/wp-content/uploads/2018/08/21-1068x504.png 1068w, https://www.osradar.com/wp-content/uploads/2018/08/21-890x420.png 890w" sizes="(max-width: 1238px) 100vw, 1238px" /><figcaption id="caption-attachment-5256" class="wp-caption-text">21.- Accessing graylog</figcaption></figure></p>
<p>A reminder, the password field is in the root_password_sha2 field of the server.conf file.</p>
<p>Please spread this article through social networks.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-graylog-on-ubuntu-18-04/">How to install Graylog on Ubuntu 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/how-to-install-graylog-on-ubuntu-18-04/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
