<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Здавствуйте.<br>
    <br>
    Есть файл <tt>/var/local/www/ssi_stub_memcahed/index.html</tt> с
    SSI вставками:<br>
    <br>
    <tt><html></tt><tt><br>
    </tt><tt><body></tt><tt><br>
    </tt><tt>    <h1>SSI STUB MEMCACHED</h1></tt><tt><br>
    </tt><tt>    <p>Start include with stub</p></tt><tt><br>
    </tt><tt>    <!--# block name="one" -->!STUB!<!--# endblock
      --></tt><tt><br>
    </tt><tt>    <!--# include
      virtual="/ssi_stub_memcahed/include.html" stub="one" --></tt><tt><br>
    </tt><tt>    <p>End include with stub</p></tt><tt><br>
    </tt><tt>    <hr/></tt><tt><br>
    </tt><tt>    <p>Start include without stub</p></tt><tt><br>
    </tt><tt>    <!--# include
      virtual="/ssi_stub_memcahed/include.html" --></tt><tt><br>
    </tt><tt>    <p>End include without stub</p></tt><tt><br>
    </tt><tt></body></tt><tt><br>
    </tt><tt></html></tt><tt><br>
    </tt><br>
    При запросе которого по <tt><a class="moz-txt-link-freetext" href="http://localhost/ssi_stub_memcahed/index.html">http://localhost/ssi_stub_memcahed/index.html</a></tt>
    получаем такой результат:<br>
    <br>
    <pre id="line1"><span title="Обнаружен начальный тег, а doctype перед ним не обнаружен. Ожидался «<!DOCTYPE html>»." class="error"><<span class="start-tag">html</span>></span><span>
<span id="line2"></span></span><span><<span class="start-tag">body</span>></span><span>
<span id="line3"></span>    </span><span><<span class="start-tag">h1</span>></span><span>SSI STUB MEMCACHED</span><span></<span class="end-tag">h1</span>></span><span>
<span id="line4"></span>    </span><span><<span class="start-tag">p</span>></span><span>Start include with stub</span><span></<span class="end-tag">p</span>></span><span>
<span id="line5"></span>    
<span id="line6"></span>    !STUB!
<span id="line7"></span>    </span><span><<span class="start-tag">p</span>></span><span>End include with stub</span><span></<span class="end-tag">p</span>></span><span>
<span id="line8"></span>    </span><span><<span class="start-tag">hr</span><span>/</span>></span><span>
<span id="line9"></span>    </span><span><<span class="start-tag">p</span>></span><span>Start include without stub</span><span></<span class="end-tag">p</span>></span><span>
<span id="line10"></span>    included successfully
<span id="line11"></span>    </span><span><<span class="start-tag">p</span>></span><span>End include without stub</span><span></<span class="end-tag">p</span>></span><span>
<span id="line12"></span></span><span></<span class="end-tag">body</span>></span><span>
<span id="line13"></span></span><span></<span class="end-tag">html</span>></span></pre>
    <br>
    В файле <tt>/var/local/www/ssi_stub_memcahed/include.html</tt>
    записана строка:<br>
    <br>
    <tt>included successfully</tt><br>
    <br>
    Конфигурация сервера:<br>
    <br>
    <tt>server {</tt><tt><br>
    </tt><tt>        listen                  80;</tt><tt><br>
    </tt><tt>        server_name             localhost;</tt><tt><br>
    </tt><tt><br>
    </tt><tt>        location / {</tt><tt><br>
    </tt><tt>                root            /etc/nginx/html;</tt><tt><br>
    </tt><tt>                index           index.html index.htm;</tt><tt><br>
    </tt><tt>        }</tt><tt><br>
    </tt><tt><br>
    </tt><tt>        location /nginx-status {</tt><tt><br>
    </tt><tt>                stub_status     on;</tt><tt><br>
    </tt><tt>                access_log      off;</tt><tt><br>
    </tt><tt>                allow           127.0.0.1;</tt><tt><br>
    </tt><tt>                deny            all;</tt><tt><br>
    </tt><tt>        }</tt><tt><br>
    </tt><tt><br>
    </tt><tt>        location /ssi_stub_memcahed/ {</tt><tt><br>
    </tt><tt>                default_type                  text/html;</tt><tt><br>
    </tt><tt>                error_log                            
      /var/log/nginx/ssi_stub_memcahced.error debug;</tt><tt><br>
    </tt><tt>                access_log                           
      /var/log/nginx/ssi_stub_memcahced.access;</tt><tt><br>
    </tt><tt>                error_page    404 502 504     =   
      @fallback;</tt><tt><br>
    </tt><tt><br>
    </tt><tt>                set    $memcached_key         "test|$uri";</tt><tt><br>
    </tt><tt>                memcached_connect_timeout     2;</tt><tt><br>
    </tt><tt>                memcached_read_timeout        5;</tt><tt><br>
    </tt><tt>                memcached_send_timeout        5;</tt><tt><br>
    </tt><tt>                memcached_pass               
      127.0.0.1:11211;</tt><tt><br>
    </tt><tt>        }</tt><tt><br>
    </tt><tt><br>
    </tt><tt>        location @fallback {</tt><tt><br>
    </tt><tt>            root                             
      /var/local/www;</tt><tt><br>
    </tt><tt>            error_log                        
      /var/log/nginx/ssi_stub_memcahced_fallback.error debug;</tt><tt><br>
    </tt><tt>            access_log                       
      /var/log/nginx/ssi_stub_memcahced_fallback.access;</tt><tt><br>
    </tt><tt>            ssi on;</tt><tt><br>
    </tt><tt>        }</tt><tt><br>
    </tt><tt>}</tt><tt><br>
    </tt><br>
    Почему подключение со стабом работает так как будто произошла ошибка
    запроса, если этот файл очевидно есть и отдается со статусом 200?<br>
    <pre class="moz-signature" cols="72">-- 
С уважением, Туманов Александр</pre>
    <pre class="moz-signature" cols="72">-- 
С уважением, Туманов Александр
Начальник группы разработки программного обеспечения.
74.RU
jabber: <a class="moz-txt-link-abbreviated" href="mailto:tumanov@info74.ru">tumanov@info74.ru</a>
email: <a class="moz-txt-link-abbreviated" href="mailto:tumanov@info74.ru">tumanov@info74.ru</a></pre>
  </body>
</html>