'\" t .\" Title: ocf_heartbeat_lxc .\" Author: ClusterLabs contributors (see the resource agent source for information about individual authors) .\" Generator: DocBook XSL Stylesheets vsnapshot .\" Date: 04/13/2023 .\" Manual: OCF resource agents .\" Source: resource-agents 4.12.0-2 .\" Language: English .\" .TH "OCF_HEARTBEAT_LXC" "7" "04/13/2023" "resource-agents 4.12.0-2" "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_lxc \- Manages LXC containers .SH "SYNOPSIS" .HP \w'\fBlxc\fR\ 'u \fBlxc\fR [start | stop | monitor | meta\-data | validate\-all] .SH "DESCRIPTION" .PP Allows LXC containers to be managed by the cluster\&. Notes for lxc Versions before 1\&.0\&.0, where the Container is stopped using kill \-PWR instead of lxc\-stop: It is \*(Aqassumed\*(Aq that the \*(Aqinit\*(Aq system will do an orderly shudown if presented with a \*(Aqkill \-PWR\*(Aq signal\&. On a \*(Aqsysvinit\*(Aq this would require the container to have an inittab file containing "p0::powerfail:/sbin/init 0" .SH "SUPPORTED PARAMETERS" .PP \fBcontainer\fR .RS 4 The unique name for this \*(AqContainer Instance\*(Aq e\&.g\&. \*(Aqtest1\*(Aq\&. .sp (unique, required, string, no default) .RE .PP \fBconfig\fR .RS 4 Absolute path to the file holding the specific configuration for this container e\&.g\&. \*(Aq/etc/lxc/test1/config\*(Aq\&. .sp (required, string, no default) .RE .PP \fBlog\fR .RS 4 Absolute path to the container log file .sp (optional, string, default "/run/resource\-agents/RESOURCE_ID\&.log") .RE .PP \fBuse_screen\fR .RS 4 Provides the option of capturing the \*(Aqroot console\*(Aq from the container and showing it on a separate screen\&. To see the screen output run \*(Aqscreen \-r {container name}\*(Aq The default value is set to \*(Aqfalse\*(Aq, change to \*(Aqtrue\*(Aq to activate this option .sp (optional, boolean, default false) .RE .SH "SUPPORTED ACTIONS" .PP This resource agent supports the following actions (operations): .PP \fBstart\fR .RS 4 Starts the resource\&. Suggested minimum timeout: 10s\&. .RE .PP \fBstop\fR .RS 4 Stops the resource\&. Suggested minimum timeout: 30s\&. .RE .PP \fBmonitor\fR .RS 4 Performs a detailed status check\&. Suggested minimum timeout: 20s\&. Suggested interval: 60s\&. .RE .PP \fBvalidate\-all\fR .RS 4 Performs a validation of the resource configuration\&. Suggested minimum timeout: 20s\&. .RE .PP \fBmeta\-data\fR .RS 4 Retrieves resource agent metadata (internal use only)\&. Suggested minimum timeout: 5s\&. .RE .SH "EXAMPLE CRM SHELL" .PP The following is an example configuration for a lxc resource using the \fBcrm\fR(8) shell: .sp .if n \{\ .RS 4 .\} .nf primitive p_lxc ocf:heartbeat:lxc \e params \e container=\fIstring\fR \e config=\fIstring\fR \e op monitor timeout="20s" interval="60s" depth="0" .fi .if n \{\ .RE .\} .SH "EXAMPLE PCS" .PP The following is an example configuration for a lxc resource using \fBpcs\fR(8) .sp .if n \{\ .RS 4 .\} .nf pcs resource create p_lxc ocf:heartbeat:lxc \e container=\fIstring\fR \e config=\fIstring\fR \e op monitor timeout="20s" interval="60s" 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