<?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>Naeh.net &#187; Linux &#8211; Logiciels</title>
	<atom:link href="http://naeh.net/categorie/linux/linux-logiciels/feed/" rel="self" type="application/rss+xml" />
	<link>http://naeh.net</link>
	<description>Le mémo du développeur</description>
	<lastBuildDate>Wed, 30 Jun 2010 18:56:54 +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>Subversion 1.6 sur Debian lenny</title>
		<link>http://naeh.net/subversion-1-6-sur-debian-lenny/</link>
		<comments>http://naeh.net/subversion-1-6-sur-debian-lenny/#comments</comments>
		<pubDate>Wed, 30 Jun 2010 18:56:54 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[svn subversion debian backports]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=169</guid>
		<description><![CDATA[alors là c'est le billet mémo par excellence :)
étant utilisateur occasionnel de tortoiseSVN à jour, impossible pour moi d'utiliser svn en ligne de commande (beaucoup plus rapide que tortoise) sur ma debian, d'où l'idée de d'installer svn 1.6 qui n'est pas disponible dans les paquets debian.
la procédure consiste a utiliser les backports, elle est très [...]]]></description>
			<content:encoded><![CDATA[<p>alors là c'est le billet mémo par excellence :)</p>
<p>étant utilisateur occasionnel de tortoiseSVN à jour, impossible pour moi d'utiliser svn en ligne de commande (beaucoup plus rapide que tortoise) sur ma debian, d'où l'idée de d'installer svn 1.6 qui n'est pas disponible dans les paquets debian.</p>
<p>la procédure consiste a utiliser les backports, elle est très simple, encore faut-il la connaitre (ou la trouver facilement)</p>
<p>pour commencer il faut savoir que svn 1.5 doit être déjà installé sur la machine, si ce n'est pas le cas, faire :</p>

<div class="wp_codebox"><table><tr id="p1695"><td class="code" id="p169code5"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> subversion subversion-tools apache2 libapache2-svn</pre></td></tr></table></div>

<p>1. configuration du sources.list<br />
il faut ajouter cette ligne à la fin du fichier <em>/etc/apt/sources.list</em></p>

<div class="wp_codebox"><table><tr id="p1696"><td class="code" id="p169code6"><pre class="sh" style="font-family:monospace;">deb http://www.backports.org/debian lenny-backports main contrib non-free</pre></td></tr></table></div>

<p>2. configurer les backports :</p>

<div class="wp_codebox"><table><tr id="p1697"><td class="code" id="p169code7"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">wget</span> <span style="color: #660033;">-O</span> - http:<span style="color: #000000; font-weight: bold;">//</span>backports.org<span style="color: #000000; font-weight: bold;">/</span>debian<span style="color: #000000; font-weight: bold;">/</span>archive.key <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">apt-key</span> add -
<span style="color: #c20cb9; font-weight: bold;">apt-get</span> update</pre></td></tr></table></div>

<p>3. on instalel svn en spécifiant la source (backports) :</p>

<div class="wp_codebox"><table><tr id="p1698"><td class="code" id="p169code8"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #660033;">-t</span> lenny-backports <span style="color: #c20cb9; font-weight: bold;">install</span> subversion subversion-tools libapache2-svn</pre></td></tr></table></div>

<p>et maintenant on peut utiliser svn en ligne de commande avec des référentiels "commités" avec des version récentes de subversion (comme tortoise)</p>
<p>Source du tuto : <a href="http://swherdman.com/2009/05/subversion-16-on-debian-lenny/">http://swherdman.com/2009/05/subversion-16-on-debian-lenny/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/subversion-1-6-sur-debian-lenny/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configuration d&#8217;Exim avec nom de domaine géré par gandi</title>
		<link>http://naeh.net/configuration-dexim-avec-nom-de-domaine-gere-par-gandi/</link>
		<comments>http://naeh.net/configuration-dexim-avec-nom-de-domaine-gere-par-gandi/#comments</comments>
		<pubDate>Sat, 27 Mar 2010 12:26:40 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[exim]]></category>
		<category><![CDATA[gandi]]></category>
		<category><![CDATA[postfix]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=151</guid>
		<description><![CDATA[Bonjour,
aujourd'hui nous allons voir comment, facilement, exploiter une fonctionnalité offerte par Gandi (ou bien comprise dans le prix de nom de domaine, ça dépend comment on voit les choses).
beaucoup d'entre nous n'ont pas le temps (et souvent pas l'envie de non plus) de se prendre la tête avec un vrai MTA genre postfix ou exim [...]]]></description>
			<content:encoded><![CDATA[<p>Bonjour,</p>
<p>aujourd'hui nous allons voir comment, facilement, exploiter une fonctionnalité offerte par Gandi (ou bien comprise dans le prix de nom de domaine, ça dépend comment on voit les choses).</p>
<p>beaucoup d'entre nous n'ont pas le temps (et souvent pas l'envie de non plus) de se prendre la tête avec un vrai MTA genre postfix ou exim et le configurer en s'assurant de bien renseigner les enregistrement MX chez le registrar, d'installer les bons outils pour le POP (ou IMAP) etc. etc.</p>
<p>il faut savoir qu'avec un nom de domaine de chez Gandi, on a droit a quelques comptes emails (5 par domaine de mémoire) et une infinité d'alias sur ces comptes.</p>
<p>ce qu'on va voir ici, c'est comment configurer une machine (serveur dédié) pour assurer le minimum syndical en s'appuyant sur le service proposé par gandi.</p>
<p>dans notre exemple il s'agira d'un Exim4 (c'est le seul avec lequel j'ai testé pour l'instant, et ça marche tellement bien que je n'ai pas envie de changer :-)  )</p>
<p>on va supposer un compte admin@mon-domaine.com</p>
<p>tout d'abord il faut éditer le fichier : <strong>/etc/exim4/passwd.client</strong> en ajoutant tout à la fin :</p>

<div class="wp_codebox"><table><tr id="p15113"><td class="code" id="p151code13"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">*</span>:admin<span style="color: #000000; font-weight: bold;">@</span>mon-domaine.com:MOT-DE-PASSE-DU-COMPTE</pre></td></tr></table></div>

<p>en suite, on va éditer le fichier <strong>/etc/exim4/update-exim4.conf.conf</strong> pour avoir quelque chose comme :</p>

<div class="wp_codebox"><table><tr id="p15114"><td class="code" id="p151code14"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">dc_eximconfig_configtype</span>=<span style="color: #ff0000;">'satellite'</span>
<span style="color: #007800;">dc_other_hostnames</span>=<span style="color: #ff0000;">''</span>
<span style="color: #007800;">dc_local_interfaces</span>=<span style="color: #ff0000;">'127.0.0.1'</span>
<span style="color: #007800;">dc_readhost</span>=<span style="color: #ff0000;">'mon-domaine.com'</span>
<span style="color: #007800;">dc_relay_domains</span>=<span style="color: #ff0000;">''</span>
<span style="color: #007800;">dc_minimaldns</span>=<span style="color: #ff0000;">'false'</span>
<span style="color: #007800;">dc_relay_nets</span>=<span style="color: #ff0000;">''</span>
<span style="color: #007800;">dc_smarthost</span>=<span style="color: #ff0000;">'mail.gandi.net:587'</span>
<span style="color: #007800;">CFILEMODE</span>=<span style="color: #ff0000;">'644'</span>
<span style="color: #007800;">dc_use_split_config</span>=<span style="color: #ff0000;">'false'</span>
<span style="color: #007800;">dc_hide_mailname</span>=<span style="color: #ff0000;">'true'</span>
<span style="color: #007800;">dc_mailname_in_oh</span>=<span style="color: #ff0000;">'true'</span>
<span style="color: #007800;">dc_localdelivery</span>=<span style="color: #ff0000;">'mail_spool'</span></pre></td></tr></table></div>

<p>un petit</p>

<div class="wp_codebox"><table><tr id="p15115"><td class="code" id="p151code15"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>exim4 reload</pre></td></tr></table></div>

<p>et le tour est joué :)</p>
<p>votre serveur envoie maintenant ces mails en utilisant le compte gandi, plus de soucis de conf complexe, maj à risque etc a se faire...</p>
<p>pour tester :</p>

<div class="wp_codebox"><table><tr id="p15116"><td class="code" id="p151code16"><pre class="bash" style="font-family:monospace;">test-machine:<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>exim4<span style="color: #666666; font-style: italic;"># mail user@omain.tld</span>
Subject: <span style="color: #7a0874; font-weight: bold;">test</span>
ceci est un message de <span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #000000; font-weight: bold;">!</span>
.
Cc:</pre></td></tr></table></div>

<p>PS. procédure trouvé il y a un moment sur les forums gandi, mais je n'arrive jamais a la retrouver je la mets ici, au cas où.<br />
PS2. comme d'habitude, notre distribution ici est une Debian :)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/configuration-dexim-avec-nom-de-domaine-gere-par-gandi/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installer et configurer Munin</title>
		<link>http://naeh.net/installer-et-configurer-munin/</link>
		<comments>http://naeh.net/installer-et-configurer-munin/#comments</comments>
		<pubDate>Sat, 24 Oct 2009 11:20:10 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[munin]]></category>
		<category><![CDATA[stats]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=110</guid>
		<description><![CDATA[... sur une debian.
Aujourd'hui on va voir comment installer et configurer l'outil de monitoring munin
Un petit article aide mémoire comme beaucoup d'autres sur ce blog :)
pour commencer :

apt-get install munin munin-node

en suite il faut éditer le fichier de configuration : /etc/munin/munin.conf
changer juste la valeur de htmldir pour choisir un répertoire où les fichiers html des [...]]]></description>
			<content:encoded><![CDATA[<p>... sur une debian.</p>
<p>Aujourd'hui on va voir comment installer et configurer l'outil de monitoring munin</p>
<p>Un petit article aide mémoire comme beaucoup d'autres sur ce blog :)</p>
<p>pour commencer :</p>

<div class="wp_codebox"><table><tr id="p11021"><td class="code" id="p110code21"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> munin munin-node</pre></td></tr></table></div>

<p>en suite il faut éditer le fichier de configuration : <em>/etc/munin/munin.conf</em></p>
<p>changer juste la valeur de htmldir pour choisir un répertoire où les fichiers html des rapports seront déposés, pour moi c'est sous un vhosts de statistiques, exemple :</p>

<div class="wp_codebox"><table><tr id="p11022"><td class="code" id="p110code22"><pre class="bash" style="font-family:monospace;">htmldir	<span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>www<span style="color: #000000; font-weight: bold;">/</span>munin</pre></td></tr></table></div>

<p>vous pouvez aussi laisser la valeur par défaut.</p>
<p>un autre fichier de configuration pourrait vous intéresser, personnellement je n'ai pas eu a le toucher : <em>/etc/munin/munin-node.conf</em></p>
<p><strong>Important : </strong>Assurez vous que le répertoire "htmldir" choisi plus haut soit accessible en écriture a l'utilisateur munin (sinon le cron vous bombarde de mails pas cool), moi j'ai fait un :</p>

<div class="wp_codebox"><table><tr id="p11023"><td class="code" id="p110code23"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> munin:www-data MON<span style="color: #000000; font-weight: bold;">/</span>HTML<span style="color: #000000; font-weight: bold;">/</span>DIR<span style="color: #000000; font-weight: bold;">/</span>DE<span style="color: #000000; font-weight: bold;">/</span>MUNIN</pre></td></tr></table></div>

<p>maintenant on restart tout ça :</p>

<div class="wp_codebox"><table><tr id="p11024"><td class="code" id="p110code24"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>munin-node restart</pre></td></tr></table></div>

<p>quelques minutes après (le temps de générer quelques stats) on va a l'url correspondant au htmldir et on admire les garphs :)</p>
<p><center><img src="http://naeh.net/wp-content/uploads/2009/10/localhostlocaldomain-memory-day.png" alt="localhostlocaldomain-memory-day" title="localhostlocaldomain-memory-day" width="495" height="415" class="aligncenter size-full wp-image-111 margin:0 auto;" /></center></p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/installer-et-configurer-munin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Lighttpd vs Apache vs Lighttpd + Apache</title>
		<link>http://naeh.net/lighttpd-vs-apache-vs-lighttpd-apache/</link>
		<comments>http://naeh.net/lighttpd-vs-apache-vs-lighttpd-apache/#comments</comments>
		<pubDate>Tue, 07 Apr 2009 21:37:46 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Divers]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[lamp]]></category>
		<category><![CDATA[lighttpd]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[php5]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=85</guid>
		<description><![CDATA[Il fut un temps où on ne se posait pas de question quant au serveur web, on prend Apache et on en parle plus, aujourd'hui les choses ont changé, Apache reste quand même le plus utilisé avec plus de 66% des parts de marché, suivi par IIS, puis tous les autres "petits" derrière, néanmoins en [...]]]></description>
			<content:encoded><![CDATA[<p>Il fut un temps où on ne se posait pas de question quant au serveur web, on prend Apache et on en parle plus, aujourd'hui les choses ont changé, Apache reste quand même le plus utilisé avec plus de 66% des parts de marché, suivi par IIS, puis tous les autres "petits" derrière, néanmoins en fonction des besoins, certains de ces petits peuvent s'avérer bien plus performants qu'Apache, aujourd'hui on va tester 3 configurations possibles avec Apache et Lighttpd.</p>
<p>d'après ce qu'on peut lire un peu partout sur le net, Lighttpd (lighty pour les intimes) est beaucoup plus performant quand il s'agit de servir des pages statiques, mais qu'en est-il vraiment ? et comment s'en sort-il avec le contenu dynamique ? (des sites statiques ça n'existe plus de nos jours ^^).</p>
<p>pour notre test, on va prendre un site très léger, basé sur Zend framework (donc loin d'être statique), contenant une page qui affiche 9 images au hasard a partir d'une tables mysql contenant environ 1000 enregistrements (seulement les emplacement des images sont stockés dans la base). Le serveur de test est un kimsufi L (petit processeur et 1Go de RAM).</p>
<p><strong>versions utilisées : </strong><br />
<a href="http://www.apache.org/" target="_blank">Apache 2.2.9</a><br />
<a href="http://www.lighttpd.net/" target="_blank">Lighttpd 1.4.19</a><br />
<a href="http://fr.php.net/" target="_blank">PHP 5.2.6</a></p>
<p>pour les tests on utilise <a href="http://packages.debian.org/fr/sid/siege" target="_blank">siege</a>, on lance donc un siege avec 100 concurrency sur 10 minutes, voici la commande :</p>

<div class="wp_codebox"><table><tr id="p8530"><td class="code" id="p85code30"><pre class="bash" style="font-family:monospace;">siege <span style="color: #660033;">-c100</span> <span style="color: #660033;">-t10M</span> URL_DU_SITE</pre></td></tr></table></div>

<p>on note également le Load average de la machine a la fin de l'opération.</p>
<h2>1ère configuration : Lighttpd tout seul</h2>
<p>voici le resultat :</p>

<div class="wp_codebox"><table><tr id="p8531"><td class="code" id="p85code31"><pre class="bash" style="font-family:monospace;">Load average : <span style="color: #000000;">4.87</span>
&nbsp;
Lifting the server siege...      done.
Transactions:		       <span style="color: #000000;">23859</span> hits
Availability:		      <span style="color: #000000;">100.00</span> <span style="color: #000000; font-weight: bold;">%</span>
Elapsed <span style="color: #000000; font-weight: bold;">time</span>:		      <span style="color: #000000;">600.37</span> secs
Data transferred:	       <span style="color: #000000;">83.25</span> MB
Response <span style="color: #000000; font-weight: bold;">time</span>:		        <span style="color: #000000;">2.02</span> secs
Transaction rate:	       <span style="color: #000000;">39.74</span> trans<span style="color: #000000; font-weight: bold;">/</span>sec
Throughput:		        <span style="color: #000000;">0.14</span> MB<span style="color: #000000; font-weight: bold;">/</span>sec
Concurrency:		       <span style="color: #000000;">80.21</span>
Successful transactions:       <span style="color: #000000;">23859</span>
Failed transactions:	           <span style="color: #000000;">0</span>
Longest transaction:	        <span style="color: #000000;">5.20</span>
Shortest transaction:	        <span style="color: #000000;">0.10</span></pre></td></tr></table></div>

<h2>2ème configuration : Apache2 tout seul</h2>
<p>le résultat :</p>

<div class="wp_codebox"><table><tr id="p8532"><td class="code" id="p85code32"><pre class="bash" style="font-family:monospace;">Load average : <span style="color: #000000;">77.51</span>
&nbsp;
Lifting the server siege...      done.
Transactions:		       <span style="color: #000000;">23543</span> hits
Availability:		      <span style="color: #000000;">100.00</span> <span style="color: #000000; font-weight: bold;">%</span>
Elapsed <span style="color: #000000; font-weight: bold;">time</span>:		      <span style="color: #000000;">599.66</span> secs
Data transferred:	       <span style="color: #000000;">82.16</span> MB
Response <span style="color: #000000; font-weight: bold;">time</span>:		        <span style="color: #000000;">2.04</span> secs
Transaction rate:	       <span style="color: #000000;">39.26</span> trans<span style="color: #000000; font-weight: bold;">/</span>sec
Throughput:		        <span style="color: #000000;">0.14</span> MB<span style="color: #000000; font-weight: bold;">/</span>sec
Concurrency:		       <span style="color: #000000;">80.22</span>
Successful transactions:       <span style="color: #000000;">23543</span>
Failed transactions:	           <span style="color: #000000;">0</span>
Longest transaction:	       <span style="color: #000000;">10.51</span>
Shortest transaction:	        <span style="color: #000000;">0.05</span></pre></td></tr></table></div>

<h2>3ème configuration : Lighttpd + Apache</h2>
<p>maintenant faisons le test en couplant les 2, dans cette configuration tout ce qui est statique (images, css, js, etc.) sera servi par lighty alors que les scripts php eux, seront traités par apache, pour cela on active le mod_proxy dans lighty, et on ajoute le code suivant dans le vhost de notre site :</p>

<div class="wp_codebox"><table><tr id="p8533"><td class="code" id="p85code33"><pre class="bash" style="font-family:monospace;"> <span style="color: #007800;">$HTTP</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #ff0000;">&quot;url&quot;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">!</span>~ <span style="color: #ff0000;">&quot;\.(js|css|gif|jpg|png|ico|txt|swf|html|htm)$&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
               proxy.server  = <span style="color: #7a0874; font-weight: bold;">&#40;</span> <span style="color: #ff0000;">&quot;&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>
                               <span style="color: #7a0874; font-weight: bold;">&#40;</span> <span style="color: #ff0000;">&quot;host&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #ff0000;">&quot;127.0.0.1&quot;</span>, <span style="color: #ff0000;">&quot;port&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000;">8080</span> <span style="color: #7a0874; font-weight: bold;">&#41;</span>
                       <span style="color: #7a0874; font-weight: bold;">&#41;</span>
               <span style="color: #7a0874; font-weight: bold;">&#41;</span>
       <span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></td></tr></table></div>

<p>vous l'aurez compris, Apache écoute sur le port 8080 (c'est fait en changeant le fichier /etc/apache2/ports.conf).</p>
<p>voici le résultat :</p>

<div class="wp_codebox"><table><tr id="p8534"><td class="code" id="p85code34"><pre class="bash" style="font-family:monospace;">Load average : <span style="color: #000000;">14.79</span>
&nbsp;
Lifting the server siege...      done.
Transactions:		       <span style="color: #000000;">22684</span> hits
Availability:		      <span style="color: #000000;">100.00</span> <span style="color: #000000; font-weight: bold;">%</span>
Elapsed <span style="color: #000000; font-weight: bold;">time</span>:		      <span style="color: #000000;">600.25</span> secs
Data transferred:	       <span style="color: #000000;">79.10</span> MB
Response <span style="color: #000000; font-weight: bold;">time</span>:		        <span style="color: #000000;">2.13</span> secs
Transaction rate:	       <span style="color: #000000;">37.79</span> trans<span style="color: #000000; font-weight: bold;">/</span>sec
Throughput:		        <span style="color: #000000;">0.13</span> MB<span style="color: #000000; font-weight: bold;">/</span>sec
Concurrency:		       <span style="color: #000000;">80.53</span>
Successful transactions:       <span style="color: #000000;">22684</span>
Failed transactions:	           <span style="color: #000000;">0</span>
Longest transaction:	        <span style="color: #000000;">8.61</span>
Shortest transaction:	        <span style="color: #000000;">0.07</span></pre></td></tr></table></div>

<p>plutôt surprenant !</p>
<h2>Conclusion :</h2>
<p>Lighty s'en sort très bien au vu des transactions/s (ou le nombre total de transactions traitées), contrairement a ce qu'on pouvait attendre, coupler les 2 nous fait perdre en performances (on enregistre quand même un load average nettement inférieur a la config d'apache tout seul).</p>
<p>personnellement ce que je retiens, c'est que lighty n'est pas si mauvais que ça pour le contenu dynamique, les performances restent quand très proches dans les 3 cas, donc autant utiliser la solution qui nous plait :-)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/lighttpd-vs-apache-vs-lighttpd-apache/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Partager un répertoire Windows avec VirtualBox</title>
		<link>http://naeh.net/partager-un-repertoire-windows-avec-virtualbox/</link>
		<comments>http://naeh.net/partager-un-repertoire-windows-avec-virtualbox/#comments</comments>
		<pubDate>Mon, 27 Oct 2008 19:03:03 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Divers]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows - Logiciels]]></category>
		<category><![CDATA[mount]]></category>
		<category><![CDATA[partage]]></category>
		<category><![CDATA[virtualBox]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=59</guid>
		<description><![CDATA[Dans cet article nous allons voir comment partager, facilement, un répertoire Windows avec une machine virtuelle sous VirtualBox.
Tout d'abord, précisions l'environnement :
Il s'agit d'un système Hôte sous Windows XP, nous installons dessus le logiciel VirtualBox, et dans ce dernier nous créons une machine virtuelle tournant sous Linux (Systême guest).
Pour commencer il faut installer les additions [...]]]></description>
			<content:encoded><![CDATA[<p>Dans cet article nous allons voir comment partager, facilement, un répertoire Windows avec une machine virtuelle sous VirtualBox.</p>
<p>Tout d'abord, précisions l'environnement :<br />
Il s'agit d'un système Hôte sous Windows XP, nous installons dessus le logiciel VirtualBox, et dans ce dernier nous créons une machine virtuelle tournant sous Linux (Systême guest).</p>
<p>Pour commencer il faut installer les additions client pour notre VirtualBox, pour cela je vous renvoie à notre article : <a href="http://naeh.net/additions-client-pour-virtualbox/">Additions client pour VirtualBox</a>.</p>
<p>Une fois les additions client installées, procédons comme suit :</p>
<ol>
<li>Sélectionner la machine virtuelle est cliquez sur "<strong>Répertoires Partagés</strong>"</li>
<li>Cliquez sur le "<strong>+</strong>" (PLUS) a droite de la fenêtre qui s'ouvre et sélectionner un répertoire à partager, vous pouvez lui donner un nom</li>
<li>Valider et démarrez votre machine virtuelle</li>
</ol>
<p>Maintenant, nous allons voir comment monter le partage du coté de notre système guest (Linux), pour cela, exécutez la commande suivante :</p>

<div class="wp_codebox"><table><tr id="p5937"><td class="code" id="p59code37"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mount</span> <span style="color: #660033;">-t</span> vboxsf NOM_PARTAGE POINT_MONTAGE</pre></td></tr></table></div>

<p>où :<br />
NOM_PARTAGE est le nom que vous avez donné à votre répertoire partagé lors de sa sélection.<br />
POINT_MONTAGE est le point (répertoire, ou encore emplacement) dans la machine virtuelle dans lequel vous voulez monter le répertoire.</p>
<p>voici un exemple avec un partage nommé Downloads :</p>

<div class="wp_codebox"><table><tr id="p5938"><td class="code" id="p59code38"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mount</span> <span style="color: #660033;">-t</span> vboxsf Downloads <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>downloads</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://naeh.net/partager-un-repertoire-windows-avec-virtualbox/feed/</wfw:commentRss>
		<slash:comments>24</slash:comments>
		</item>
		<item>
		<title>Installer libssh2, ssh2 pour php</title>
		<link>http://naeh.net/installer-libssh2-ssh2-pour-php/</link>
		<comments>http://naeh.net/installer-libssh2-ssh2-pour-php/#comments</comments>
		<pubDate>Wed, 08 Oct 2008 20:51:00 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[PHP / MySQL]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[cli]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[extension]]></category>
		<category><![CDATA[libssh2]]></category>
		<category><![CDATA[php5]]></category>
		<category><![CDATA[Serveur]]></category>
		<category><![CDATA[ssh2]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=56</guid>
		<description><![CDATA[Dans cet article nous allons voir comment installer l'extension ssh2 pour php5, cette extension permet l'utilisation de fonctionnalités SSH2 avec php (très utiles quand on veut faire du SFTP par exemple) pour plus d'informations cf. la documentation officielle sur php.net
Pour l'installation, ce n'est pas très compliqué, il suffit de suivre ces quelques étapes à la [...]]]></description>
			<content:encoded><![CDATA[<p>Dans cet article nous allons voir comment installer l'extension ssh2 pour php5, cette extension permet l'utilisation de fonctionnalités SSH2 avec php (très utiles quand on veut faire du SFTP par exemple) pour plus d'informations cf. <a href="http://fr.php.net/manual/fr/book.ssh2.php" target="_blank">la documentation officielle sur php.net</a></p>
<p>Pour l'installation, ce n'est pas très compliqué, il suffit de suivre ces quelques étapes à la lettre et tout ira très bien ;-)</p>
<p>tout d'abord il faut s'assurer d'avoir les bons paquets d'installés, en voici une liste :</p>
<ul>
<li>php5-dev</li>
<li>openssl</li>
<li>libssl-dev</li>
<li>gcc</li>
<li>make</li>
<li>etc. je suppose que si vous installez cette extension, c'est que vous avez déjà php, apache etc.</li>
</ul>
<p><em>Toute la suite s'effectue en root</em></p>
<p>mais avant toute chose, n'oublions pas de faire un petit :</p>

<div class="wp_codebox"><table><tr id="p5649"><td class="code" id="p56code49"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> update
<span style="color: #c20cb9; font-weight: bold;">apt-get</span> upgrade</pre></td></tr></table></div>

<p>en suite il faut créer un répertoire de travail :</p>

<div class="wp_codebox"><table><tr id="p5650"><td class="code" id="p56code50"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> ~
<span style="color: #c20cb9; font-weight: bold;">mkdir</span> libssh2
<span style="color: #7a0874; font-weight: bold;">cd</span> libssh2</pre></td></tr></table></div>

<p>ensuite télécharger libssh2 :</p>

<div class="wp_codebox"><table><tr id="p5651"><td class="code" id="p56code51"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">wget</span> http:<span style="color: #000000; font-weight: bold;">//</span>ovh.dl.sourceforge.net<span style="color: #000000; font-weight: bold;">/</span>sourceforge<span style="color: #000000; font-weight: bold;">/</span>libssh2<span style="color: #000000; font-weight: bold;">/</span>libssh2-<span style="color: #000000;">0.14</span>.tar.gz</pre></td></tr></table></div>

<p>puis l'extraire :</p>

<div class="wp_codebox"><table><tr id="p5652"><td class="code" id="p56code52"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">-xzvf</span> libssh2-<span style="color: #000000;">0.14</span>.tar.gz</pre></td></tr></table></div>

<p>aller dans le répertoire créé et installer libssh2 :</p>

<div class="wp_codebox"><table><tr id="p5653"><td class="code" id="p56code53"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> libssh2-<span style="color: #000000;">0.14</span>
.<span style="color: #000000; font-weight: bold;">/</span>configure <span style="color: #000000; font-weight: bold;">&amp;&amp;</span> <span style="color: #c20cb9; font-weight: bold;">make</span> all <span style="color: #c20cb9; font-weight: bold;">install</span></pre></td></tr></table></div>

<p>maintenant que libssh2 est installée, passons a ssh2 :</p>
<p>on sort du repertoire de libssh2 et on télécharge ssh2 :</p>

<div class="wp_codebox"><table><tr id="p5654"><td class="code" id="p56code54"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> ..
<span style="color: #c20cb9; font-weight: bold;">wget</span> http:<span style="color: #000000; font-weight: bold;">//</span>pecl.php.net<span style="color: #000000; font-weight: bold;">/</span>get<span style="color: #000000; font-weight: bold;">/</span>ssh2-<span style="color: #000000;">0.10</span>.tgz</pre></td></tr></table></div>

<p>extraire l'archive téléchargée :</p>

<div class="wp_codebox"><table><tr id="p5655"><td class="code" id="p56code55"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">-xzvf</span> ssh2-<span style="color: #000000;">0.10</span>.tgz</pre></td></tr></table></div>

<p>aller dans le répertoire créé et installer ssh2 :</p>

<div class="wp_codebox"><table><tr id="p5656"><td class="code" id="p56code56"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> ssh2-<span style="color: #000000;">0.10</span>
phpize <span style="color: #000000; font-weight: bold;">&amp;&amp;</span> .<span style="color: #000000; font-weight: bold;">/</span>configure <span style="color: #660033;">--with-ssh2</span> <span style="color: #000000; font-weight: bold;">&amp;&amp;</span> <span style="color: #c20cb9; font-weight: bold;">make</span></pre></td></tr></table></div>

<p>maintenant que l'installation est terminée, on active l'extension, ici on va copier le fichier ssh2.so dans le répertoire des extension de php5 (il peut être différent du mien selon la distrib et l'installation) :</p>

<div class="wp_codebox"><table><tr id="p5657"><td class="code" id="p56code57"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">cp</span> modules<span style="color: #000000; font-weight: bold;">/</span>ssh2.so <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>lib<span style="color: #000000; font-weight: bold;">/</span>php5<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">20060613</span>+lfs</pre></td></tr></table></div>

<p>puis on ajoute l'extension en créant un fichier ssh2.ini dans le répertoire conf.d (comme pour toutes les autres extensions de php) on n'oublie pas de le faire pour apache mais aussi pour le mode CLI.</p>

<div class="wp_codebox"><table><tr id="p5658"><td class="code" id="p56code58"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;extension=ssh2.so&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>php5<span style="color: #000000; font-weight: bold;">/</span>cli<span style="color: #000000; font-weight: bold;">/</span>conf.d<span style="color: #000000; font-weight: bold;">/</span>ssh2.ini
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;extension=ssh2.so&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>php5<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>conf.d<span style="color: #000000; font-weight: bold;">/</span>ssh2.ini
<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart</pre></td></tr></table></div>

<p>Et voilà, notre extension est installée, a vous ssh2 et sftp avec php :)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/installer-libssh2-ssh2-pour-php/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Additions client pour VirtualBox</title>
		<link>http://naeh.net/additions-client-pour-virtualbox/</link>
		<comments>http://naeh.net/additions-client-pour-virtualbox/#comments</comments>
		<pubDate>Sun, 28 Sep 2008 15:31:13 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Divers]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[Linux - OS]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows - Logiciels]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[headers]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[virtualBox]]></category>

		<guid isPermaLink="false">http://naeh.net/?p=54</guid>
		<description><![CDATA[Ici nous allons voir comment installer les additions client sur une virtualbox sous Windows et pour une Debian Etch en guest.
ça parait simple, mais quand on a installé une Debian assez maigre (avec presque rien dessus) la tache ne se résume plus a un simple clic, voici donc ce qu'il faut faire :
la première étape [...]]]></description>
			<content:encoded><![CDATA[<p>Ici nous allons voir comment installer les additions client sur une virtualbox sous Windows et pour une Debian Etch en guest.</p>
<p>ça parait simple, mais quand on a installé une Debian assez maigre (avec presque rien dessus) la tache ne se résume plus a un simple clic, voici donc ce qu'il faut faire :</p>
<p>la première étape est obligatoire pour nous éviter un message d'erreur du type :</p>
<blockquote><p>"Please install the build and header files for your current Linux kernel.<br />
The current kernel version is 2.6.17-5mdv<br />
Please install the GNU compiler.<br />
Problems were found which would prevent VirtualBox from installing.<br />
Please correct these problems and try again." </p></blockquote>

<div class="wp_codebox"><table><tr id="p5461"><td class="code" id="p54code61"><pre class="bash" style="font-family:monospace;">debian-guest:~<span style="color: #666666; font-style: italic;"># apt-get install linux-headers-`uname -r` build-essential</span></pre></td></tr></table></div>

<p>après il faut aller dans : Périphériques >> Installer les additions client...</p>
<p>retourner dans Debian et faire :</p>

<div class="wp_codebox"><table><tr id="p5462"><td class="code" id="p54code62"><pre class="bash" style="font-family:monospace;">debian-guest:~<span style="color: #666666; font-style: italic;"># cd /media/</span>
debian-guest:~<span style="color: #666666; font-style: italic;"># mount cdrom0</span>
debian-guest:~<span style="color: #666666; font-style: italic;"># cd cdrom</span>
debian-guest:~<span style="color: #666666; font-style: italic;"># sh VBoxLinuxAddition-XXXX.run (le XXX c'est la version adm64 ou x86)</span></pre></td></tr></table></div>

<p>redémarrez les machine virtuelle est ca devrait être bon ;-)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/additions-client-pour-virtualbox/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Wordpress avec Lighttpd</title>
		<link>http://naeh.net/wordpress-avec-lighttpd/</link>
		<comments>http://naeh.net/wordpress-avec-lighttpd/#comments</comments>
		<pubDate>Mon, 22 Sep 2008 21:19:07 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[lighttpd]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://naeh.net/wordpress-avec-lighttpd/</guid>
		<description><![CDATA[Depuis peu naeh.net tourne sous Lighttpd (Adieu mon cher Apache 2), parait-il c'est aussi performant que Apache mais ça consomme beaucoup moins de mérmoire et de ressources CPU.
C'est beau, rapide, léger, en gros c'est magnifique, mais c'est pas tout.
il faut noter tout de même quelques différences par rapport à Apache, Lighttpd ne comprend pas les [...]]]></description>
			<content:encoded><![CDATA[<p>Depuis peu naeh.net tourne sous Lighttpd (Adieu mon cher Apache 2), parait-il c'est aussi performant que Apache mais ça consomme beaucoup moins de mérmoire et de ressources CPU.</p>
<p>C'est beau, rapide, léger, en gros c'est magnifique, mais c'est pas tout.</p>
<p>il faut noter tout de même quelques différences par rapport à Apache, Lighttpd ne comprend pas les .htaccess, ne gère pas les vhosts de la même façon qu'Apache etc.</p>
<p>Or, wordpress utilisse l'url rewriting pour nous donner de belles urls, voici donc le bout de code a ajouter dans le vhost de wordpress pour que ce dernier continue à servir de belles urls :</p>

<div class="wp_codebox"><table><tr id="p5266"><td class="code" id="p52code66"><pre class="bash" style="font-family:monospace;">server.error-handler-<span style="color: #000000;">404</span> = <span style="color: #ff0000;">&quot;/index.php?error=404&quot;</span>
&nbsp;
url.rewrite = <span style="color: #7a0874; font-weight: bold;">&#40;</span>
        <span style="color: #ff0000;">&quot;^/(wp-.+).*/?&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #ff0000;">&quot;$0&quot;</span>,
        <span style="color: #ff0000;">&quot;^/(sitemap.xml)&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #ff0000;">&quot;$0&quot;</span>,
        <span style="color: #ff0000;">&quot;^/(xmlrpc.php)&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #ff0000;">&quot;$0&quot;</span>,
        <span style="color: #ff0000;">&quot;^/(.+)/?$&quot;</span> =<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #ff0000;">&quot;/index.php/$1&quot;</span>
<span style="color: #7a0874; font-weight: bold;">&#41;</span></pre></td></tr></table></div>

<p>On garde même la gestion de l'erreur 404 par wordpress ;)</p>
<p>avec ces quelques lignes, votre wordpress ne peut que mieux se porter dans son nouvel environnement Lighty :)</p>
<p>N.B. n'oublier pas d'activer le module rewrite dans lighttpd.conf pour qu'il sache ce qu'on lui demande quand même ;)<br />
voici la ligne a décommenter (ou a ajouter) :</p>

<div class="wp_codebox"><table><tr id="p5267"><td class="code" id="p52code67"><pre class="bash" style="font-family:monospace;">server.modules              = <span style="color: #7a0874; font-weight: bold;">&#40;</span>
            ...
            <span style="color: #ff0000;">&quot;mod_rewrite&quot;</span>,
            ...
<span style="color: #7a0874; font-weight: bold;">&#41;</span></pre></td></tr></table></div>

<p>n'oubliez pas un petit</p>

<div class="wp_codebox"><table><tr id="p5268"><td class="code" id="p52code68"><pre class="bash" style="font-family:monospace;"> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>lighttpd restart</pre></td></tr></table></div>

<p>a la fin :)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/wordpress-avec-lighttpd/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Comment installer fileinfo sous debian</title>
		<link>http://naeh.net/installation-fileinfo/</link>
		<comments>http://naeh.net/installation-fileinfo/#comments</comments>
		<pubDate>Wed, 14 May 2008 15:43:14 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[PHP / MySQL]]></category>
		<category><![CDATA[Programmation]]></category>
		<category><![CDATA[apt-get]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[fileinfo]]></category>
		<category><![CDATA[libmagic]]></category>
		<category><![CDATA[pear]]></category>
		<category><![CDATA[php5]]></category>
		<category><![CDATA[phpize]]></category>

		<guid isPermaLink="false">http://naeh.net/installation-fileinfo/</guid>
		<description><![CDATA[Les fonctions de l'extension FileInfo essaient de savoir le type de contenu et l’encodage d’un fichier en regardant certaines séquences d’octet "magique" à des positions spécifiques à l’intérieur du fichier. Bien qu'il ne s'agit pas d'une approche infaillible, la méthode heuristique effectue un très bon travail.
le problème avec cette extension c'est qu'elle est un peu [...]]]></description>
			<content:encoded><![CDATA[<p>Les fonctions de l'extension <a href="http://fr3.php.net/manual/fr/book.fileinfo.php" target="_blank">FileInfo</a> essaient de savoir le type de contenu et l’encodage d’un fichier en regardant certaines séquences d’octet "magique" à des positions spécifiques à l’intérieur du fichier. Bien qu'il ne s'agit pas d'une approche infaillible, la méthode heuristique effectue un très bon travail.</p>
<p>le problème avec cette extension c'est qu'elle est un peu dur à installer, en réalité pas si dur que ça, il suffit de prendre le temps de le faire. Il faut juste savoir qu'un simple <strong>apt-get install php5-fileinfo</strong> ne suffira pas, tout simplement parce qu'il n'existe pas de paquet debian pour cette extension (pas encore...).</p>
<p>Donc pour l'installer, voici la procédure :<br />
Il faut d'abord installer <a href="http://pear.php.net/manual/fr/introduction.php" target="_blank">PEAR</a> :</p>

<div class="wp_codebox"><table><tr id="p5175"><td class="code" id="p51code75"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> php-pear</pre></td></tr></table></div>

<p>ensuite il faut installer php5-dev si ce n'est pas déjà fait, ceci installera phpize ce qui nous évitera l'erreur :</p>

<div class="wp_codebox"><table><tr id="p5176"><td class="code" id="p51code76"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sh</span>: phpize: <span style="color: #7a0874; font-weight: bold;">command</span> not found
ERROR: <span style="color: #000000; font-weight: bold;">`</span>phpize<span style="color: #ff0000;">' failed</span></pre></td></tr></table></div>

<p>installation de php5-dev :</p>

<div class="wp_codebox"><table><tr id="p5177"><td class="code" id="p51code77"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> php5-dev</pre></td></tr></table></div>

<p>c'est presque bon mais pas encore :<br />
maintenant il faut installer libmagic pour nous éviter une erreur lors de l'installation de fileinfo :</p>

<div class="wp_codebox"><table><tr id="p5178"><td class="code" id="p51code78"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> libmagic-dev</pre></td></tr></table></div>

<p>maintenant tout est bon, nous allons enfin pouvoir lancer l'installation de notre extension :</p>

<div class="wp_codebox"><table><tr id="p5179"><td class="code" id="p51code79"><pre class="bash" style="font-family:monospace;">pecl <span style="color: #c20cb9; font-weight: bold;">install</span> fileinfo</pre></td></tr></table></div>

<p>Voilà, maintenant fileinfo est installée, nous allons pouvoir vérifier les types mime des fichiers avec des méthodes plus fiables ;-)</p>
<p>Normalement tout devrait fonctionner maintenant, mais il ce peut que l'extension ne soit pas activée comme il faut, dans ce cas il faudra créer un fichier <strong>fileinfo.ini</strong> dans <strong>/etc/php5/apache2/conf.d</strong> avec le contenu suivant :</p>

<div class="wp_codebox"><table><tr id="p5180"><td class="code" id="p51code80"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">extension</span>=fileinfo.so</pre></td></tr></table></div>

<p>reloader apache avec /etc/init.d/apache2 reload et le tour est joué :)</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/installation-fileinfo/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Installer PHPDoc et générer une documentation</title>
		<link>http://naeh.net/installation-phpdoc/</link>
		<comments>http://naeh.net/installation-phpdoc/#comments</comments>
		<pubDate>Tue, 04 Mar 2008 14:33:16 +0000</pubDate>
		<dc:creator>Naeh</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux - Logiciels]]></category>
		<category><![CDATA[PHP / MySQL]]></category>
		<category><![CDATA[Programmation]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[documentation]]></category>
		<category><![CDATA[pear]]></category>
		<category><![CDATA[php5]]></category>
		<category><![CDATA[phpdoc]]></category>
		<category><![CDATA[Serveur]]></category>

		<guid isPermaLink="false">http://naeh.net/installation-phpdoc/</guid>
		<description><![CDATA[Dans cet article nous allons voir comment à partir d'un code source bien commenté, générer une documentation comme on aimerait avoir pour tout projet ou application digne de son nom.
Pour cela nous allons utiliser PHPDocumentor. qui va nous permetre de générer une documentation à paritr des sources de notre projet.
Il faut d'abord l'installer avec la [...]]]></description>
			<content:encoded><![CDATA[<p>Dans cet article nous allons voir comment à partir d'un code source bien commenté, générer une documentation comme on aimerait avoir pour tout projet ou application digne de son nom.</p>
<p>Pour cela nous allons utiliser <a href="http://www.phpdoc.org/" target="_blank">PHPDocumentor</a>. qui va nous permetre de générer une documentation à paritr des sources de notre projet.</p>
<h2>Il faut d'abord l'installer avec la commande suivante :</h2>

<div class="wp_codebox"><table><tr id="p4784"><td class="code" id="p47code84"><pre class="bash" style="font-family:monospace;">pear <span style="color: #c20cb9; font-weight: bold;">install</span> phpdocumentor</pre></td></tr></table></div>

<p>(si pear n'est pas installé faites un <strong>apt-get install php-pear</strong><em>)</em></p>
<p><em>Si vous rencontrez un problème de dépassement  de mémoire alouée avec PHP, allez dans /etc/php5/cli/php.ini et augmenter cette limite (il s'agit du paramètre memory_limit).</em></p>
<h2>création d'un fichier de configuration pour le projet :</h2>
<p>pour générer la documentation d'un projet nous avons besoin d'un fichier de configuration par projet, en voici un exemple :<br />
fichier nom_du_projet.conf :</p>

<div class="wp_codebox"><table><tr id="p4785"><td class="code" id="p47code85"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">&#91;</span>Parse Data<span style="color: #7a0874; font-weight: bold;">&#93;</span>
title = Titre de la documentation
hidden = <span style="color: #c20cb9; font-weight: bold;">false</span>
parseprivate = off
javadocdesc = off
defaultcategoryname = Documentation
defaultpackagename = Projet
target = <span style="color: #000000; font-weight: bold;">/</span>PATH<span style="color: #000000; font-weight: bold;">/</span>OU<span style="color: #000000; font-weight: bold;">/</span>SERA<span style="color: #000000; font-weight: bold;">/</span>ENREGISTRE<span style="color: #000000; font-weight: bold;">/</span>LA<span style="color: #000000; font-weight: bold;">/</span>DOCUMENTATION
readmeinstallchangelog = README, INSTALL, FAQ, LICENSE
directory =   <span style="color: #000000; font-weight: bold;">/</span>PATH<span style="color: #000000; font-weight: bold;">/</span>VERS<span style="color: #000000; font-weight: bold;">/</span>LE<span style="color: #000000; font-weight: bold;">/</span>PROJET
ignore = templates<span style="color: #000000; font-weight: bold;">/</span>,<span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #000000; font-weight: bold;">*</span>.php
sourcecode = on
<span style="color: #007800;">output</span>=HTML:frames:earthli</pre></td></tr></table></div>

<p>et pour tester exécutez la commande suivante (après avoir créé le répertoire cible de la documentation)</p>

<div class="wp_codebox"><table><tr id="p4786"><td class="code" id="p47code86"><pre class="bash" style="font-family:monospace;">phpdoc <span style="color: #660033;">-c</span> nom_du_projet.conf</pre></td></tr></table></div>

<p>et voilà, la génération prend un peu de temps, en fonction de la machine et de la taille du projet.</p>
]]></content:encoded>
			<wfw:commentRss>http://naeh.net/installation-phpdoc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
