Ajuda com o Varnish para 2 sites no mesmo servidor

Bráulio Bhavamitra brauliobhavamitra at gmail.com
Mon Nov 26 15:02:12 BRST 2012


Oi Rodrigo,

Tentei a solução que propos e tive o seguinte erro:
➜  ~  sudo service varnish restart
[sudo] password for braulio:
Stopping HTTP accelerator: varnishd.
Starting HTTP accelerator: varnishd failed!
storage_file: filename: /var/lib/varnish/cirandas/varnish_storage.bin size
1024 MB.
Message from VCC-compiler:
Invalid return "pass"
(input Line 18 Pos 17)
        return (pass);
----------------####--

...in function "vcl_deliver"
(input Line 15 Pos 5)
sub vcl_deliver {
----###########--

...which is the "vcl_deliver" method
Legal returns are: "deliver" "restart"
Running VCC-compiler failed, exit 1
VCL compilation failed


Mudei de vcl_deliver para vcl_recv e tive outro erro:
➜  ~  sudo service varnish restart
Stopping HTTP accelerator: varnishd failed!
Starting HTTP accelerator: varnishd failed!
storage_file: filename: /var/lib/varnish/cirandas/varnish_storage.bin size
1024 MB.
Message from VCC-compiler:
Variable 'resp.http.X-Pass' not accessible in method 'vcl_recv'.
At: (input Line 17 Pos 13)
        set resp.http.X-Pass = "Yes";
------------################---------
Running VCC-compiler failed, exit 1
VCL compilation failed



abraços,
bráulio


On Mon, Nov 26, 2012 at 9:00 AM, Daniel Tygel <dtygel at gmail.com> wrote:

> **
> Olá Rodrigo e demais,
>
>    Me pareceu uma proposta bastante boa. No caso de arquivos xml sendo
> carregados por ajax, que também estão dando erro 503, este cabeçalho ficará
> no início do arquivo xml?
>
>         obrigado,
>
>                   daniel
>
> Em Seg, 2012-11-26 às 04:45 -0300, Rodrigo Souto escreveu:
>
> Correção:
>
> sub vcl_deliver {
>   if (req.http.host ~ "(www\.)?fbes\.org\.br"){
>     set resp.http.X-Pass = "Yes";
>     return (pass);
>   } else {
>     set resp.http.X-Pass = "No";
>   }
> }
>
> _______________________________________________
> Noosfero-br mailing listNoosfero-br at listas.softwarelivre.orghttp://listas.softwarelivre.org/cgi-bin/mailman/listinfo/noosfero-br
>
>
>
> _______________________________________________
> Noosfero-br mailing list
> Noosfero-br at listas.softwarelivre.org
> http://listas.softwarelivre.org/cgi-bin/mailman/listinfo/noosfero-br
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-br/attachments/20121126/144f0211/attachment.html>


More information about the Noosfero-br mailing list