<?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>Кибер-Фанк v2.0 &#187; debian</title>
	<atom:link href="http://www.shatlovsky.ru/category/debian/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.shatlovsky.ru</link>
	<description>Information must be free</description>
	<lastBuildDate>Thu, 29 Apr 2010 16:23:13 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>debian: ошибка при сборке apache 1.3.41</title>
		<link>http://www.shatlovsky.ru/2009/12/06/debian-oshibka-pri-sborke-apache-1-3-41/</link>
		<comments>http://www.shatlovsky.ru/2009/12/06/debian-oshibka-pri-sborke-apache-1-3-41/#comments</comments>
		<pubDate>Sun, 06 Dec 2009 09:13:46 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[apache]]></category>
		<category><![CDATA[debian]]></category>

		<guid isPermaLink="false">http://www.shatlovsky.ru/?p=170</guid>
		<description><![CDATA[При сборке apache 1.3.41 под debian 5.0 lenny возникает ошибка: отсутствует ndbm.h: $ ./configure \ --prefix=/usr/local/apache \ --enable-module=most \ --enable-shared=max \ $ make ... mod_auth_dbm.c:42:18: error: ndbm.h: No such file or directory mod_auth_dbm.c: In function ‘get_dbm_pw’: mod_auth_dbm.c:110: error: ‘DBM’ undeclared &#40;first use in this function&#41; mod_auth_dbm.c:110: error: &#40;Each undeclared identifier is reported only once mod_auth_dbm.c:110: [...]]]></description>
			<content:encoded><![CDATA[<p>При сборке apache 1.3.41 под debian 5.0 lenny возникает ошибка: отсутствует <code>ndbm.h</code>:</p>
<pre class="bash">$ ./configure \
  --<span style="color: #007800;">prefix=</span>/usr/<span style="color: #7a0874; font-weight: bold;">local</span>/apache \
  --enable-<span style="color: #007800;">module=</span>most \
  --enable-<span style="color: #007800;">shared=</span>max \
$ <span style="color: #c20cb9; font-weight: bold;">make</span>
...
mod_auth_dbm.c:<span style="color: #000000;">42</span>:<span style="color: #000000;">18</span>: error: ndbm.h: No such <span style="color: #c20cb9; font-weight: bold;">file</span> or directory
mod_auth_dbm.c: In <span style="color: #000000; font-weight: bold;">function</span> ‘get_dbm_pw’:
mod_auth_dbm.c:<span style="color: #000000;">110</span>: error: ‘DBM’ undeclared <span style="color: #7a0874; font-weight: bold;">&#40;</span>first use <span style="color: #000000; font-weight: bold;">in</span> this <span style="color: #000000; font-weight: bold;">function</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
mod_auth_dbm.c:<span style="color: #000000;">110</span>: error: <span style="color: #7a0874; font-weight: bold;">&#40;</span>Each undeclared identifier is reported only once
mod_auth_dbm.c:<span style="color: #000000;">110</span>: error: <span style="color: #000000; font-weight: bold;">for</span> each <span style="color: #000000; font-weight: bold;">function</span> it appears <span style="color: #000000; font-weight: bold;">in</span>.<span style="color: #7a0874; font-weight: bold;">&#41;</span>
mod_auth_dbm.c:<span style="color: #000000;">110</span>: error: ‘f’ undeclared <span style="color: #7a0874; font-weight: bold;">&#40;</span>first use <span style="color: #000000; font-weight: bold;">in</span> this <span style="color: #000000; font-weight: bold;">function</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
mod_auth_dbm.c:<span style="color: #000000;">111</span>: error: ‘datum’ undeclared <span style="color: #7a0874; font-weight: bold;">&#40;</span>first use <span style="color: #000000; font-weight: bold;">in</span> this <span style="color: #000000; font-weight: bold;">function</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
mod_auth_dbm.c:<span style="color: #000000;">111</span>: error: expected ‘;’ before ‘d’
mod_auth_dbm.c:<span style="color: #000000;">114</span>: error: ‘q’ undeclared <span style="color: #7a0874; font-weight: bold;">&#40;</span>first use <span style="color: #000000; font-weight: bold;">in</span> this <span style="color: #000000; font-weight: bold;">function</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
mod_auth_dbm.c:<span style="color: #000000;">128</span>: error: ‘d’ undeclared <span style="color: #7a0874; font-weight: bold;">&#40;</span>first use <span style="color: #000000; font-weight: bold;">in</span> this <span style="color: #000000; font-weight: bold;">function</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
<span style="color: #c20cb9; font-weight: bold;">make</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">4</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>: *** <span style="color: #7a0874; font-weight: bold;">&#91;</span>mod_auth_dbm.so<span style="color: #7a0874; font-weight: bold;">&#93;</span> Error <span style="color: #000000;">1</span>
<span style="color: #c20cb9; font-weight: bold;">make</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">3</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>: *** <span style="color: #7a0874; font-weight: bold;">&#91;</span>all<span style="color: #7a0874; font-weight: bold;">&#93;</span> Error <span style="color: #000000;">1</span>
<span style="color: #c20cb9; font-weight: bold;">make</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>: *** <span style="color: #7a0874; font-weight: bold;">&#91;</span>subdirs<span style="color: #7a0874; font-weight: bold;">&#93;</span> Error <span style="color: #000000;">1</span>
<span style="color: #c20cb9; font-weight: bold;">make</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>: Leaving directory `/usr/src/apache_1<span style="color: #000000;">.3</span><span style="color: #000000;">.41</span>/src<span style="color: #ff0000;">'
make[1]: *** [build-std] Error 2
make[1]: Leaving directory `/usr/src/apache_1.3.41'</span>
<span style="color: #c20cb9; font-weight: bold;">make</span>: *** <span style="color: #7a0874; font-weight: bold;">&#91;</span>build<span style="color: #7a0874; font-weight: bold;">&#93;</span> Error <span style="color: #000000;">2</span></pre>
<p>Поиск по содержимому пакетов показывает, что такого файла в пакетах debian нет. Пишут, что раньше он входил в состав <code>libc6</code>. В одном из листов рассылки было найдено такое решение:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> libgdbm-dev
$ <span style="color: #c20cb9; font-weight: bold;">ln</span> -s /usr/include/gdbm-ndbm.h /usr/include/ndbm.h</pre>
<p>Что интересно, работает.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2009/12/06/debian-oshibka-pri-sborke-apache-1-3-41/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>debian: добавляем в iptables поддержку ip sets (ipset)</title>
		<link>http://www.shatlovsky.ru/2009/10/27/debian-dobavlyaem-v-iptables-podderzhku-ip-sets-ipset/</link>
		<comments>http://www.shatlovsky.ru/2009/10/27/debian-dobavlyaem-v-iptables-podderzhku-ip-sets-ipset/#comments</comments>
		<pubDate>Tue, 27 Oct 2009 09:22:42 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[debian]]></category>
		<category><![CDATA[ipset]]></category>
		<category><![CDATA[iptables]]></category>
		<category><![CDATA[m-a]]></category>
		<category><![CDATA[module-assistant]]></category>
		<category><![CDATA[netfilter]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://www.shatlovsky.ru/?p=118</guid>
		<description><![CDATA[IP Sets – расширение пакетного фильтра ядра iptables, которое позволяет комфортно работать с большими наборами адресов/сетей. При написании правил iptables при этом мы оперируем именованными списками. Это, пожалуй, единственный на сегодняшний день доступный способ писать правила для большого количества хостов/сетей, не перечисляя каждый из них в отдельном правиле. Если ваш сайт, работающий под linux, подвергается [...]]]></description>
			<content:encoded><![CDATA[<p><strong>IP Sets</strong> – расширение пакетного фильтра ядра <strong>iptables</strong>, которое позволяет комфортно работать с большими наборами адресов/сетей. При написании правил iptables при этом мы оперируем именованными списками.</p>
<p>Это, пожалуй, единственный на сегодняшний день доступный способ писать правила для большого количества хостов/сетей, не перечисляя каждый из них в отдельном правиле. Если ваш сайт, работающий под linux, подвергается DDOS, вы наверняка уже знаете про IP Sets. Если нет - <a href="http://ipset.netfilter.org/">http://ipset.netfilter.org/</a>.</p>
<p>Утилита <strong>ipset</strong> живет в одноименном пакете, а все необходимые патчи ядра входят в состав пакета <strong>netfilter-extensions-source</strong>, который собирается и устанавливается при помощи утилиты <strong>module-assistant</strong> (которая для удобства имеет более короткое имя: <strong>m-a</strong>).</p>
<p>Примерный сценарий установки ip sets выглядит так:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> ipset
$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> netfilter-extensions-<span style="color: #7a0874; font-weight: bold;">source</span>
$ <span style="color: #c20cb9; font-weight: bold;">uname</span> -a
Linux host.domain.tld <span style="color: #000000;">2.6</span><span style="color: #000000;">.26</span><span style="color: #000000;">-1</span><span style="color: #000000;">-686</span> <span style="color: #808080; font-style: italic;">#<span style="color: #000000;">1</span> SMP Fri Mar <span style="color: #000000;">13</span> <span style="color: #000000;">18</span>:<span style="color: #000000;">08</span>:<span style="color: #000000;">45</span> UTC <span style="color: #000000;">2009</span> i686 GNU/Linux</span>
<span style="color: #808080; font-style: italic;"># версия пакета linux-headers должна совпадать с версией ядра, для которого собирается netfilter-extensions</span>
$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> linux-headers<span style="color: #000000;">-2.6</span><span style="color: #000000;">.26</span><span style="color: #000000;">-1</span><span style="color: #000000;">-686</span>
$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> m-a build netfilter-extensions
$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> m-a update &amp;&amp; m-a a-i netfilter-extensions</pre>
<p>Версия пакета заголовков ядра должна точно соответствовать версии активного ядра, для которого собирается <strong>ipset</strong>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2009/10/27/debian-dobavlyaem-v-iptables-podderzhku-ip-sets-ipset/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>firefox: оптимизация внутренних баз данных sqlite</title>
		<link>http://www.shatlovsky.ru/2009/08/26/firefox-optimizaciya-vnutrennix-baz-dannyx-sqlite/</link>
		<comments>http://www.shatlovsky.ru/2009/08/26/firefox-optimizaciya-vnutrennix-baz-dannyx-sqlite/#comments</comments>
		<pubDate>Wed, 26 Aug 2009 07:17:53 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[debian]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[freebsd]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[shell]]></category>
		<category><![CDATA[sqlite]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[unix]]></category>
		<category><![CDATA[заметки на полях]]></category>

		<guid isPermaLink="false">http://www.shatlovsky.ru/?p=112</guid>
		<description><![CDATA[$ find .mozilla/firefox -type f -name &#34;*.sqlite&#34; -exec time sqlite3 \&#123;\&#125; &#34;VACUUM&#34; &#34;;&#34; via]]></description>
			<content:encoded><![CDATA[<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">find</span> .mozilla/firefox -<span style="color: #7a0874; font-weight: bold;">type</span> f -name <span style="color: #ff0000;">&quot;*.sqlite&quot;</span> -<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #000000; font-weight: bold;">time</span> sqlite3 \<span style="color: #7a0874; font-weight: bold;">&#123;</span>\<span style="color: #7a0874; font-weight: bold;">&#125;</span> <span style="color: #ff0000;">&quot;VACUUM&quot;</span> <span style="color: #ff0000;">&quot;;&quot;</span></pre>
<p><a href="http://jdevelop.livejournal.com/1473676.html?mode=reply">via</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2009/08/26/firefox-optimizaciya-vnutrennix-baz-dannyx-sqlite/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Создание /etc/init.d/nginx на debian 5.0 lenny</title>
		<link>http://www.shatlovsky.ru/2009/06/05/sozdanie-etcinitdnginx-na-debian-50-lenny/</link>
		<comments>http://www.shatlovsky.ru/2009/06/05/sozdanie-etcinitdnginx-na-debian-50-lenny/#comments</comments>
		<pubDate>Fri, 05 Jun 2009 07:05:14 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[config]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[заметки на полях]]></category>

		<guid isPermaLink="false">http://www.shatlovsky.ru/2009/06/05/sozdanie-etcinitdnginx-na-debian-50-lenny/</guid>
		<description><![CDATA[$ sudo vim /etc/init.d/nginx Вставляем нижеследующий код (помним про команду ‘set :paste’ для вставки в VIM): #!/bin/sh ### BEGIN INIT INFO # Provides: nginx # Required-Start: $remote_fs $syslog $named $network $time # Required-Stop: $remote_fs $syslog $named $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start nginx at boot time [...]]]></description>
			<content:encoded><![CDATA[<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> vim /etc/init.d/nginx</pre>
<p>Вставляем нижеследующий код (помним про команду ‘set :paste’ для вставки в VIM):</p>
<pre class="bash"><span style="color: #808080; font-style: italic;">#!/bin/sh</span>
<span style="color: #808080; font-style: italic;">### BEGIN INIT INFO</span>
<span style="color: #808080; font-style: italic;"># Provides:          nginx</span>
<span style="color: #808080; font-style: italic;"># Required-Start:    <span style="color: #007800;">$remote_fs</span> <span style="color: #007800;">$syslog</span> <span style="color: #007800;">$named</span> <span style="color: #007800;">$network</span> <span style="color: #007800;">$time</span></span>
<span style="color: #808080; font-style: italic;"># Required-Stop:     <span style="color: #007800;">$remote_fs</span> <span style="color: #007800;">$syslog</span> <span style="color: #007800;">$named</span> <span style="color: #007800;">$network</span></span>
<span style="color: #808080; font-style: italic;"># Default-Start:     <span style="color: #000000;">2</span> <span style="color: #000000;">3</span> <span style="color: #000000;">4</span> <span style="color: #000000;">5</span></span>
<span style="color: #808080; font-style: italic;"># Default-Stop:      <span style="color: #000000;">0</span> <span style="color: #000000;">1</span> <span style="color: #000000;">6</span></span>
<span style="color: #808080; font-style: italic;"># Short-Description: Start nginx at boot time</span>
<span style="color: #808080; font-style: italic;"># Description:       Enable service provided by nginx.</span>
<span style="color: #808080; font-style: italic;">### END INIT INFO</span>
<span style="color: #808080; font-style: italic;"># <span style="color: #007800;">$Id</span>$</span>
&nbsp;
<span style="color: #007800;">NGINXHOME=</span>/usr/<span style="color: #7a0874; font-weight: bold;">local</span>/nginx
<span style="color: #007800;">NGINXPID=</span><span style="color: #007800;">$NGINXHOME</span>/logs/nginx.pid
&nbsp;
<span style="color: #007800;">PATH=</span>/usr/<span style="color: #7a0874; font-weight: bold;">local</span>/sbin:/usr/<span style="color: #7a0874; font-weight: bold;">local</span>/bin:/sbin:/bin:/usr/sbin:/usr/bin
<span style="color: #007800;">DAEMON=</span><span style="color: #007800;">$NGINXHOME</span>/sbin/nginx
<span style="color: #007800;">NAME=</span>nginx
<span style="color: #007800;">DESC=</span>nginx
&nbsp;
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> ! -x <span style="color: #007800;">$DAEMON</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>
<span style="color: #000000; font-weight: bold;">then</span>
   <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Couldn't find $DAEMON. Please set path to DAEMON.&quot;</span>
   <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
<span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># Include nginx defaults <span style="color: #000000; font-weight: bold;">if</span> available</span>
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> -f /etc/default/nginx <span style="color: #7a0874; font-weight: bold;">&#93;</span> ; <span style="color: #000000; font-weight: bold;">then</span>
	. /etc/default/nginx
<span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">set</span> -e
&nbsp;
<span style="color: #000000; font-weight: bold;">case</span> <span style="color: #ff0000;">&quot;$1&quot;</span> <span style="color: #000000; font-weight: bold;">in</span>
  start<span style="color: #7a0874; font-weight: bold;">&#41;</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> -n <span style="color: #ff0000;">&quot;Starting $DESC: &quot;</span>
	start-stop-daemon --start --pidfile <span style="color: #007800;">$NGINXPID</span> \
		--<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #007800;">$DAEMON</span> -- <span style="color: #007800;">$DAEMON_OPTS</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;$NAME.&quot;</span>
	;;
  stop<span style="color: #7a0874; font-weight: bold;">&#41;</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> -n <span style="color: #ff0000;">&quot;Stopping $DESC: &quot;</span>
	start-stop-daemon --stop --pidfile <span style="color: #007800;">$NGINXPID</span> \
		--<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #007800;">$DAEMON</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;$NAME.&quot;</span>
	;;
  restart|force-reload<span style="color: #7a0874; font-weight: bold;">&#41;</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> -n <span style="color: #ff0000;">&quot;Restarting $DESC: &quot;</span>
	start-stop-daemon --stop --pidfile \
		<span style="color: #007800;">$NGINXHOME</span>/run/<span style="color: #007800;">$NAME</span>.pid --<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #007800;">$DAEMON</span>
	<span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">1</span>
	start-stop-daemon --start --pidfile \
		<span style="color: #007800;">$NGINXPID</span> --<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #007800;">$DAEMON</span> -- <span style="color: #007800;">$DAEMON_OPTS</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;$NAME.&quot;</span>
	;;
  reload<span style="color: #7a0874; font-weight: bold;">&#41;</span>
      <span style="color: #7a0874; font-weight: bold;">echo</span> -n <span style="color: #ff0000;">&quot;Reloading $DESC configuration: &quot;</span>
      start-stop-daemon --stop --signal HUP --pidfile <span style="color: #007800;">$NGINXPID</span> \
          --<span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #007800;">$DAEMON</span>
      <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;$NAME.&quot;</span>
      ;;
  *<span style="color: #7a0874; font-weight: bold;">&#41;</span>
	<span style="color: #007800;">N=</span>/etc/init.d/<span style="color: #007800;">$NAME</span>
	<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Usage: $N {start|stop|restart|force-reload}&quot;</span> &gt;&amp;<span style="color: #000000;">2</span>
	<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">1</span>
	;;
<span style="color: #000000; font-weight: bold;">esac</span>
&nbsp;
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span></pre>
<p>Сохраняем скрипт и выходим из vim.</p>
<p>Делаем скрипт исполняемым:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">chmod</span> <span style="color: #000000;">755</span> /etc/init.d/nginx</pre>
<p>Указываем, что <em>nginx</em> нужно запускать при запуске и остановке сервера:</p>
<pre class="bash">$  <span style="color: #c20cb9; font-weight: bold;">sudo</span> /usr/sbin/update-rc.d -f nginx defaults</pre>
<p>UPD: Блок, заключенный между строками
<pre class="bash"><span style="color: #808080; font-style: italic;">### BEGIN INIT INFO</span>
<span style="color: #808080; font-style: italic;">### END INIT INFO</span></pre>
<p> обеспечивает LSB-совместимость. Подробнее см. <a href="http://wiki.debian.org/LSBInitScripts">http://wiki.debian.org/LSBInitScripts</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2009/06/05/sozdanie-etcinitdnginx-na-debian-50-lenny/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Установка nginx на debian 5.0 lenny</title>
		<link>http://www.shatlovsky.ru/2009/06/04/ustanovka-nginx-na-debian-50-lenny/</link>
		<comments>http://www.shatlovsky.ru/2009/06/04/ustanovka-nginx-na-debian-50-lenny/#comments</comments>
		<pubDate>Thu, 04 Jun 2009 15:52:01 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[debian]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[заметки на полях]]></category>

		<guid isPermaLink="false">http://www.shatlovsky.ru/2009/06/04/ustanovka-nginx-na-debian-50-lenny/</guid>
		<description><![CDATA[На "пустом" свежеустановленном Debian не хватает ряда инструментов и библиотек для сборки и установки nginx. Ставим gcc, make, и компания: $ sudo apt-get install build-essential Библиотеки для сборки nginx: $ sudo apt-get install libpcre3 libpcre3-dev libpcrecpp0 libssl-dev zlib1g-dev Для поддержки встроенного Perl добавляем: $ sudo apt-get install libperl-dev Собственно процесс сборки и установки (вместо 0.7.XX [...]]]></description>
			<content:encoded><![CDATA[<p>На "пустом" свежеустановленном Debian не хватает ряда инструментов и библиотек для сборки и установки nginx.</p>
<p>Ставим gcc, make, и компания:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> build-essential</pre>
<p>Библиотеки для сборки nginx:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> libpcre3 libpcre3-dev libpcrecpp0 libssl-dev zlib1g-dev</pre>
<p>Для поддержки встроенного Perl добавляем:</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> libperl-dev</pre>
<p>Собственно процесс сборки и установки (вместо 0.7.XX впишите номер актуальной версии):</p>
<pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">wget</span> http://sysoev.ru/nginx/nginx<span style="color: #000000;">-0.7</span>.XX.<span style="color: #c20cb9; font-weight: bold;">tar</span>.gz
$ <span style="color: #c20cb9; font-weight: bold;">tar</span> zxvf nginx<span style="color: #000000;">-0.7</span>.XX.<span style="color: #c20cb9; font-weight: bold;">tar</span>.gz
$ <span style="color: #c20cb9; font-weight: bold;">ln</span> -s nginx<span style="color: #000000;">-0.7</span>.XX nginx
$ <span style="color: #7a0874; font-weight: bold;">cd</span> nginx
$ ./configure \
--<span style="color: #007800;">prefix=</span>/usr/<span style="color: #7a0874; font-weight: bold;">local</span>/nginx \
--with-cc-<span style="color: #007800;">opt=</span><span style="color: #ff0000;">&quot;-I /usr/include&quot;</span> \
--with-ld-<span style="color: #007800;">opt=</span><span style="color: #ff0000;">&quot;-L /usr/lib&quot;</span> \
--with-http_stub_status_module \
--with-http_realip_module \
--with-http_perl_module  \
--with-http_ssl_module
&nbsp;
$ <span style="color: #c20cb9; font-weight: bold;">make</span> &amp;&amp; <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span>
&nbsp;</pre>
<p>Обратите внимание, параметры
<pre class="bash">--with-cc-<span style="color: #007800;">opt=</span><span style="color: #ff0000;">&quot;-I /usr/include&quot;</span> --with-ld-<span style="color: #007800;">opt=</span><span style="color: #ff0000;">&quot;-L /usr/lib&quot;</span></pre>
<p> указывают на расположение системных заголовков и библиотек, без них configure не видит ряда системных библиотек.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2009/06/04/ustanovka-nginx-na-debian-50-lenny/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
