Mailing List Archive

VCL.List Output
Hello everyone,

I was curious about the output of vcl.list, specifically as to what the
numbers meant, since I don't think its documented in the man page. I
went through the source and I think the number outputted is the
vcl->conf->busy structure member, which is incremented every time in
VCL_Get. I'm not sure exactly when that happens though.

I ask only because I could not seem to unload a certain configuration
using vcl.discard, which prompted me to stop and start the child so that
I could. Thats no big deal as its not on a production environment yet.
The commands I executed were as follows:

varnishadm -T x.x.x.x:8080 vcl.use boot
varnishadm -T x.x.x.x:8080 vcl.list
* 1 boot
1 config
varnishadm -T x.x.x.x:8080 vcl.load config1
/usr/local/etc/varnish/static.vcl
varnishadm -T x.x.x.x:8080 vcl.load config2
/usr/local/etc/varnish/static_and_dynamic.vcl
varnishadm -T x.x.x.x:8080 vcl.list
* 1 boot
1 config
0 static
0 static_and_dynamic
varnishadm -T x.x.x.x:8080 vcl.discard config

Which returns an error. Any idea why that one config was still 'busy'?

-- james
VCL.List Output [ In reply to ]
In message <46DF1FEB.8030000 at nyi.net>, James Quacinella writes:
>Hello everyone,
>
>I was curious about the output of vcl.list, specifically as to what the
>numbers meant, since I don't think its documented in the man page.

It is the reference count of the compile vcl code: how many threads
have a hold on that vcl right now.

>varnishadm -T x.x.x.x:8080 vcl.list
>* 1 boot
> 1 config
> 0 static
> 0 static_and_dynamic
>varnishadm -T x.x.x.x:8080 vcl.discard config
>
>Which returns an error. Any idea why that one config was still 'busy'?

A client request still hanging in there would be my guess.

--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
VCL.List Output [ In reply to ]
Hi!

On Wed, Sep 05, 2007 at 05:30:19PM -0400, James Quacinella wrote:
> I ask only because I could not seem to unload a certain configuration
> using vcl.discard, which prompted me to stop and start the child so that
> I could. Thats no big deal as its not on a production environment yet.
> The commands I executed were as follows:
>
> varnishadm -T x.x.x.x:8080 vcl.use boot
> varnishadm -T x.x.x.x:8080 vcl.list
> * 1 boot
> 1 config
> varnishadm -T x.x.x.x:8080 vcl.load config1
> /usr/local/etc/varnish/static.vcl
> varnishadm -T x.x.x.x:8080 vcl.load config2
> /usr/local/etc/varnish/static_and_dynamic.vcl
> varnishadm -T x.x.x.x:8080 vcl.list
> * 1 boot
> 1 config
> 0 static
> 0 static_and_dynamic
> varnishadm -T x.x.x.x:8080 vcl.discard config
>
> Which returns an error. Any idea why that one config was still 'busy'?

I think you meant to write that you loaded static.vcl with config name
static, and static_and_dynamic.vcl with config name static_and_dynamic.
In any case, there are issues with loaded configs getting stuck. Please
see, and report to ticket 145:
http://varnish.projects.linpro.no/ticket/145

Cheers,

--
Anders.