Currently Viewing Posts Tagged Varnish Cache

Stop using Varnish Cache Server for the time being

I just disabled Varnish Server on this VPS. The varnish server version is v3.0.5.

The performance on my blog is improved, but not that much. And also sometimes it return 503 error.

There are a lot of other Varnish user said same 503 issues.

So, I stop using Varnish server for the time being.

 

And at the same time, I noticed that Varnish 4.0 released. I tried to install it on my Centos testing machine, Installation is fine. but I can not make it work. When I try to start varnish, it failed.

There are not many documents about Varnish 4.0. I will wait and see if I can use it later.

Varnish official site.

Varnish Cache built-in tools

When I start to use Varnish for my server, it is hard to start a new vcl. Most of vcl copy on internet make my Varnish failed to start.

Later I know there is a tool to test the VCL file. Make sure it is legal, or validated.

varnishd -C -f /path/to/mysetup.vcl

If something wrong, it will show the error. Point out the place of error.

[root@vps varnish]# varnishd -C -f ./test.vcl
Message from VCC-compiler:
Expected an action, 'if', '{' or '}'
(input Line 18 Pos 9)
ban("req.url ~ ^" + req.url + "$ && req.http.host == " + req.http.host);
--------###---------------------------------------------------------------------
Running VCC-compiler failed, exit 1[root@vps varnish]#

So I can modify it and try it again, until it is pass the validation.

 

Continue reading “Varnish Cache built-in tools”

  • Archives