<?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>gugaBSD</title>
	<atom:link href="http://www.luizgustavo.pro.br/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.luizgustavo.pro.br/blog</link>
	<description>Software Livre, BSD e outras coisas mais...</description>
	<lastBuildDate>Mon, 14 May 2012 20:18:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Lançado oficialmente o FreeBSD 9.0</title>
		<link>http://www.luizgustavo.pro.br/blog/2012/01/12/lancado-oficialmente-o-freebsd-9-0/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2012/01/12/lancado-oficialmente-o-freebsd-9-0/#comments</comments>
		<pubDate>Thu, 12 Jan 2012 22:25:12 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[lançamento]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=716</guid>
		<description><![CDATA[O primeiro post do ano no meu blog não poderia ser melhor, acaba de ser anunciado oficialmente o lançamento da versão RELEASE do FreeBSD 9.0. É uma versão que era esperada com muito ansiedade por muita gente, afinal, varias alterações significativas foram adicionadas nessa nova familia de versão. Dentre as principais, quero destacar: Novo instalador [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/freebsd-logo.png"><img class="alignright size-full wp-image-269" title="freebsd-logo" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/freebsd-logo.png" alt="" width="178" height="175" /></a>O primeiro post do ano no meu blog não poderia ser melhor, acaba de ser anunciado oficialmente o lançamento da versão RELEASE do <strong>FreeBSD 9.0</strong>. É uma versão que era esperada com muito ansiedade por muita gente, afinal, varias alterações significativas foram adicionadas nessa nova familia de versão.</p>
<p>Dentre as principais, quero destacar:</p>
<ul>
<li>Novo instalador</li>
<li>Suporte nativo ao novo journaling SUJ</li>
<li>Suporte nativo ao HAST para HA de disco</li>
<li>Código do sistema base preparado para ser compilado com LLVM</li>
</ul>
<p>Veja a página oficial de lançamento da versão com todas as informações sobre essa versão no link abaixo (em inglês):</p>
<p><a href="http://www.freebsd.org/releases/9.0R/announce.html" target="_blank">http://www.freebsd.org/releases/9.0R/announce.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2012/01/12/lancado-oficialmente-o-freebsd-9-0/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>RIP: Irado Furioso com Tudo !!!</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/30/rip-irado-furioso-com-tudo/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/30/rip-irado-furioso-com-tudo/#comments</comments>
		<pubDate>Fri, 30 Dec 2011 21:17:59 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[Diversos]]></category>
		<category><![CDATA[Irado Furioso com Tudod]]></category>
		<category><![CDATA[luto]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=712</guid>
		<description><![CDATA[Com tristeza e pesar que crio esse post, infelizmente, depois da averiguação de nossos amigos da FUG, após algum tempo sem postar nada na lista, foi-se verificado que nosso caro amigo Irado faleceu. Não tive a oportunidade de conhece-lo pessoalmente, mas troquei altos papos com o nobre colega, não só assunto técnico, com ele se [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/12/075.gif"><img class="alignleft size-full wp-image-713" style="margin: 5px;" title="075" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/12/075.gif" alt="" width="135" height="135" /></a>Com tristeza e pesar que crio esse post, infelizmente, depois da averiguação de nossos amigos da FUG, após algum tempo sem postar nada na lista, foi-se verificado que nosso caro amigo Irado faleceu.</p>
<p style="text-align: justify;">Não tive a oportunidade de conhece-lo pessoalmente, mas troquei altos papos com o nobre colega, não só assunto técnico, com ele se podia conversar quase tudo.</p>
<p style="text-align: justify;">Sempre sarcástico, já começando pelo o seu nick &#8220;Irado Furioso com Tudo&#8221;, foi um cara que como todo mundo por ai diz: &#8220;Ensinou a pescar&#8221;, muita gente aprendeu com sua experiência, eu mesmo tenho alguns emails dele impresso em papel continuo dos primórdios do OpenSource.</p>
<p style="text-align: justify;">Eita saudade, mas acredito que o pessoal lá em cima esteja precisando de pessoal especializado, vejamos que esse ano tivemos perdas importantes no mundo do TI e com certeza, com todo o seu merecimento, Irado foi uma delas.</p>
<p>Vai com <strong>Deus</strong> meu irmão ! vai preparando a rede ai pra quando um dia chegar-mos ai a coisa toda esteja tinindo !</p>
<p>IRADO FURIOSO COM TUDO !!!</p>
<pre><strong>flames &gt; /dev/null (by Irado)</strong></pre>
<p>Veja a integra do email do Patrick sobre a noticia do falecimento do Irado, no link abaixo:<br />
<a href="http://www.fug.com.br/historico/html/freebsd/2011-12/msg00389.html">http://www.fug.com.br/historico/html/freebsd/2011-12/msg00389.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/30/rip-irado-furioso-com-tudo/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Lançada versão 2.0.1 do Pfsense</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/21/lancada-versao-2-0-1-do-pfsense/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/21/lancada-versao-2-0-1-do-pfsense/#comments</comments>
		<pubDate>Wed, 21 Dec 2011 09:42:07 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[pfSense]]></category>
		<category><![CDATA[lançamento]]></category>
		<category><![CDATA[pfsense]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=708</guid>
		<description><![CDATA[A versão 2.0.1 do pfSense esta disponivel para download, A noticia dizia que os mirrors estavam sendo sincronizados no momento no anuncio, mas acredito que pelo o tempo que estou traduzindo este anuncio já devam estar sincronizados. Esta versão é um release para corrigir alguns bugs e solucionar alguns problemas de segurança da versão 2.0. [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/pfsense_logo_menor.png"><img class="alignleft size-full wp-image-195" style="margin: 5px;" title="pfsense_logo_menor" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/pfsense_logo_menor.png" alt="" width="112" height="105" /></a>A versão 2.0.1 do pfSense esta disponivel para download, A noticia dizia que os mirrors estavam sendo sincronizados no momento no anuncio, mas acredito que pelo o tempo que estou traduzindo este anuncio já devam estar sincronizados. Esta versão é um release para corrigir alguns bugs e solucionar alguns problemas de segurança da versão 2.0. É recomendavel que se faça a atualização. Como sempre, você pode atualizar a partir de qualquer versão anterior a 2.0.1, se você ainda não tiver atualizado seu pfSense para o 2.0 e quiser atualiza-lo, faça diretamente para a versão 2.0.1.</p>
<p>Para quem usa o gereciamento de Certificado para criar certificados, preste atenção as notas fornecidas no texto indicado no link abaixo.</p>
<p>Veja a integra das informações de atualização e os itens atualizados no link abaixo:</p>
<p><a href="http://blog.pfsense.org/?p=633" target="_blank">http://blog.pfsense.org/?p=633</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/21/lancada-versao-2-0-1-do-pfsense/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Centreon 2.3.3 on FreeBSD 9 (update)</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/09/english-centreon-2-3-3-freebsd-9/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/09/english-centreon-2-3-3-freebsd-9/#comments</comments>
		<pubDate>Fri, 09 Dec 2011 02:32:19 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[mundoUnix]]></category>
		<category><![CDATA[Software Livre]]></category>
		<category><![CDATA[centreon]]></category>
		<category><![CDATA[monitoramento]]></category>
		<category><![CDATA[nagios]]></category>
		<category><![CDATA[SNMP]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/2011/12/09/english-centreon-2-3-3-freebsd-9/</guid>
		<description><![CDATA[This tutorial will guide the user to complete the installation of Centreon on FreeBSD. We will be using an installation on a FreeBSD 9.0-PRERELEASE kernel version, kernel version does not influence the tutorial. It may be FreeBSD 8.x or 9.x What is the Centreon? Centreon is a powerful tool for monitoring hosts and services, it [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/centreon_bsd.png"><img class="aligncenter size-full wp-image-367" title="centreon_bsd" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/centreon_bsd.png" alt="" width="250" height="81" /></a>This tutorial will guide the user to complete the installation of Centreon on FreeBSD. We will be using an installation on a FreeBSD 9.0-PRERELEASE kernel version, kernel version does not influence the tutorial. It may be FreeBSD 8.x or 9.x</p>
<p>What is the Centreon?</p>
<p>Centreon is a powerful tool for monitoring hosts and services, it is a frontend that works on top of Nagios, adding many features for viewing and alert history, status, etc. ..</p>
<h4 style="text-align: center;">Need Support ? <a href="http://mundounix.com.br/wp/monitoramento-de-redes/" target="_blank">Click Here !</a></h4>
<p style="text-align: center;"><img class="aligncenter size-full wp-image-386" title="monitoramento_diagrama" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/monitoramento_diagrama.png" alt="" width="467" height="420" /></p>
<p>To learn more about the tool, I invite you to visit the official site at <a title="http://www.centreon.com" href="http://www.centreon.com/" rel="nofollow">http://www.centreon.com</a></p>
<p>What we need? ?</p>
<div>
<ul>
<li>Apache</li>
<li><acronym title="Hypertext Preprocessor">PHP</acronym> 5.3.x + a lot of dependencies</li>
<li>Mysql</li>
<li>Nagios</li>
<li>Pear + a lot of dependencies</li>
<li><acronym title="Practical Extraction and Report Language">Perl</acronym> + a lot of dependencies</li>
<li>rrdtool</li>
<li>snmp</li>
<li>sudo</li>
<li>Centreon (obvious :-p)</li>
</ul>
</div>
<p><span id="more-704"></span></p>
<h4>Starting installation of packages</h4>
<p>For this tutorial, we will use the tool <a href="http://www.freebsd.org/cgi/url.cgi?ports/ports-mgmt/portmaster/pkg-descr" target="_blank">portmaster</a>, you can even do all the installation manually, but I advise u to use the tool in order to facilitate the installation of the dependencies and the amount of packages that we need.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports<span style="color: #000000; font-weight: bold;">/</span>ports-mgmt<span style="color: #000000; font-weight: bold;">/</span>portmaster
<span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span> clean</pre></div></div>

<p>if you are using csh shell</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">rehash</pre></div></div>

<p>We start by some common packages to provide the Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># In the package configurations, keep the default settings or to your liking.</span>
portmaster <span style="color: #660033;">-d</span> lang<span style="color: #000000; font-weight: bold;">/</span>perl5.12 www<span style="color: #000000; font-weight: bold;">/</span>apache22 shells<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span> security<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">sudo</span> net-mgmt<span style="color: #000000; font-weight: bold;">/</span>net-snmp net-mgmt<span style="color: #000000; font-weight: bold;">/</span>snmptt</pre></div></div>

<p>Installing our database (if using MySQL outside, only install mysql-client)</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> databases<span style="color: #000000; font-weight: bold;">/</span>mysql51-client databases<span style="color: #000000; font-weight: bold;">/</span>mysql51-server</pre></div></div>

<p>Let&#8217;s go, install the PHP:</p>
<p>Attention to configure PHP5 package, you need some options checked, at least those which are listed below:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"> │ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> CLI        Build CLI version                               │ │
 │ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> APACHE     Build Apache module                             │ │</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> lang<span style="color: #000000; font-weight: bold;">/</span>php5 databases<span style="color: #000000; font-weight: bold;">/</span>php5-mysql graphics<span style="color: #000000; font-weight: bold;">/</span>php5-gd 
	www<span style="color: #000000; font-weight: bold;">/</span>php5-session archivers<span style="color: #000000; font-weight: bold;">/</span>php5-zlib 
	sysutils<span style="color: #000000; font-weight: bold;">/</span>php5-posix security<span style="color: #000000; font-weight: bold;">/</span>php5-filter 
	converters<span style="color: #000000; font-weight: bold;">/</span>php5-mbstring textproc<span style="color: #000000; font-weight: bold;">/</span>php5-xml 
	devel<span style="color: #000000; font-weight: bold;">/</span>php5-gettext textproc<span style="color: #000000; font-weight: bold;">/</span>php5-xmlwriter</pre></div></div>

<p>PEAR:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> devel<span style="color: #000000; font-weight: bold;">/</span>pear databases<span style="color: #000000; font-weight: bold;">/</span>pear-DB_DataObject databases<span style="color: #000000; font-weight: bold;">/</span>pear-DB_DataObject_FormBuilder 
	databases<span style="color: #000000; font-weight: bold;">/</span>pear-MDB2 textproc<span style="color: #000000; font-weight: bold;">/</span>pear-Numbers_Roman 
	textproc<span style="color: #000000; font-weight: bold;">/</span>pear-Numbers_Words devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_QuickForm2 
	devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_QuickForm_advmultiselect net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_Traceroute 
	net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_Ping devel<span style="color: #000000; font-weight: bold;">/</span>pear-Validate net<span style="color: #000000; font-weight: bold;">/</span>pear-XML_RPC 
	mail<span style="color: #000000; font-weight: bold;">/</span>pear-Mail mail<span style="color: #000000; font-weight: bold;">/</span>pear-Mail_Mime www<span style="color: #000000; font-weight: bold;">/</span>pear-HTTP net<span style="color: #000000; font-weight: bold;">/</span>pear-SOAP 
	devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_Table security<span style="color: #000000; font-weight: bold;">/</span>pear-Auth_SASL net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_SMTP 
	graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_Canvas graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_Graph 
	graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_GraphViz</pre></div></div>

<p>Let&#8217;s go to the part of Perl:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> devel<span style="color: #000000; font-weight: bold;">/</span>p5-Config-IniFiles graphics<span style="color: #000000; font-weight: bold;">/</span>p5-GD 
	databases<span style="color: #000000; font-weight: bold;">/</span>p5-DBD-mysql security<span style="color: #000000; font-weight: bold;">/</span>p5-Crypt-DES 
	security<span style="color: #000000; font-weight: bold;">/</span>p5-Digest-HMAC net-mgmt<span style="color: #000000; font-weight: bold;">/</span>p5-Net-SNMP</pre></div></div>

<h4 style="text-align: center;">Problems with network? implementing security? <a href="http://mundounix.com.br/wp/consultoria-linuxbsd/" target="_blank">click here !</a></h4>
<p>An important tool that can not miss in our environment:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> databases<span style="color: #000000; font-weight: bold;">/</span>rrdtool</pre></div></div>

<p>And our background of Centreon, Nagios!</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> net-mgmt<span style="color: #000000; font-weight: bold;">/</span>nagios net-mgmt<span style="color: #000000; font-weight: bold;">/</span>ndoutils</pre></div></div>

<p>Check the options:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> EMBEDDED_PERL   Enable embedded Perl <span style="color: #7a0874; font-weight: bold;">&#91;</span>requires Perl 5.8.0+<span style="color: #7a0874; font-weight: bold;">&#93;</span> │ │
│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> NANOSLEEP       Use nanosleep <span style="color: #000000; font-weight: bold;">in</span> event timing               │ │
│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> EVENT_BROKER    Enable event broker functionality           │ │</pre></div></div>

<p>Nagios-plugins:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> FPING    Support <span style="color: #000000; font-weight: bold;">for</span> non-flooding fast <span style="color: #c20cb9; font-weight: bold;">ping</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>check_fping<span style="color: #7a0874; font-weight: bold;">&#41;</span>  │ │
│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> NETSNMP  SNMP support <span style="color: #7a0874; font-weight: bold;">&#40;</span>check_snmp<span style="color: #7a0874; font-weight: bold;">&#41;</span>                         │ │</pre></div></div>

<p>If installing in a Jail, check below:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> JAIL     Compilation within jail<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">8</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>see Makefile<span style="color: #7a0874; font-weight: bold;">&#41;</span>         │ │</pre></div></div>

<p>ndoutils:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> MYSQL  MySQL Backend  			                   │ │</pre></div></div>

<p>Let&#8217;s settings for some packages:</p>
<p>if you are using csh shell</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">rehash</pre></div></div>

<p>PHP:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc
<span style="color: #c20cb9; font-weight: bold;">cp</span> php.ini-production php.ini
<span style="color: #666666; font-style: italic;"># Set the time zone for your location</span>
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/;date.timezone =/date.timezone = America/Sao_Paulo/'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>php.ini</pre></div></div>

<p>Apache:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'apache22_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;AddType application/x-httpd-php .php&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>Includes<span style="color: #000000; font-weight: bold;">/</span>php.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;AddType application/x-httpd-php-source .phps&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>Includes<span style="color: #000000; font-weight: bold;">/</span>php.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/DirectoryIndex index.html/DirectoryIndex index.html index.php/g'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>httpd.conf
&nbsp;
<span style="color: #666666; font-style: italic;"># Make sure your hosts file (/etc/hosts) or internal DNS is working properly</span>
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>apache22 start</pre></div></div>

<p>Mysql:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'mysql_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>mysql-server start
<span style="color: #666666; font-style: italic;"># set the root password for mysql</span>
mysqladmin <span style="color: #660033;">-u</span> root password <span style="color: #ff0000;">&quot;new-password&quot;</span></pre></div></div>

<p>SNMP:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_flags=&quot;-a&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_conffile=&quot;/usr/local/etc/snmp/snmpd.conf&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmptrapd_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmptrapd_flags=&quot;-a -p /var/run/snmptrapd.pid&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
&nbsp;
<span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp
<span style="color: #c20cb9; font-weight: bold;">cp</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>share<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf.example <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/rocommunity public  default    -V systemonly/rocommunity public default/g'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/agentAddress  udp:127.0.0.1:161/#agentAddress  udp:127.0.0.1:161/'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>snmpd start
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>snmptrapd start</pre></div></div>

<p>Fix the file <strong><span style="text-decoration: underline;">/usr/local/etc/snmp/snmpd.conf</span></strong> with location information and identification.</p>
<p><em></em>If you are installing snmpd in a Jail, see this article for the same operation in Jail:<br />
<a href="http://ggeek.blogspot.com/2008/10/freebsd-jails-and-net-snmp.html" target="_blank">http://ggeek.blogspot.com/2008/10/freebsd-jails-and-net-snmp.html</a></p>
<h4 style="text-align: center;">Consulting in Open Source, <a href="http://mundounix.com.br/wp/consultoria/" target="_blank">contact us!</a></h4>
<p>Nagios:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sh</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">ls</span> <span style="color: #660033;">-1</span> <span style="color: #000000; font-weight: bold;">*</span>-sample <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #c20cb9; font-weight: bold;">read</span> arq ; <span style="color: #000000; font-weight: bold;">do</span> <span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">cut</span> <span style="color: #660033;">-f1</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">'-'</span><span style="color: #000000; font-weight: bold;">`</span> ; <span style="color: #000000; font-weight: bold;">done</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> objects<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">ls</span> <span style="color: #660033;">-1</span> <span style="color: #000000; font-weight: bold;">*</span>-sample <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #c20cb9; font-weight: bold;">read</span> arq ; <span style="color: #000000; font-weight: bold;">do</span> <span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">cut</span> <span style="color: #660033;">-f1</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">'-'</span><span style="color: #000000; font-weight: bold;">`</span> ; <span style="color: #000000; font-weight: bold;">done</span>
<span style="color: #7a0874; font-weight: bold;">exit</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'nagios_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>nagios start</pre></div></div>

<p>NDOUtils:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'ndo2db_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf</pre></div></div>

<p>Download Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>tmp
fetch http:<span style="color: #000000; font-weight: bold;">//</span>download.centreon.com<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>centreon-2.3.3.tar.gz
<span style="color: #c20cb9; font-weight: bold;">tar</span> zxf centreon-2.3.3.tar.gz
<span style="color: #7a0874; font-weight: bold;">cd</span> centreon-2.3.3</pre></div></div>

<p>Making Centreon read the bash shell</p>
<p>There are two ways (choose one):</p>
<p>- Changing the path the scripts Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s//bin/bash//usr/local/bin/bash/g'</span> install.sh
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s//bin/bash//usr/local/bin/bash/g'</span> libinstall<span style="color: #000000; font-weight: bold;">/*</span></pre></div></div>

<p>- Creating a symbolic link in /bin</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span></pre></div></div>

<p>Some preparations for the installation:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d
fetch <span style="color: #660033;">-o</span> tmpl<span style="color: #000000; font-weight: bold;">/</span>vardistrib<span style="color: #000000; font-weight: bold;">/</span>freebsd http:<span style="color: #000000; font-weight: bold;">//</span>www.luizgustavo.pro.br<span style="color: #000000; font-weight: bold;">/</span>downloads<span style="color: #000000; font-weight: bold;">/</span>freebsd.txt</pre></div></div>

<p>Now start the installation via the command:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">bash</span> install.sh <span style="color: #660033;">-f</span> tmpl<span style="color: #000000; font-weight: bold;">/</span>vardistrib<span style="color: #000000; font-weight: bold;">/</span>freebsd</pre></div></div>

<p>Follow the installation process through the video below:</p>
<p><iframe src="http://www.youtube.com/embed/h3QensGRZeA?rel=0" frameborder="0" width="520" height="350"></iframe></p>
<p>After installation, we will leave for the web part to do so, restart MySQL and Apache:</p>
<div>
<div>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>mysql-server restart</pre></div></div>

</div>
</div>
<p>We fix some patches of permission:</p>
<div>
<div>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon
<span style="color: #c20cb9; font-weight: bold;">rm</span> filesGeneration
<span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesGeneration .
<span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www filesGeneration
<span style="color: #c20cb9; font-weight: bold;">rm</span> filesUpload
<span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesUpload .
<span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www filesUpload
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesGeneration
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesUpload</pre></div></div>

</div>
</div>
<p>We also fix a problem of dependence on the version of PEAR:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>pear uninstall HTML_QuickForm_advmultiselect 
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>pear <span style="color: #c20cb9; font-weight: bold;">install</span> <span style="color: #660033;">-f</span> pear<span style="color: #000000; font-weight: bold;">/</span>HTML_QuickForm_advmultiselect-1.2.0</pre></div></div>

<p><em>Now this way, we can point to our broswer centreon server address:</em></p>
<pre>http://&lt;ip_or_url&gt;/centreon</pre>
<h4>Follow the video to configure the web:</h4>
<p><iframe src="http://www.youtube.com/embed/0NUwmVmcfKA?rel=0" frameborder="0" width="520" height="360"></iframe></p>
<p><strong>There is less, we still need to export the configuration files for our NDO-Utils to work for it, follow the export of the same video on the web:</strong></p>
<p><iframe src="http://www.youtube.com/embed/UdebdL-AaN0?rel=0" frameborder="0" width="520" height="360"></iframe></p>
<p>Now, let&#8217;s start the processes of Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">pw user mod nagios <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">sh</span>
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>centcore start
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>centstorage start</pre></div></div>

<p>Setting the part of the CRON to FreeBSD:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">cat</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d<span style="color: #000000; font-weight: bold;">/*</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>crontab
<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>cron restart
<span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-rf</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d</pre></div></div>

<p>Restart nagios processes and ndoutils</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>nagios restart
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>ndo2db restart</pre></div></div>

<p>Ready! Now just configure your hosts and start monitoring.</p>
<p><a href="http://www.mundounix.com.br/"><img class="alignleft" title="logo_mundounix3" src="http://luizgustavo.pro.br/blog/wp-content/uploads/2009/09/logo_mundounix3.png" alt="" width="284" height="72" /></a><em><strong>If you need support Centreon, contact the <a href="http://www.mundounix.com.br/" target="_blank">Mundounix</a>, we offer support and advice for network monitoring solution.</strong></em></p>
<p><a href="http://www.mundounix.com.br/" target="_blank">http://www.mundounix.com.br</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/09/english-centreon-2-3-3-freebsd-9/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Centreon 2.3.3 no FreeBSD 9 (atualizado)</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/08/centreon-2-3-3-freebsd9/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/08/centreon-2-3-3-freebsd9/#comments</comments>
		<pubDate>Thu, 08 Dec 2011 22:20:09 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[mundoUnix]]></category>
		<category><![CDATA[Software Livre]]></category>
		<category><![CDATA[centreon]]></category>
		<category><![CDATA[monitoramento]]></category>
		<category><![CDATA[nagios]]></category>
		<category><![CDATA[SNMP]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=674</guid>
		<description><![CDATA[Este tutorial vai orientar o usuário a efetuar a instalação do Centreon no FreeBSD. Estaremos utilizando uma instalação em um FreeBSD com kernel versão 9.0-PRERELEASE, a versão do kernel não influenciará no tutorial. Pode ser FreeBSD 8.x ou 9.x O que é o Centreon ? Centreon é uma poderosa ferramenta de monitoramento de hosts e [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/centreon_bsd.png"><img class="aligncenter size-full wp-image-367" title="centreon_bsd" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/centreon_bsd.png" alt="" width="250" height="81" /></a>Este tutorial vai orientar o usuário a efetuar a instalação do Centreon no FreeBSD. Estaremos utilizando uma instalação em um FreeBSD com kernel versão 9.0-PRERELEASE, a versão do kernel não influenciará no tutorial. Pode ser FreeBSD 8.x ou 9.x</p>
<h4>O que é o Centreon ?</h4>
<p>Centreon é uma poderosa ferramenta de monitoramento de hosts e serviços, ele é um frontend que funciona em cima do Nagios, adicionando muitas facilidades para visualização e histórico de alertas, estatus, etc..</p>
<h4 style="text-align: center;">Precisa de suporte ? <a href="http://mundounix.com.br/wp/monitoramento-de-redes/" target="_blank">Clique aqui !</a></h4>
<p style="text-align: center;"><img class="aligncenter size-full wp-image-386" title="monitoramento_diagrama" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/monitoramento_diagrama.png" alt="" width="467" height="420" /></p>
<p>Para conhecer um pouco mais sobre a ferramenta, eu lhe convido a visitar o site oficial no endereço <a title="http://www.centreon.com" href="http://www.centreon.com/" rel="nofollow">http://www.centreon.com</a></p>
<p>O que nós vamos precisar ?</p>
<div>
<ul>
<li>Apache</li>
<li><acronym title="Hypertext Preprocessor">PHP</acronym> 5.3.x + um monte de dependências</li>
<li>Mysql</li>
<li>Nagios</li>
<li>Pear + um monte de dependências</li>
<li><acronym title="Practical Extraction and Report Language">Perl</acronym> + um monte de dependências</li>
<li>rrdtool</li>
<li>snmp</li>
<li>sudo</li>
<li>Centreon (óbvio :-p)</li>
</ul>
</div>
<p><span id="more-674"></span></p>
<h4>Iniciando a instalação dos pacotes</h4>
<p>Para este tutorial, nos iremos usar a ferramenta <a href="http://www.freebsd.org/cgi/url.cgi?ports/ports-mgmt/portmaster/pkg-descr" target="_blank">portmaster</a>, você até podera fazer toda a instalação manualmente, mas u aconselho o uso da ferramenta, afim de facilitar a instalação das dependências e pela a quantidade de pacotes que iremos precisar.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports<span style="color: #000000; font-weight: bold;">/</span>ports-mgmt<span style="color: #000000; font-weight: bold;">/</span>portmaster
<span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span> clean</pre></div></div>

<p>se estiver usando o shell csh</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">rehash</pre></div></div>

<p>Começamos por alguns pacotes comuns para prover o Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># Nas configurações de pacotes, mantenha as opções default ou a seu gosto.</span>
portmaster <span style="color: #660033;">-d</span> lang<span style="color: #000000; font-weight: bold;">/</span>perl5.12 www<span style="color: #000000; font-weight: bold;">/</span>apache22 shells<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span> security<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">sudo</span> net-mgmt<span style="color: #000000; font-weight: bold;">/</span>net-snmp net-mgmt<span style="color: #000000; font-weight: bold;">/</span>snmptt</pre></div></div>

<p>Instalando nosso banco de dados (se for usar o Mysql fora, instale somente o mysql-client)</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> databases<span style="color: #000000; font-weight: bold;">/</span>mysql51-client databases<span style="color: #000000; font-weight: bold;">/</span>mysql51-server</pre></div></div>

<p>Vamos instalar o PHP:</p>
<p>Atenção ao configurar o pacote PHP5, você precisará de algumas opções marcadas, pelo menos as que estão listadas abaixo:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"> │ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> CLI        Build CLI version                               │ │
 │ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> APACHE     Build Apache module                             │ │</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> lang<span style="color: #000000; font-weight: bold;">/</span>php5 databases<span style="color: #000000; font-weight: bold;">/</span>php5-mysql graphics<span style="color: #000000; font-weight: bold;">/</span>php5-gd \
	www<span style="color: #000000; font-weight: bold;">/</span>php5-session archivers<span style="color: #000000; font-weight: bold;">/</span>php5-zlib \
	sysutils<span style="color: #000000; font-weight: bold;">/</span>php5-posix security<span style="color: #000000; font-weight: bold;">/</span>php5-filter \
	converters<span style="color: #000000; font-weight: bold;">/</span>php5-mbstring textproc<span style="color: #000000; font-weight: bold;">/</span>php5-xml \
	devel<span style="color: #000000; font-weight: bold;">/</span>php5-gettext textproc<span style="color: #000000; font-weight: bold;">/</span>php5-xmlwriter</pre></div></div>

<p>PEAR:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> devel<span style="color: #000000; font-weight: bold;">/</span>pear databases<span style="color: #000000; font-weight: bold;">/</span>pear-DB_DataObject databases<span style="color: #000000; font-weight: bold;">/</span>pear-DB_DataObject_FormBuilder \
	databases<span style="color: #000000; font-weight: bold;">/</span>pear-MDB2 textproc<span style="color: #000000; font-weight: bold;">/</span>pear-Numbers_Roman \
	textproc<span style="color: #000000; font-weight: bold;">/</span>pear-Numbers_Words devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_QuickForm2 \
	devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_QuickForm_advmultiselect net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_Traceroute \
	net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_Ping devel<span style="color: #000000; font-weight: bold;">/</span>pear-Validate net<span style="color: #000000; font-weight: bold;">/</span>pear-XML_RPC \
	mail<span style="color: #000000; font-weight: bold;">/</span>pear-Mail mail<span style="color: #000000; font-weight: bold;">/</span>pear-Mail_Mime www<span style="color: #000000; font-weight: bold;">/</span>pear-HTTP net<span style="color: #000000; font-weight: bold;">/</span>pear-SOAP \
	devel<span style="color: #000000; font-weight: bold;">/</span>pear-HTML_Table security<span style="color: #000000; font-weight: bold;">/</span>pear-Auth_SASL net<span style="color: #000000; font-weight: bold;">/</span>pear-Net_SMTP \
	graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_Canvas graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_Graph \
	graphics<span style="color: #000000; font-weight: bold;">/</span>pear-Image_GraphViz</pre></div></div>

<p>Vamos para a parte do Perl:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> devel<span style="color: #000000; font-weight: bold;">/</span>p5-Config-IniFiles graphics<span style="color: #000000; font-weight: bold;">/</span>p5-GD \
	databases<span style="color: #000000; font-weight: bold;">/</span>p5-DBD-mysql security<span style="color: #000000; font-weight: bold;">/</span>p5-Crypt-DES \
	security<span style="color: #000000; font-weight: bold;">/</span>p5-Digest-HMAC net-mgmt<span style="color: #000000; font-weight: bold;">/</span>p5-Net-SNMP</pre></div></div>

<h4 style="text-align: center;">Problemas com rede ? implementação de segurança ? <a href="http://mundounix.com.br/wp/consultoria-linuxbsd/" target="_blank">clique aqui</a></h4>
<p>Uma importante ferramenta que não pode faltar no nosso ambiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> databases<span style="color: #000000; font-weight: bold;">/</span>rrdtool</pre></div></div>

<p>E nosso pano de fundo do Centreon, o Nagios !</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">portmaster <span style="color: #660033;">-d</span> net-mgmt<span style="color: #000000; font-weight: bold;">/</span>nagios net-mgmt<span style="color: #000000; font-weight: bold;">/</span>ndoutils</pre></div></div>

<p>Marque as opções:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> EMBEDDED_PERL   Enable embedded Perl <span style="color: #7a0874; font-weight: bold;">&#91;</span>requires Perl 5.8.0+<span style="color: #7a0874; font-weight: bold;">&#93;</span> │ │
│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> NANOSLEEP       Use nanosleep <span style="color: #000000; font-weight: bold;">in</span> event timing               │ │
│ │<span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> EVENT_BROKER    Enable event broker functionality           │ │</pre></div></div>

<p>Nagios-plugins:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> FPING    Support <span style="color: #000000; font-weight: bold;">for</span> non-flooding fast <span style="color: #c20cb9; font-weight: bold;">ping</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>check_fping<span style="color: #7a0874; font-weight: bold;">&#41;</span>  │ │
│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> NETSNMP  SNMP support <span style="color: #7a0874; font-weight: bold;">&#40;</span>check_snmp<span style="color: #7a0874; font-weight: bold;">&#41;</span>                         │ │</pre></div></div>

<p>Se estiver instalando dentro de uma Jail, marque a opção abaixo:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> JAIL     Compilation within jail<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">8</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>see Makefile<span style="color: #7a0874; font-weight: bold;">&#41;</span>         │ │</pre></div></div>

<p>ndoutils:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">│ │ <span style="color: #7a0874; font-weight: bold;">&#91;</span>X<span style="color: #7a0874; font-weight: bold;">&#93;</span> MYSQL  MySQL Backend  			                   │ │</pre></div></div>

<p>Vamos as configurações de alguns pacotes:</p>
<p>se estiver usando o shell csh</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">rehash</pre></div></div>

<p>PHP:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc
<span style="color: #c20cb9; font-weight: bold;">cp</span> php.ini-production php.ini
<span style="color: #666666; font-style: italic;"># Ajuste o Fuso horario para sua localidade</span>
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/;date.timezone =/date.timezone = America\/Sao_Paulo/'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>php.ini</pre></div></div>

<p>Apache:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'apache22_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;AddType application/x-httpd-php .php&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>Includes<span style="color: #000000; font-weight: bold;">/</span>php.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;AddType application/x-httpd-php-source .phps&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>Includes<span style="color: #000000; font-weight: bold;">/</span>php.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/DirectoryIndex index.html/DirectoryIndex index.html index.php/g'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache22<span style="color: #000000; font-weight: bold;">/</span>httpd.conf
&nbsp;
<span style="color: #666666; font-style: italic;"># Verifique se o seu arquivo de hosts (/etc/hosts) ou DNS interno esta funcionando corretamente</span>
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>apache22 start</pre></div></div>

<p>Mysql:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'mysql_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>mysql-server start
<span style="color: #666666; font-style: italic;"># definir senha para root do mysql</span>
mysqladmin <span style="color: #660033;">-u</span> root password <span style="color: #ff0000;">&quot;nova-senha&quot;</span></pre></div></div>

<p>SNMP:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_flags=&quot;-a&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmpd_conffile=&quot;/usr/local/etc/snmp/snmpd.conf&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmptrapd_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'snmptrapd_flags=&quot;-a -p /var/run/snmptrapd.pid&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
&nbsp;
<span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp
<span style="color: #c20cb9; font-weight: bold;">cp</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>share<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf.example <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/rocommunity public  default    -V systemonly/rocommunity public default/g'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/agentAddress  udp:127.0.0.1:161/#agentAddress  udp:127.0.0.1:161/'</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>snmp<span style="color: #000000; font-weight: bold;">/</span>snmpd.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>snmpd start
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>snmptrapd start</pre></div></div>

<p>Acerte o arquivo <span style="text-decoration: underline;"><strong>/usr/local/etc/snmp/snmpd.conf</strong></span> com informações de localização e identificação.</p>
<p><em>Se você estiver instalando o snmpd em uma Jail, veja este artigo para funcionamento da mesma em Jail:</em><br />
<a href="http://ggeek.blogspot.com/2008/10/freebsd-jails-and-net-snmp.html" target="_blank">http://ggeek.blogspot.com/2008/10/freebsd-jails-and-net-snmp.html</a></p>
<h4 style="text-align: center;">Consultoria em Soluções Livres, <a href="http://mundounix.com.br/wp/consultoria/" target="_blank">entre em contato !</a></h4>
<p>Nagios:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sh</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">ls</span> <span style="color: #660033;">-1</span> <span style="color: #000000; font-weight: bold;">*</span>-sample <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #c20cb9; font-weight: bold;">read</span> arq ; <span style="color: #000000; font-weight: bold;">do</span> <span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">cut</span> <span style="color: #660033;">-f1</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">'-'</span><span style="color: #000000; font-weight: bold;">`</span> ; <span style="color: #000000; font-weight: bold;">done</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> objects<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">ls</span> <span style="color: #660033;">-1</span> <span style="color: #000000; font-weight: bold;">*</span>-sample <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #c20cb9; font-weight: bold;">read</span> arq ; <span style="color: #000000; font-weight: bold;">do</span> <span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$arq</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">cut</span> <span style="color: #660033;">-f1</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">'-'</span><span style="color: #000000; font-weight: bold;">`</span> ; <span style="color: #000000; font-weight: bold;">done</span>
<span style="color: #7a0874; font-weight: bold;">exit</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'nagios_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>nagios start</pre></div></div>

<p>NDOUtils:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'ndo2db_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf</pre></div></div>

<p>Fazendo download do Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>tmp
fetch http:<span style="color: #000000; font-weight: bold;">//</span>download.centreon.com<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>centreon-2.3.3.tar.gz
<span style="color: #c20cb9; font-weight: bold;">tar</span> zxf centreon-2.3.3.tar.gz
<span style="color: #7a0874; font-weight: bold;">cd</span> centreon-2.3.3</pre></div></div>

<p>Fazendo o Centreon ler o shell bash</p>
<p>Existem 2 maneiras (escolha uma):</p>
<p>- Alterando o caminho nos scripts do Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/\/bin\/bash/\/usr\/local\/bin\/bash/g'</span> install.sh
<span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-p</span> <span style="color: #660033;">-i</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'s/\/bin\/bash/\/usr\/local\/bin\/bash/g'</span> libinstall<span style="color: #000000; font-weight: bold;">/*</span></pre></div></div>

<p>- Criando um link simbolico no /bin</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span></pre></div></div>

<p>Alguns preparativos para a instalação:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d
fetch <span style="color: #660033;">-o</span> tmpl<span style="color: #000000; font-weight: bold;">/</span>vardistrib<span style="color: #000000; font-weight: bold;">/</span>freebsd http:<span style="color: #000000; font-weight: bold;">//</span>www.luizgustavo.pro.br<span style="color: #000000; font-weight: bold;">/</span>downloads<span style="color: #000000; font-weight: bold;">/</span>freebsd.txt</pre></div></div>

<p>Inicie agora a instalação via comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">bash</span> install.sh <span style="color: #660033;">-f</span> tmpl<span style="color: #000000; font-weight: bold;">/</span>vardistrib<span style="color: #000000; font-weight: bold;">/</span>freebsd</pre></div></div>

<p>Acompanhe o processo de instalação através do video abaixo:</p>
<p><iframe src="http://www.youtube.com/embed/h3QensGRZeA?rel=0" frameborder="0" width="520" height="350"></iframe></p>
<p>Terminada a instalação, vamos partir para a parte web, para isso, reinicie o MySQL e o Apache:</p>
<div>
<div>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>mysql-server restart</pre></div></div>

</div>
</div>
<p>Vamos acertar algumas correções de permissão:</p>
<div>
<div>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon
<span style="color: #c20cb9; font-weight: bold;">rm</span> filesGeneration
<span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesGeneration .
<span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www filesGeneration
<span style="color: #c20cb9; font-weight: bold;">rm</span> filesUpload
<span style="color: #c20cb9; font-weight: bold;">mv</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesUpload .
<span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> www:www filesUpload
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>centreon
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesGeneration
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>centreon<span style="color: #000000; font-weight: bold;">/</span>filesUpload</pre></div></div>

</div>
</div>
<p>Vamos corrigir também um problema de versão de dependência do PEAR:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>pear uninstall HTML_QuickForm_advmultiselect 
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>pear <span style="color: #c20cb9; font-weight: bold;">install</span> <span style="color: #660033;">-f</span> pear<span style="color: #000000; font-weight: bold;">/</span>HTML_QuickForm_advmultiselect-1.2.0</pre></div></div>

<p><em>Agora assim, podemos apontar nosso navergador para o endereço do servidor centreon:</em></p>
<pre>http://&lt;ip_ou_url&gt;/centreon</pre>
<h4>Acompanhe o vídeo para configurar via web:</h4>
<p><iframe src="http://www.youtube.com/embed/0NUwmVmcfKA?rel=0" frameborder="0" width="520" height="360"></iframe></p>
<p><strong>Falta pouco, ainda precisamos exportar os arquivos de configuração para que nosso NDO-Utils possa funcionar, para isso, acompanhe o vídeo na exportação do mesmo via web:</strong></p>
<p><iframe src="http://www.youtube.com/embed/UdebdL-AaN0?rel=0" frameborder="0" width="520" height="360"></iframe></p>
<p>Agora, vamos iniciar os processos do Centreon:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">pw user mod nagios <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">sh</span>
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>centcore start
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>centstorage start</pre></div></div>

<p>Acertar a parte da CRON para o FreeBSD:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">cat</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d<span style="color: #000000; font-weight: bold;">/*</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>crontab
<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>cron restart
<span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-rf</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>cron.d</pre></div></div>

<p>Reinicie os processos do nagios e ndoutils</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>nagios restart
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>ndo2db restart</pre></div></div>

<p>Pronto ! agora é só configurar os seus hosts e iniciar o monitoramento.</p>
<p><a href="http://www.mundounix.com.br/"><img class="alignleft" title="logo_mundounix3" src="http://luizgustavo.pro.br/blog/wp-content/uploads/2009/09/logo_mundounix3.png" alt="" width="284" height="72" /></a><em><strong>Se necessitar de suporte ao Centreon, entre em contato com a <a href="http://www.mundounix.com.br/" target="_blank">Mundounix</a>, nós oferecemos suporte e consultoria para solução de monitoramento de redes.</strong></em></p>
<p><a href="http://www.mundounix.com.br/" target="_blank">http://www.mundounix.com.br</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/08/centreon-2-3-3-freebsd9/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>PEFS &#8211; Criptografia facil no FreeBSD</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/06/pefs-criptografia-facil-no-freebsd/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/06/pefs-criptografia-facil-no-freebsd/#comments</comments>
		<pubDate>Wed, 07 Dec 2011 01:16:06 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[criptografia]]></category>
		<category><![CDATA[pefs]]></category>
		<category><![CDATA[segurança]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=669</guid>
		<description><![CDATA[O que é PEFS ? PEFS é um modulo para kernel de criptografia de sistema de arquivo para FreeBSD. Principais características: Executa de forma transparente acima de qualquer sistema de arquivo Valores de encriptação randomicos por arquivo Armazenamento de metadados somente no nome do arquivo Número arbitrario de chaves para cada sistema de arquivo, misturando [...]]]></description>
			<content:encoded><![CDATA[<h4>O que é PEFS ?<a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/cadeado_bsd.png"><img class="size-full wp-image-202 alignright" title="cadeado_bsd" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/cadeado_bsd.png" alt="" width="113" height="154" /></a></h4>
<p>PEFS é um modulo para kernel de criptografia de sistema de arquivo para FreeBSD.</p>
<p>Principais características:</p>
<ul>
<li>Executa de forma transparente acima de qualquer sistema de arquivo</li>
<li>Valores de encriptação randomicos por arquivo</li>
<li>Armazenamento de metadados somente no nome do arquivo</li>
<li>Número arbitrario de chaves para cada sistema de arquivo, misturando chaves em um mesmo diretório e usando cadeia de chaves</li>
<li>Algoritmos modernos de criptografia: AES e Camellia no modo XTS,  PKCS#5v2 e HKDF para geração de chaves.</li>
</ul>
<h4>Como eu instalo e uso ?</h4>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports<span style="color: #000000; font-weight: bold;">/</span>sysutils<span style="color: #000000; font-weight: bold;">/</span>pefs-kmod<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span> clean</pre></div></div>

<p><em>* Você vai precisar dos fontes do kernel (/usr/src)</em></p>
<p>Encriptando um diretorio:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">%</span> <span style="color: #c20cb9; font-weight: bold;">mkdir</span> ~<span style="color: #000000; font-weight: bold;">/</span>Privado
<span style="color: #000000; font-weight: bold;">%</span> pefs addchain <span style="color: #660033;">-fZ</span> ~<span style="color: #000000; font-weight: bold;">/</span>Privado
Enter parent key passphrase:
Reenter parent key passphrase:
<span style="color: #000000; font-weight: bold;">%</span> pefs <span style="color: #c20cb9; font-weight: bold;">mount</span> ~<span style="color: #000000; font-weight: bold;">/</span>Privado ~<span style="color: #000000; font-weight: bold;">/</span>Privado
<span style="color: #000000; font-weight: bold;">%</span> pefs addkey <span style="color: #660033;">-c</span> ~<span style="color: #000000; font-weight: bold;">/</span>Privado
Enter passphrase:
...
<span style="color: #000000; font-weight: bold;">%</span> pefs unmount ~<span style="color: #000000; font-weight: bold;">/</span>Privado</pre></div></div>

<p>Mais informações em:<br />
<a href="http://github.com/glk/pefs">http://github.com/glk/pefs</a><br />
<a href="http://wiki.freebsd.org/PEFS">http://wiki.freebsd.org/PEFS</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/06/pefs-criptografia-facil-no-freebsd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Jail rápido e fácil no FreeBSD9</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/01/jail-rapido-e-facil-no-freebsd9/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/01/jail-rapido-e-facil-no-freebsd9/#comments</comments>
		<pubDate>Thu, 01 Dec 2011 21:05:02 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[FreeBSD9]]></category>
		<category><![CDATA[Jail]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=659</guid>
		<description><![CDATA[Neste artigo &#8220;jogo rápido&#8221;, irei mostrar os comandos necessários para criar uma Jail no FreeBSD 9 (RC3) usando os binários de instalação do FreeBSD. Para isso, comece pelo o download do arquivo &#8220;base&#8221; a partir de um FTP, como no exemplo abaixo: Você também pode usar o arquivo encontrado no cd de instalação cd /tmp [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/freebsd_jail.png"><img class="alignright size-full wp-image-333" title="freebsd_jail" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2010/02/freebsd_jail.png" alt="" width="168" height="177" /></a>Neste artigo &#8220;jogo rápido&#8221;, irei mostrar os comandos necessários para criar uma Jail no FreeBSD 9 (RC3) usando os binários de instalação do FreeBSD.</p>
<p>Para isso, comece pelo o download do arquivo &#8220;base&#8221; a partir de um FTP, como no exemplo abaixo:</p>
<blockquote><p><em>Você também pode usar o arquivo encontrado no cd de instalação</em></p></blockquote>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>tmp
fetch <span style="color: #c20cb9; font-weight: bold;">ftp</span>:<span style="color: #000000; font-weight: bold;">//</span>ftp3.br.freebsd.org<span style="color: #000000; font-weight: bold;">/</span>pub<span style="color: #000000; font-weight: bold;">/</span>FreeBSD<span style="color: #000000; font-weight: bold;">/</span>releases<span style="color: #000000; font-weight: bold;">/</span>amd64<span style="color: #000000; font-weight: bold;">/</span>amd64<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">9.0</span>-RC3<span style="color: #000000; font-weight: bold;">/</span>base.txz</pre></div></div>

<p>Feito isso, basta criar o ambiente da Jail, como no exemplo abaixo:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>jails<span style="color: #000000; font-weight: bold;">/</span>jail-dev
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>jails<span style="color: #000000; font-weight: bold;">/</span>jail-dev
<span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">--unlink</span> <span style="color: #660033;">-xpJvf</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>base.txz</pre></div></div>

<p>Configure alguns parâmetros na jail através de chroot na jail:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">chroot</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>jails<span style="color: #000000; font-weight: bold;">/</span>jail-dev <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">csh</span>
<span style="color: #666666; font-style: italic;"># configure senha de root</span>
<span style="color: #c20cb9; font-weight: bold;">passwd</span>
<span style="color: #666666; font-style: italic;"># adicione um usuario</span>
pw add user admin <span style="color: #660033;">-m</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">csh</span> <span style="color: #660033;">-G</span> wheel
<span style="color: #c20cb9; font-weight: bold;">passwd</span> admin
<span style="color: #666666; font-style: italic;"># configure o rc.conf</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'rpcbind_enable=&quot;NO&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'network_interfaces=&quot;&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #666666; font-style: italic;"># crie um fstab vazio para evitar mensagens de erro</span>
<span style="color: #c20cb9; font-weight: bold;">touch</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>fstab
<span style="color: #7a0874; font-weight: bold;">exit</span></pre></div></div>

<p>Pronto, a Jail já esta funcional.</p>
<p>Configure-a conforme o exemplo abaixo no arquivo /etc/rc.conf:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code"><pre class="text" style="font-family:monospace;">jail_enable=&quot;YES&quot;
jail_list=&quot;jaildev&quot;
jail_jaildev_rootdir=&quot;/usr/jails/jail-dev&quot;
jail_jaildev_hostname=&quot;jail-dev.mundounix.com.br&quot;
jail_jaildev_interface=&quot;bge0&quot;
jail_jaildev_ip=&quot;192.168.83.100&quot;
jail_jaildev_exec_start=&quot;/bin/sh /etc/rc&quot;
jail_jaildev_exec_stop=&quot;/bin/sh /etc/rc.shutdown&quot;
jail_jaildev_devfs_enable=&quot;YES&quot;</pre></td></tr></table></div>

<p>Dai, é inicia-la com o comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.d<span style="color: #000000; font-weight: bold;">/</span>jail start jaildev</pre></div></div>

<p>E divirta-se !</p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/01/jail-rapido-e-facil-no-freebsd9/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ZFS na Raiz com FreeBSD 9</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/12/01/zfs-na-raiz-com-freebsd-9/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/12/01/zfs-na-raiz-com-freebsd-9/#comments</comments>
		<pubDate>Thu, 01 Dec 2011 20:31:44 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[FreeBSD9]]></category>
		<category><![CDATA[zfs]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=653</guid>
		<description><![CDATA[Este guia irá mostrar como você pode instalar um ambiente completo e funcional com ZFS usando o esquema de particionamento GPT no FreeBSD 9, nós também iremos usar SWAP em ZFS. Você pode usar este guia como referencia para uma instalação simples ou em espelhamento (mirror). &#160; Este guia é uma tradução do excelente artigo [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/12/daemon_girl.jpg"><img class="alignright size-medium wp-image-654" title="daemon_girl" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/12/daemon_girl-300x257.jpg" alt="" width="300" height="257" /></a>Este guia irá mostrar como você pode instalar um ambiente completo e funcional com ZFS usando o esquema de particionamento GPT no FreeBSD 9, nós também iremos usar SWAP em ZFS.</p>
<p>Você pode usar este guia como referencia para uma instalação simples ou em espelhamento (mirror).</p>
<p>&nbsp;</p>
<h4><strong>Este guia é uma tradução do excelente artigo do blog <a href="http://aisecure.net/" target="_blank">aisecure.net</a>, você pode visualiza-lo na integra neste <a href="http://www.aisecure.net/2011/11/28/root-zfs-freebsd9/" target="_blank">link</a>.</strong></h4>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><span id="more-653"></span><strong><a href="http://mundounix.com.br/wp/consultoria-pfsense/"><img class="aligncenter size-full wp-image-638" title="Consultoria Pfsense" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2009/10/text4162.png" alt="Consultoria Pfsense" width="542" height="130" /></a><br />
(1) Inicialize o FreeBSD9 através do DVD de instalação ou pelo o &#8220;memstick&#8221; e selecione a opção “Live CD”.</strong></p>
<p><strong>(2) Crie um /tmp gravavél</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">umount</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>md1
mdmfs <span style="color: #660033;">-s</span> 512M md1 <span style="color: #000000; font-weight: bold;">/</span>tmp</pre></div></div>

<p><strong>(3) Crie as partições necessárias no(s) disco(s) e adcione o ambiente de boot do ZFS.</strong></p>
<p>a) Para uma instalação de disco simples.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">gpart create <span style="color: #660033;">-s</span> gpt ada0
gpart add <span style="color: #660033;">-b</span> <span style="color: #000000;">34</span> <span style="color: #660033;">-s</span> 64k <span style="color: #660033;">-t</span> freebsd-boot ada0
gpart add <span style="color: #660033;">-t</span> freebsd-zfs <span style="color: #660033;">-l</span> disk0 ada0
gpart bootcode <span style="color: #660033;">-b</span> <span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>pmbr <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>gptzfsboot <span style="color: #660033;">-i</span> <span style="color: #000000;">1</span> ada0</pre></div></div>

<p>b) Repita o procedimento para o segundo disco se você for usar uma instalação em espelhamento (mirror).</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">gpart create <span style="color: #660033;">-s</span> gpt ada1
gpart add <span style="color: #660033;">-b</span> <span style="color: #000000;">34</span> <span style="color: #660033;">-s</span> 64k <span style="color: #660033;">-t</span> freebsd-boot ada1
gpart add <span style="color: #660033;">-t</span> freebsd-zfs <span style="color: #660033;">-l</span> disk1 ada1
gpart bootcode <span style="color: #660033;">-b</span> <span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>pmbr <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>gptzfsboot <span style="color: #660033;">-i</span> <span style="color: #000000;">1</span> ada1</pre></div></div>

<p><strong>(4) Crie o pool do ZFS.</strong></p>
<p>a) Para uma instalação simples.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zpool create zroot <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>gpt<span style="color: #000000; font-weight: bold;">/</span>disk0</pre></div></div>

<p>b) Para uma instalação em espelhamento.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zpool create zroot mirror <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>gpt<span style="color: #000000; font-weight: bold;">/</span>disk0 <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>gpt<span style="color: #000000; font-weight: bold;">/</span>disk1</pre></div></div>

<p><strong>(5) Configure corretamente o bootfs, checksums e os pontos de montagem. (ignore qualquer mensagem de erro relacionada a somente leitura &#8220;read only&#8221;)</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zpool <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">bootfs</span>=zroot zroot
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">checksum</span>=fletcher4 zroot
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">mountpoint</span>=<span style="color: #000000; font-weight: bold;">/</span>mnt zroot</pre></div></div>

<p><strong>(6)) Neste ponto, iremos exportar e importar o pool do ZFS enquanto estamos preservando o zroot.cache no /tmp.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zpool <span style="color: #7a0874; font-weight: bold;">export</span> zroot
zpool import <span style="color: #660033;">-o</span> <span style="color: #007800;">cachefile</span>=<span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>zpool.cache zroot</pre></div></div>

<p><strong>(7) Crie o sistema de arquivo apropriado (Seja livre para improvisar).</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zfs create zroot<span style="color: #000000; font-weight: bold;">/</span>usr
zfs create zroot<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>home
zfs create zroot<span style="color: #000000; font-weight: bold;">/</span>var
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=on <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=on <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>tmp
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports<span style="color: #000000; font-weight: bold;">/</span>distfiles
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ports<span style="color: #000000; font-weight: bold;">/</span>packages
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>src
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>crash
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>db
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=on <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>db<span style="color: #000000; font-weight: bold;">/</span>pkg
&nbsp;
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>empty
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>log
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=<span style="color: #c20cb9; font-weight: bold;">gzip</span> <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>mail
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=off <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>run
zfs create <span style="color: #660033;">-o</span> <span style="color: #007800;">compression</span>=lzjb <span style="color: #660033;">-o</span> <span style="color: #007800;">exec</span>=on <span style="color: #660033;">-o</span> <span style="color: #007800;">setuid</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>tmp</pre></div></div>

<p><strong>(8) Adicione um espaço de SWAP e desabilite a opção de checksums. Neste caso eu adicionei 4GB de SWAP.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zfs create <span style="color: #660033;">-V</span> 4G zroot<span style="color: #000000; font-weight: bold;">/</span>swap
zfs <span style="color: #000000; font-weight: bold;">set</span> org.freebsd:<span style="color: #007800;">swap</span>=on zroot<span style="color: #000000; font-weight: bold;">/</span>swap
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">checksum</span>=off zroot<span style="color: #000000; font-weight: bold;">/</span>swap</pre></div></div>

<p><strong>(9) Crie um link simbólico para o /home e corrija algumas permissões.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">chmod</span> <span style="color: #000000;">1777</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>tmp
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>mnt ; <span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> usr<span style="color: #000000; font-weight: bold;">/</span>home home
<span style="color: #c20cb9; font-weight: bold;">chmod</span> <span style="color: #000000;">1777</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>tmp</pre></div></div>

<p><strong>(10) Instale o FreeBSD.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sh</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>freebsd-dist
<span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">DESTDIR</span>=<span style="color: #000000; font-weight: bold;">/</span>mnt
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #000000; font-weight: bold;">in</span> base.txz lib32.txz kernel.txz doc.txz ports.txz src.txz;
<span style="color: #000000; font-weight: bold;">do</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">cat</span> <span style="color: #007800;">$file</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">--unlink</span> <span style="color: #660033;">-xpJf</span> - <span style="color: #660033;">-C</span> <span style="color: #800000;">${DESTDIR:-/}</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>; <span style="color: #000000; font-weight: bold;">done</span></pre></div></div>

<p><strong>(11) Copie o zpool.cache (MUITO IMPORTANTE!!!)</strong></p>
<pre>cp /tmp/zpool.cache /mnt/boot/zfs/zpool.cache</pre>
<p><strong>(12) Crie o arquivo rc.conf, loader.conf e um arquivo vazio do fstab (Caso contrário, o sistema irá reclamar).</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'zfs_enable=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rc.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'zfs_load=&quot;YES&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>loader.conf
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">'vfs.root.mountfrom=&quot;zfs:zroot&quot;'</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>boot<span style="color: #000000; font-weight: bold;">/</span>loader.conf
<span style="color: #c20cb9; font-weight: bold;">touch</span> <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>fstab</pre></div></div>

<p><strong>(13) Desmonte tudo e corrija os pontos de montagem para a inicialização do sistema.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">readonly</span>=on zroot<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>empty
zfs <span style="color: #c20cb9; font-weight: bold;">umount</span> <span style="color: #660033;">-a</span>
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">mountpoint</span>=legacy zroot
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">mountpoint</span>=<span style="color: #000000; font-weight: bold;">/</span>tmp zroot<span style="color: #000000; font-weight: bold;">/</span>tmp
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">mountpoint</span>=<span style="color: #000000; font-weight: bold;">/</span>usr zroot<span style="color: #000000; font-weight: bold;">/</span>usr
zfs <span style="color: #000000; font-weight: bold;">set</span> <span style="color: #007800;">mountpoint</span>=<span style="color: #000000; font-weight: bold;">/</span>var zroot<span style="color: #000000; font-weight: bold;">/</span>var</pre></div></div>

<p>Reinicie, ajuste a informação de fuso horário (tzsetup), configure uma senha para o usuário root, adicione um usuário comum no sistema e divirta-se!!!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/12/01/zfs-na-raiz-com-freebsd-9/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Novo site Mundounix</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/11/25/novo-site-mundounix/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/11/25/novo-site-mundounix/#comments</comments>
		<pubDate>Fri, 25 Nov 2011 19:43:31 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[mundo BSD]]></category>
		<category><![CDATA[mundoUnix]]></category>
		<category><![CDATA[Mundounix]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=641</guid>
		<description><![CDATA[Pessoal, atualizei o site da Mundounix, gostaria de convidar a todos a visitar o novo site no endereço abaixo: http://www.mundounix.com.br Obrigado !]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/11/logo_avatar_mundounix.png"><img class="alignright size-full wp-image-642" title="logo_avatar_mundounix" src="http://www.luizgustavo.pro.br/blog/wp-content/uploads/2011/11/logo_avatar_mundounix.png" alt="" width="144" height="153" /></a>Pessoal, atualizei o site da Mundounix, gostaria de convidar a todos a visitar o novo site no endereço abaixo:</p>
<h2><a href="http://www.mundounix.com.br" target="_blank">http://www.mundounix.com.br</a></h2>
<p>Obrigado !</p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/11/25/novo-site-mundounix/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GNS3 + VirtualBox 4.1.2 no FreeBSD</title>
		<link>http://www.luizgustavo.pro.br/blog/2011/11/18/gns3-virtualbox-4-1-2-no-freebsd/</link>
		<comments>http://www.luizgustavo.pro.br/blog/2011/11/18/gns3-virtualbox-4-1-2-no-freebsd/#comments</comments>
		<pubDate>Fri, 18 Nov 2011 19:11:12 +0000</pubDate>
		<dc:creator>luizgustavo</dc:creator>
				<category><![CDATA[Sem categoria]]></category>

		<guid isPermaLink="false">http://www.luizgustavo.pro.br/blog/?p=632</guid>
		<description><![CDATA[Este é um vídeo tutorial de funcionamento do GNS3 com suporte ao VirtualBox no FreeBSD. No exemplo, vou configurar um ambiente com um switch cisco (via modulo switch para roteador) e emular ambientes de comunicação sem e com VLAN trunk. Para esse ambiente, estamos usando os seguintes itens: VirtualBox 4.1.2 (via cft) GNS3 0.8.1 (via [...]]]></description>
			<content:encoded><![CDATA[<p>Este é um vídeo tutorial de funcionamento do GNS3 com suporte ao VirtualBox no FreeBSD.</p>
<p>No exemplo, vou configurar um ambiente com um switch cisco (via modulo switch para roteador) e emular ambientes de comunicação sem e com VLAN trunk.</p>
<p>Para esse ambiente, estamos usando os seguintes itens:</p>
<ul>
<li>VirtualBox 4.1.2 (via cft)</li>
<li>GNS3 0.8.1 (via download do site)</li>
</ul>
<p>Instalação do VirtualBox 4.1.2:<br />
<code><br />
cd /tmp<br />
fetch http://home.bluelife.at/ports/virtualbox-cft-20110825.tar.gz<br />
tar zxf virtualbox-cft-20110825.tar.gz<br />
cd emulators/virtualbox-ose<br />
make deinstall<br />
make install clean<br />
</code></p>
<p>Segue o vídeo explicativo do funcionamento (abaixo os links de referencia):</p>
<p><iframe src="http://www.youtube.com/embed/O-3E5iQPOas" frameborder="0" width="500" height="400"></iframe></p>
<p>Referencias:</p>
<p>GNS3: <a href="http://www.gns3.net/download">http://www.gns3.net/download</a><br />
Virtualbox (ports para o Freebsd): <a href="http://home.bluelife.at/ports/virtualbox-cft-20110825.tar.gz">http://home.bluelife.at/ports/virtualbox-cft-20110825.tar.gz</a><br />
Problema com vlan trunk da interface intel: (<a href="http://webcache.googleusercontent.com/search?q=cache:QHH8bNlDmREJ:humbledown.org/virtualbox-intel-vlan-tag-stripping.xhtml+Intel+PRO+%2Bvirtualbox+%2Bvlan+%2Btrunk&amp;hl=pt-BR&amp;client=firefox-a&amp;gl=br&amp;strip=1"> via cache do google</a> )<br />
Problema com interface PCnet-FAST III no Freebsd: <a href="http://eligere.wordpress.com/2008/03/05/virtualbox-156-freebsd-70-and-pcnet-fast-iii-problem/">http://eligere.wordpress.com/2008/03/05/virtualbox-156-freebsd-70-and-pcnet-fast-iii-problem/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.luizgustavo.pro.br/blog/2011/11/18/gns3-virtualbox-4-1-2-no-freebsd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

