<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
/* Font Definitions */
@font-face
{font-family:"MS Mincho";
panose-1:2 2 6 9 4 2 5 8 3 4;}
@font-face
{font-family:"\@MS Mincho";
panose-1:2 2 6 9 4 2 5 8 3 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:Arial;
color:windowtext;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
{page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Hi all, <o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>I have a newbie question regarding ‘purging the cache.’<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>When I run the following command to purge the root domain of
my website,<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'> <o:p></o:p></span></font></p>
<p class=MsoNormal style='text-indent:.5in'><i><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial;font-style:italic'>varnishadm -T
localhost:80 purge.url ^/$<o:p></o:p></span></font></i></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>I get this error:<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='text-indent:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>An error occured in receiving status.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Based on examples, I’ve setup my VCL as follows:<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>//********<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>acl purge {<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>"localhost";<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>“my local ip address”;<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>}<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>sub vcl_recv {<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'># Allow wildcard purging<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>if (req.request == "PURGE"){<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>if (!client.ip ~ purge) {<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>error 405 "Not allowed.";<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>}<o:p></o:p></span></font></p>
<p class=MsoNormal style='text-autospace:none'><font size=1 face=Arial><span
style='font-size:9.0pt;font-family:Arial'>purge_url(req.url); }<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>…<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>//***********<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Any help would be greatly appreciated. <o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Thanks,<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Brian<o:p></o:p></span></font></p>
</div>
</body>
</html>