'\" t .\" Title: ocf_heartbeat_varnish .\" Author: ClusterLabs contributors (see the resource agent source for information about individual authors) .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: 12/17/2020 .\" Manual: OCF resource agents .\" Source: resource-agents UNKNOWN .\" Language: English .\" .TH "OCF_HEARTBEAT_VARNIS" "7" "12/17/2020" "resource-agents UNKNOWN" "OCF resource agents" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" ocf_heartbeat_varnish \- Manage a Varnish instance .SH "SYNOPSIS" .HP \w'\fBvarnish\fR\ 'u \fBvarnish\fR [start | stop | status | monitor | meta\-data | validate\-all] .SH "DESCRIPTION" .PP The Varnish Resource Agent can manage several varnishd instances throughout the cluster\&. It does so by creating a unique PID file and requires a unique listen address and name for each instance\&. .SH "SUPPORTED PARAMETERS" .PP \fBconfig\fR .RS 4 The VCL configuration file that Varnish should manage, for example "/etc/varnish/default\&.vcl"\&. .sp (unique, required, string, no default) .RE .PP \fBname\fR .RS 4 Override the name of the instance that should be given to Varnish (defaults to the resource identifier)\&. .sp (unique, optional, string, default "RESOURCE_ID") .RE .PP \fBpid\fR .RS 4 Write the process\*(Aqs PID to the specified file\&. The default will include the specified name, i\&.e\&.: "/var/run/varnish_production\&.pid"\&. Unlike what this help message shows, it is most likely not necessary to change this parameter\&. .sp (unique, optional, string, default "/var/run/varnishd_RESOURCE_ID\&.pid") .RE .PP \fBlisten_address\fR .RS 4 Listen on this address:port, for example "192\&.168\&.1\&.1:80" .sp (unique, optional, string, default "0\&.0\&.0\&.0:80") .RE .PP \fBmgmt_address\fR .RS 4 Provide a management interface, for example "127\&.0\&.0\&.1:2222" .sp (unique, required, string, no default) .RE .PP \fBttl\fR .RS 4 Specify a hard minimum time to live for cached documents\&. .sp (optional, integer, default 600) .RE .PP \fBvarnish_user\fR .RS 4 Specify the name of an unprivileged user to which the child process should switch before it starts accepting connections\&. .sp (optional, string, default "varnish") .RE .PP \fBvarnish_group\fR .RS 4 Specify the name of an unprivileged group to which the child process should switch before it starts accepting connections\&. .sp (optional, string, default "varnish") .RE .PP \fBbackend_type\fR .RS 4 Use the specified storage backend\&. Valid options are \*(Aqmalloc\*(Aq for memory and \*(Aqfile\*(Aq for a file backend\&. .sp (optional, string, default "malloc") .RE .PP \fBbackend_size\fR .RS 4 Specify the size of the backend\&. For example "1G"\&. .sp (optional, string, default "1G") .RE .PP \fBbackend_file\fR .RS 4 Specify the backend filename if you use backend_type file\&. For example /var/lib/varnish/mybackend\&.bin .sp (unique, optional, string, default "/var/lib/varnish/RESOURCE_ID\&.bin") .RE .PP \fBthreads_pools\fR .RS 4 Number of worker thread pools\&. Each pool has the minimum, maximum and timeout values configured in the thread_pool_min, thread_pool_max and thread_pool_timeout parameters .sp (optional, string, default "2") .RE .PP \fBthread_pool_min\fR .RS 4 Start at least min but no more than max worker threads with the specified idle timeout in each pool\&. .sp (optional, string, default "100") .RE .PP \fBthread_pool_max\fR .RS 4 Start at least min but no more than max worker threads with the specified idle timeout in each pool\&. .sp (optional, string, default "3000") .RE .PP \fBthread_pool_timeout\fR .RS 4 Start at least min but no more than max worker threads with the specified idle timeout in each pool\&. .sp (optional, string, default "120") .RE .PP \fBclient_binary\fR .RS 4 This is used to control Varnish via a CLI\&. It\*(Aqs currently only used to check the status of the running child process\&. .sp (optional, string, default "varnishadm") .RE .PP \fBmaxfiles\fR .RS 4 Maximum number of open files (for ulimit \-n) .sp (optional, string, default "131072") .RE .PP \fBmax_locked_memory\fR .RS 4 Locked shared memory limit (for ulimit \-l) .sp (optional, string, default "82000") .RE .PP \fBsecret\fR .RS 4 Path to a file containing a secret used for authorizing access to the management port\&. .sp (optional, string, default "/etc/varnish/secret") .RE .SH "SUPPORTED ACTIONS" .PP This resource agent supports the following actions (operations): .PP \fBstart\fR .RS 4 Starts the resource\&. Suggested minimum timeout: 20s\&. .RE .PP \fBstop\fR .RS 4 Stops the resource\&. Suggested minimum timeout: 20s\&. .RE .PP \fBmonitor\fR .RS 4 Performs a detailed status check\&. Suggested minimum timeout: 20s\&. Suggested interval: 10s\&. .RE .PP \fBstatus\fR .RS 4 Performs a status check\&. Suggested minimum timeout: 20s\&. .RE .PP \fBmeta\-data\fR .RS 4 Retrieves resource agent metadata (internal use only)\&. Suggested minimum timeout: 5s\&. .RE .PP \fBvalidate\-all\fR .RS 4 Performs a validation of the resource configuration\&. Suggested minimum timeout: 20s\&. .RE .SH "EXAMPLE CRM SHELL" .PP The following is an example configuration for a varnish resource using the \fBcrm\fR(8) shell: .sp .if n \{\ .RS 4 .\} .nf primitive p_varnish ocf:heartbeat:varnish \e params \e config=\fIstring\fR \e mgmt_address=\fIstring\fR \e op monitor timeout="20s" interval="10s" depth="0" .fi .if n \{\ .RE .\} .SH "EXAMPLE PCS" .PP The following is an example configuration for a varnish resource using \fBpcs\fR(8) .sp .if n \{\ .RS 4 .\} .nf pcs resource create p_varnish ocf:heartbeat:varnish \e config=\fIstring\fR \e mgmt_address=\fIstring\fR \e op monitor timeout="20s" interval="10s" OCF_CHECK_LEVEL="0" .fi .if n \{\ .RE .\} .SH "SEE ALSO" .PP \m[blue]\fB\%http://clusterlabs.org/\fR\m[] .SH "AUTHOR" .PP \fBClusterLabs contributors (see the resource agent source for information about individual authors)\fR