Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
97ffae10
Commit
97ffae10
authored
Jan 25, 2012
by
Andreas Plesner Jacobsen
Committed by
Tollef Fog Heen
Mar 09, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rest of the literal block colons in fully minimized form
parent
e0523218
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
12 deletions
+12
-12
install.rst
doc/sphinx/installation/install.rst
+1
-1
esi.rst
doc/sphinx/tutorial/esi.rst
+4
-4
handling_misbehaving_servers.rst
doc/sphinx/tutorial/handling_misbehaving_servers.rst
+2
-2
troubleshooting.rst
doc/sphinx/tutorial/troubleshooting.rst
+3
-3
vcl.rst
doc/sphinx/tutorial/vcl.rst
+2
-2
No files found.
doc/sphinx/installation/install.rst
View file @
97ffae10
...
...
@@ -116,7 +116,7 @@ Configuring and compiling
~~~~~~~~~~~~~~~~~~~~~~~~~
Next, configuration: The configuration will need the dependencies
above satisfied. Once that is taken care of::
:
above satisfied. Once that is taken care of::
cd varnish-cache
sh autogen.sh
...
...
doc/sphinx/tutorial/esi.rst
View file @
97ffae10
...
...
@@ -26,7 +26,7 @@ Example: esi include
~~~~~~~~~~~~~~~~~~~~
Lets see an example how this could be used. This simple cgi script
outputs the date::
:
outputs the date::
#!/bin/sh
...
...
@@ -34,7 +34,7 @@ outputs the date:::
echo ''
date "+%Y-%m-%d %H:%M"
Now, lets have an HTML file that has an ESI include statement::
:
Now, lets have an HTML file that has an ESI include statement::
<HTML>
<BODY>
...
...
@@ -43,7 +43,7 @@ Now, lets have an HTML file that has an ESI include statement:::
</BODY>
</HTML>
For ESI to work you need to activate ESI processing in VCL, like this::
:
For ESI to work you need to activate ESI processing in VCL, like this::
sub vcl_fetch {
if (req.url == "/test.html") {
...
...
@@ -59,7 +59,7 @@ Example: esi remove
~~~~~~~~~~~~~~~~~~~
The *remove* keyword allows you to remove output. You can use this to make
a fall back of sorts, when ESI is not available, like this::
:
a fall back of sorts, when ESI is not available, like this::
<esi:include src="http://www.example.com/ad.html"/>
<esi:remove>
...
...
doc/sphinx/tutorial/handling_misbehaving_servers.rst
View file @
97ffae10
...
...
@@ -26,7 +26,7 @@ requests somewhat stale content.
So, in order to serve stale content we must first have some content to
serve. So to make Varnish keep all objects for 30 minutes beyond their
TTL use the following VCL::
:
TTL use the following VCL::
sub vcl_fetch {
set beresp.grace = 30m;
...
...
@@ -64,7 +64,7 @@ errors. You can instruct Varnish to try to handle this in a
more-than-graceful way - enter *Saint mode*. Saint mode enables you to
discard a certain page from one backend server and either try another
server or serve stale content from cache. Lets have a look at how this
can be enabled in VCL::
:
can be enabled in VCL::
sub vcl_fetch {
if (beresp.status == 500) {
...
...
doc/sphinx/tutorial/troubleshooting.rst
View file @
97ffae10
...
...
@@ -55,7 +55,7 @@ Varnish is crashing
When varnish goes bust the child processes crashes. Usually the mother
process will manage this by restarting the child process again. Any
errors will be logged in syslog. It might look like this::
:
errors will be logged in syslog. It might look like this::
Mar 8 13:23:38 smoke varnishd[15670]: Child (15671) not responding to CLI, killing it.
Mar 8 13:23:43 smoke varnishd[15670]: last message repeated 2 times
...
...
@@ -78,13 +78,13 @@ Varnish gives me Guru meditation
First find the relevant log entries in varnishlog. That will probably
give you a clue. Since varnishlog logs so much data it might be hard
to track the entries down. You can set varnishlog to log all your 503
errors by issuing the following command::
:
errors by issuing the following command::
$ varnishlog -c -m TxStatus:503
If the error happened just a short time ago the transaction might still
be in the shared memory log segment. To get varnishlog to process the
whole shared memory log just add the -d option::
:
whole shared memory log just add the -d option::
$ varnishlog -d -c -m TxStatus:503
...
...
doc/sphinx/tutorial/vcl.rst
View file @
97ffae10
...
...
@@ -136,7 +136,7 @@ Example 1 - manipulating headers
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lets say we want to remove the cookie for all objects in the /static
directory of our web server::
:
directory of our web server::
sub vcl_recv {
if (req.url ~ "^/images") {
...
...
@@ -154,7 +154,7 @@ Example 2 - manipulating beresp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Here we override the TTL of a object comming from the backend if it
matches certain criteria::
:
matches certain criteria::
sub vcl_fetch {
if (req.url ~ "\.(png|gif|jpg)$") {
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment