<?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>Agile Hacking &#187; Sysadmin</title>
	<atom:link href="http://gabrielfalcao.com/category/sysadmin/feed/" rel="self" type="application/rss+xml" />
	<link>http://gabrielfalcao.com</link>
	<description>The GNUs of mine, and its green builds</description>
	<lastBuildDate>Tue, 08 Jun 2010 13:22:40 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Solving &#8220;connection refused&#8221; issues on Debian Sid</title>
		<link>http://gabrielfalcao.com/2010/01/05/solving-connection-refused-issues-on-debian-sid/</link>
		<comments>http://gabrielfalcao.com/2010/01/05/solving-connection-refused-issues-on-debian-sid/#comments</comments>
		<pubDate>Wed, 06 Jan 2010 01:43:27 +0000</pubDate>
		<dc:creator>Gabriel Falcão</dc:creator>
				<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[agile]]></category>

		<guid isPermaLink="false">http://gabrielfalcao.com/?p=143</guid>
		<description><![CDATA[Some weeks ago I started to experiment some network issues on my debian sid:

The selenium-remote-control was not running:

I could even try to do a: &#8220;telnet localhost 4444&#8243;, it just did not work.

My Apache-Solr was not capable to subscribe to apache-activemq

When reading the log, I saw:
Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused
Suddenly [...]]]></description>
			<content:encoded><![CDATA[<p>Some weeks ago I started to experiment some network issues on my debian sid:</p>
<ul>
<li>The selenium-remote-control was not running:</li>
</ul>
<p>I could even try to do a: &#8220;telnet localhost 4444&#8243;, it just did not work.</p>
<ul>
<li>My Apache-Solr was not capable to subscribe to apache-activemq</li>
</ul>
<p>When reading the log, I saw:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Could not connect to broker URL: tcp:<span style="color: #000000; font-weight: bold;">//</span>localhost:<span style="color: #000000;">61616</span>. Reason: java.net.ConnectException: Connection refused<br />
Suddenly I noticed something weird <span style="color: #000000; font-weight: bold;">in</span> my <span style="color: #c20cb9; font-weight: bold;">netstat</span>:<br />
<br />
tcp6       <span style="color: #000000;">0</span>      <span style="color: #000000;">0</span> :::<span style="color: #000000;">8983</span>                 :::<span style="color: #000000; font-weight: bold;">*</span>                    LISTEN      <span style="color: #000000;">3865</span><span style="color: #000000; font-weight: bold;">/</span>solr-globocom<br />
tcp6       <span style="color: #000000;">0</span>      <span style="color: #000000;">0</span> :::<span style="color: #000000;">8161</span>                 :::<span style="color: #000000; font-weight: bold;">*</span>                    LISTEN      <span style="color: #000000;">3901</span><span style="color: #000000; font-weight: bold;">/</span>activemq-globo<br />
tcp6       <span style="color: #000000;">0</span>      <span style="color: #000000;">0</span> :::<span style="color: #000000;">61616</span>                :::<span style="color: #000000; font-weight: bold;">*</span>                    LISTEN      <span style="color: #000000;">3901</span><span style="color: #000000; font-weight: bold;">/</span>activemq-globo<br />
tcp6       <span style="color: #000000;">0</span>      <span style="color: #000000;">0</span> 127.0.0.1:<span style="color: #000000;">41879</span>         127.0.0.1:<span style="color: #000000;">61616</span>         ESTABLISHED <span style="color: #000000;">3865</span><span style="color: #000000; font-weight: bold;">/</span>solr-globocom<br />
tcp6       <span style="color: #000000;">0</span>      <span style="color: #000000;">0</span> 127.0.0.1:<span style="color: #000000;">61616</span>         127.0.0.1:<span style="color: #000000;">41879</span>         ESTABLISHED <span style="color: #000000;">3901</span><span style="color: #000000; font-weight: bold;">/</span>activemq-globo</div></div>
<p>Everything is being bound as IPv6&#8230; humm, that doesn&#8217;t have a good smell&#8230;.</p>
<p>Looking for solutions I&#8217;ve found this file:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>sysctl.d<span style="color: #000000; font-weight: bold;">/</span>bindv6only.conf</div></div>
<p>interesting, huh?!?</p>
<p>Openning up that file, I saw a full description of it, then I just needed to change its property from this:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">net.ipv6.bindv6only = <span style="color: #000000;">1</span></div></div>
<p>to this:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">net.ipv6.bindv6only = <span style="color: #000000;">0</span></div></div>
<p>Well, if you have the same problem, jsut change that, restart your PC, and be happy!</p>
]]></content:encoded>
			<wfw:commentRss>http://gabrielfalcao.com/2010/01/05/solving-connection-refused-issues-on-debian-sid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hosting and deploying django apps on Dreamhost</title>
		<link>http://gabrielfalcao.com/2008/12/02/hosting-and-deploying-django-apps-on-dreamhost/</link>
		<comments>http://gabrielfalcao.com/2008/12/02/hosting-and-deploying-django-apps-on-dreamhost/#comments</comments>
		<pubDate>Tue, 02 Dec 2008 12:12:00 +0000</pubDate>
		<dc:creator>gabriel</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Web development]]></category>

		<guid isPermaLink="false">http://gabrielfalcao.com/?p=10</guid>
		<description><![CDATA[About two years ago, I&#8217;ve signed up to Dreamhost. My goals were and still being to host my personal projects, websites and so on.
Once I am a Django web developer, one of my first actions were to create a django deployment setup, good and flexible enough. The time passed on and have been got new [...]]]></description>
			<content:encoded><![CDATA[<p>About two years ago, I&#8217;ve signed up to Dreamhost. My goals were and still being to host my personal projects, websites and so on.</p>
<p>Once I am a <a href="http://www.djangoproject.com/">Django</a> web developer, one of my first actions were to create a django deployment setup, good and flexible enough. The time passed on and have been got new experiences, and the best desision, i think, was to create a new python sandbox, i mean, a customized python environment.</p>
<h2>How is it possible ?</h2>
<p>Simple! Just compiling python from scratch, with a fake root path (a prefix)</p>
<p>Anyway, the deployment process involves more variables, like setting both htaccess and dispatch files for each project, installing some basic modules such <a href="http://www.pythonware.com/products/pil/">PIL</a> and <a href="http://sourceforge.net/projects/mysql-python/">MySQL</a> and so on&#8230;</p>
<p>So, i ever wanted to create a super duper script to do all that &#8220;dirty&#8221; work. And i did it last weekend!</p>
<p>I were working ia a freelance job and decided to create a subdomain to host test instance of them.</p>
<p>A new sandbox, ready to make my tests to create the super script.</p>
<p>So folks, i present you the brand new: <strong>django_dreamhost.sh</strong> <img src='http://gabrielfalcao.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>It&#8217;s composed by 4 files:</p>
<ul>
<li><strong>django_dreamhost.sh</strong> itself</li>
<li><strong>djangify.template</strong> &#8211; a template with will become a script to setup new projects (htaccess and dipatch files, for instance)</li>
<li><strong>htaccess.template</strong> &#8211; a template that will become the .htaccess of each project of yours</li>
<li><strong>dispatch.template</strong> &#8211; will become the dispatch.fcgi for your projects as well</li>
</ul>
<p>&#8220;But do i need to download all them ?&#8221;, of course NO!</p>
<p>You just download the main script, and he will do all do hard work!</p>
<p>&#8220;I wanna contribute, modify or do anything with that script, can I ?&#8221;, of course yes! All parts of the script are GPLv2 +</p>
<p>You can also always get the development version through <a href="http://git.or.cz/">git</a> repository:</p>
<p><strong>git clone http://git.nacaolivre.org/django_dreamhost</strong></p>
<p>Don&#8217;t want to get all code, just the script ?</p>
<p>Download it at: <a href="http://gnu.gabrielfalcao.com/django_dreamhost/django_dreamhost.sh"><strong>http://gnu.gabrielfalcao.com/django_dreamhost/django_dreamhost.sh</strong></a></p>
<h2><strong>What does that script do ?</strong></h2>
<p>He will do the following steps:</p>
<ol>
<li>Download Python, Django, Python-setuptools, Python-fastcgi to a directory called downloads</li>
<li>Extract all</li>
<li>Create a local root at $HOME/.myroot and the subdirs etc and usr</li>
<li>Set the new bin path to you global path through bashrc and bash_profile</li>
<li>Compile and install python to the new prefix: $HOME/.myroot/usr</li>
<li>Install Django, rename django-admin.py to django-admin</li>
<li>Setup your bash-completion to support django scripts</li>
<li>Install the python modules above with the new python</li>
<li>Install PIL and MYSQL modules through easy_install (setuptools)</li>
<li>Download the template scripts to $HOME/projects/script_templates</li>
<li>Replace the custom tags in templates</li>
<li>Move the djangify.template to the new bin PATH: $HOME/usr/bin and give it execution permission</li>
</ol>
<p>I thinks it&#8217;s all.</p>
<p>I currently use <a href="http://www.nongnu.org/fab/">Fabric</a> to help on deployment, and i have a quite smart basic setup for it to work with this dreamhost django environment, but it will be approached in the next blog post <img src='http://gabrielfalcao.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>See you, folks!</p>
]]></content:encoded>
			<wfw:commentRss>http://gabrielfalcao.com/2008/12/02/hosting-and-deploying-django-apps-on-dreamhost/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
	</channel>
</rss>
