Hi Nitesh,
I don't know if squid supports all ESI tags. I try to use only the basic
<esi:include> tag and have problems.
Could you, please, check, if <esi:include> works with your installation?
If it works fine, you should see the page properly composed, and in the
squid_installation/var/logs/access.log there should be entries, that the
template and included pages where taken from the cache.
I would be very gratefull if you could do that test.
Regards,
Michal
Nitesh Naik napisał(a):
>
> Michal,
>
> Thanks for your suggestion.
>
> Changed parser to custom and used following sample ESI code.
>
> <esi:assign name="test_string" value="This is test"/>
> <esi:vars> $(test_string) </esi:vars>
>
> Its Working perfectly fine. Is squid not supporting all ESI tags ?
>
> Regards
> Nitesh Naik
>
>
> ----- Original Message -----
> From: "Michal Pietrusinski" <michal.pietrusinski@cern.ch>
> To: "Nitesh Naik" <nitesh@zedo.com>
> Cc: <squid-users@squid-cache.org>
> Sent: Tuesday, March 08, 2005 5:57 PM
> Subject: Re: [squid-users] Did Anyone used ESI with squid ?
>
>
>
>>Dear Nitesh,
>>
>>It looks like the header is ok, since ESI processing started. I also had
>> problems with parser 'libxml2' - it was constantly reporting some
>>parsing errors even on simple pages which were validated with W3C
>
> validator.
>
>>So finally I changed to 'custom' and 'expat' parsers.
>>
>>I suggest you first try some really simple ESI constructs with 'custom'
>>parser.
>>
>>Regards,
>>Michal
>>
>>
>>
>>Nitesh Naik napisał(a):
>>
>>>Dear Michal,
>>>
>>>Thanks for your reply.
>>>
>>>Let me send you some more information about settings that I am using.
>>>
>>>We are using squid squid-3.0-PRE3-20041220 for parsing ESI. squid is
>>>compiled with esi ( --enable-esi ) but for some reason esi is not
>
> getting
>
>>>parsed and we get following error in the browser.
>>>
>>>The following error was encountered:
>>>
>>>ESI Processing failed.
>>>The ESI processor returned:
>>>esiProcess: Parse error at line 2: junk after document element
>>>This means that:
>>> The surrogate was not able to process the ESI template. Please report
>
> this
>
>>>error to the webmaster
>>>
>>>ESI example used
>>><esi:assign name="date_string" value="$strftime($time(), '%a, %d %B %Y
>>>%H:%M:%S %Z')"/>
>>><esi:vars>
>>>$(date_string)
>>></esi:vars>
>>>
>>>
>>> squid.conf settings
>>>
>>> httpd_accel_surrogate_id unset-id
>>> http_accel_surrogate_remote on
>>> esi_parser libxml2
>>> cache_peer xyz.com parent 80 0 no-query originserver
>>>
>>>Apache configuration at origin server
>>> <Directory /esi/>
>>> Header add Surrogate-Control max-age=60,content="ESI/1.0"
>>> ExpiresActive On
>>> ExpiresByType text/html "now plus 1 minutes"
>>> </Directory>
>>>
>>>
>>>When we hit origin server the Surrogate-Control is added to header
>>>
>>>HTTP/1.1 200 OK
>>>Date: Fri, 04 Mar 2005 13:30:03 GMT
>>>Surrogate-Control: max-age=60,content="ESI/1.0"
>>>P3P: CP="NOI DSP COR CURa ADMa DEVa PSDa OUR BUS UNI COM NAV OTC",
>>>policyref="/w3c/p3p.xml"
>>>Last-Modified: Fri, 04 Mar 2005 12:50:06 GMT
>>>ETag: "13c8a1-133-4228597e"
>>>Accept-Ranges: bytes
>>>Content-Length: 307
>>>Connection: close
>>>Content-Type: text/html
>>>
>>>Regards
>>>Nitesh Naik
>>>
>>>
>>>
>>>----- Original Message -----
>>>From: "Michal Pietrusinski" <michal.pietrusinski@cern.ch>
>>>To: <squid-users@squid-cache.org>
>>>Sent: Tuesday, March 08, 2005 5:26 PM
>>>Subject: Re: [squid-users] Did Anyone used ESI with squid ?
>>>
>>>
>>>
>>>
>>>>Dear Nitesh,
>>>>
>>>>I'm also trying to use ESI with squid - I installed Squid 3, (remember
>>>>to use --enable-esi with configure) and pages are composed fine (I use
>>>><esi:include>), but templates and fragments are not cached.
>>>>
>>>>Remember that your pages must have appropriate HTTP headers in order to
>>>>make squid parsing it as ESI templates.
>>>>
>>>>I hope you are more lucky and will have your pages cached.
>>>>
>>>>Regards,
>>>>Michal Pietrusinski
>>>>
>>>>
>>>>
>>>>Nitesh Naik napisał(a):
>>>>
>>>>
>>>>>Hi,
>>>>>
>>>>>I am having problem with configuring squid with ESI parsing. Did anyone
>>>>>implemented it ?
>>>>>
>>>>>
>>>>>Regards
>>>>>Nitesh Naik
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>
Received on Tue Mar 08 2005 - 08:04:20 MST
This archive was generated by hypermail pre-2.1.9 : Fri Apr 01 2005 - 12:00:02 MST