Search squid archive

Re: A problem with a refresh pattern rule

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu 11.Aug'16 at 22:38:13 +1200, Amos Jeffries wrote:
> On 11/08/2016 7:04 p.m., C. L. Martinez wrote:
> > Hi all,
> > 
> >  I am doing some modifications in refresh_patterns rules in a squid host (release 3.5.20) and it seems they are working, with the exception of this one:
> > 
> > refresh_pattern -i \.(rar|jar|gz|tgz|tar|bz2|iso|m1v|m2(v|p)|mo(d|v)|(x-|)flv)  129600  80%  129600  override-expire override-lastmod reload-into-ims ignore-reload
> > 
> >  When I run 'squid -k parse' returns me the following error:
> > 
> > 2016/08/11 06:57:33| /etc/squid/squid.conf line 173: refresh_pattern -i \.(rar|jar|gz|tgz|tar|bz2|iso|m1v|m2(v|p)|mo(d|v)|(x-|)flv)     129600  80%  129600  override-expire override-lastmod reload-into-ims ignore-reload
> > 2016/08/11 06:57:33| refreshAddToList: Invalid regular expression '\.(rar|jar|gz|tgz|tar|bz2|iso|m1v|m2(v|p)|mo(d|v)|(x-|)flv)': empty (sub)expression
> > 
> >  Searching where I am doing the mistake, I don't find any problem with "\.(rar|jar|gz|tgz|tar|bz2|iso|m1v|m2(v|p)|mo(d|v)|(x-|)flv)". Where am I doing the mistake??
> > 
> 
> That pattern works fine for me. Must be something to do with the regex
> library on your system.
> 
> I think the error message is about the (x-|)flv piece. The absence of
> anything between | and ) is the only bit that coudl be called an 'empty
> sub-expression' there. You might have to change that to x-flv|flv.

Perfect!!! .. That was, thanks Amos.
> 
> 
> >  On the other side, I see the following warnings also:
> > 
> > 2016/08/11 06:57:33| WARNING: use of 'override-expire' in 'refresh_pattern' violates HTTP
> > 2016/08/11 06:57:33| WARNING: use of 'override-lastmod' in 'refresh_pattern' violates HTTP
> > 2016/08/11 06:57:33| WARNING: use of 'reload-into-ims' in 'refresh_pattern' violates HTTP
> > 2016/08/11 06:57:33| WARNING: use of 'ignore-reload' in 'refresh_pattern' violates HTTP
> > 
> >  I have enabled these options "override-expire override-lastmod reload-into-ims ignore-reload" on some other patterns. Is this wrong??
> 
> Those are WARNINGs. Not an error. They instruct Squid to do things which
> are outside the HTTP specification. You may encounter trouble with some
> traffic because of that changed behaviour.
> 
> The warnings are there to make sure you awre aware something risky is
> being done, and when you run into trouble with those options it is
> probably not Squid bugs but your choice to violate the standard HTTP
> behaviour which caused it.
> 
> Amos

 Understood. I will remove those options, then.

Many thanks.

-- 
Greetings,
C. L. Martinez
_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users




[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux