<?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/"
	xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule">

<channel>
	<title>pwn-o-rama &#187; debian lenny nslu2 nas bittorrent torrent</title>
	<atom:link href="http://blog.pwn.cl/tag/debian-lenny-nslu2-nas-bittorrent-torrent/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.pwn.cl</link>
	<description>occasionally braindumps</description>
	<lastBuildDate>Mon, 05 Jul 2010 00:14:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
<creativeCommons:license>http://creativecommons.org/licenses/by/2.0/cl/</creativeCommons:license>		<item>
		<title>Torrentflux + SQLite + lighthttpd en Debian 5 (lenny)</title>
		<link>http://blog.pwn.cl/2010/07/torrentflux-sqlite-lighthttpd-en-debian-5-lenny/</link>
		<comments>http://blog.pwn.cl/2010/07/torrentflux-sqlite-lighthttpd-en-debian-5-lenny/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 00:08:55 +0000</pubDate>
		<dc:creator>sneira</dc:creator>
				<category><![CDATA[hardware]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[debian lenny nslu2 nas bittorrent torrent]]></category>

		<guid isPermaLink="false">http://blog.pwn.cl/?p=331</guid>
		<description><![CDATA[Cómo instalar Torrentflux (un cliente BitTorrent), con SQLite para la Base de Datos y lighthttpd cómo servidor web. Requería de un cliente BitTorrent que tuviera un front-end web, pero los recursos de hardware son limitados: será instalado en un NAS, un NSLU2 con Debian 5 (Lenny). El Sistema Operativo está instalado en un pendrive de [...]]]></description>
			<content:encoded><![CDATA[<p>Cómo instalar Torrentflux (un cliente BitTorrent), con SQLite para la Base de Datos y lighthttpd cómo servidor web.<br />
Requería de un cliente BitTorrent que tuviera un front-end web, pero los recursos de hardware son limitados: será instalado en un NAS, un NSLU2 con Debian 5 (Lenny). El Sistema Operativo está instalado en un pendrive de 2 GB, y a la vez, está conectado un disco externo disponible en /mnt/disk1</p>
<p>Este How To está basado en los siguientes posts:</p>
<p>http://www.torrentflux.com/forum/index.php/topic,3353.0.html</p>
<p>http://www.linuxquestions.org/questions/linux-server-73/sqlite-problems-attempt-to-write-a-readonly-database-611727/</p>
<ul>
<li>Instalar los paquetes necesarios:</li>
</ul>
<pre class="brush: plain; light: true; title: ; notranslate">

# apt-get install lighttpd php5-cgi sqlite php5-sqlite
</pre>
<ul>
<li>Crear la estructura de directorios para torrentflux y lighthttpd:</li>
</ul>
<pre class="brush: plain; light: true; title: ; notranslate">

# mkdir -p /mnt/disk1/opt/torrentflux
# chown www-data:root /mnt/disk1/opt/torrentflux
# mkdir -p /mnt/disk1/var/www/torrentflux
# chown www-data:root /mnt/disk1/var/www/torrentflux
# ln -s /mnt/disk1/var/www/torrentflux /var/www/torrentflux
</pre>
<p>Descargar torrentflux desde http://www.torrentflux.com/download.php<br />
Al momento de escribir este documento, la última versión disponible de torrentflux es la 2.4</p>
<ul>
<li>Copiar Torrentflux al directorio destino y crear la Base de Datos</li>
</ul>
<pre class="brush: plain; light: true; title: ; notranslate">

# tar xzvf torrentflux_2.4.tar.gz
# cp -R torrentflux_2.4/html/* /mnt/disk1/var/www/torrentflux
# chown -R www-data:root /mnt/disk1/var/www/torrentflux/

# wget http://homepage.ntlworld.com/cyborgsystems/CS_Main/NSLU2/torrentflux/sqlite_torrentflux.sql
# sqlite /mnt/disk1/opt/torrentflux/torrentflux.db &lt; sqlite_torrentflux.sql
# chown www-data:root /mnt/disk1/opt/torrentflux/torrentflux.db
</pre>
<ul>
<li>Configurar lighthttpd</li>
</ul>
<pre class="brush: plain; light: true; title: ; notranslate">

# vim /etc/lighttpd/lighttpd.conf
</pre>
<p>y ubica la sección server.modules y agrega esta línea al principio de la lista:</p>
<pre class="brush: plain; light: true; title: ; notranslate">

&quot;mod_fastcgi&quot;,
</pre>
<p>luego ve al final del archivo y agrega:</p>
<pre class="brush: plain; light: true; title: ; notranslate">

fastcgi.server = ( &quot;.php&quot; =&gt; ((
&quot;bin-path&quot; =&gt; &quot;/usr/bin/php5-cgi&quot;,
&quot;socket&quot; =&gt; &quot;/tmp/php.socket&quot; )))
</pre>
<ul>
<li>Configurar Torrentflux</li>
</ul>
<pre class="brush: plain; light: true; title: ; notranslate">

# vim /mnt/disk1/var/www/torrentflux/config.php
</pre>
<p>reemplaza estas líneas:</p>
<pre class="brush: plain; light: true; title: ; notranslate">

$cfg[&quot;db_type&quot;] = &quot;mysql&quot;;
$cfg[&quot;db_host&quot;] = &quot;localhost&quot;;
</pre>
<p>por estas:</p>
<pre class="brush: plain; light: true; title: ; notranslate">

$cfg[&quot;db_type&quot;] = &quot;sqlite&quot;;
$cfg[&quot;db_host&quot;] = &quot;/mnt/disk1/opt/torrentflux/torrentflux.db&quot;;
</pre>
<p>Conéctate a torrentflux, e ingresa un nombre de usuario y contraseña, se crearán automáticamente en el sistema. Estará disponible en http://ip/torrentflux</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pwn.cl/2010/07/torrentflux-sqlite-lighthttpd-en-debian-5-lenny/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

