]> sourceware.org Git - lvm2.git/blob - man/lvchange.8.in
args: add --activate synonym for --available arg
[lvm2.git] / man / lvchange.8.in
1 .TH LVCHANGE 8 "LVM TOOLS #VERSION#" "Sistina Software UK" \" -*- nroff -*-
2 .SH NAME
3 lvchange \- change attributes of a logical volume
4 .SH SYNOPSIS
5 .B lvchange
6 .RB [ \-\-addtag
7 .IR Tag ]
8 .RB [ \-A | \-\-autobackup
9 .RI { y | n }]
10 .RB [ \-a | \-\-activate
11 .RI [ e | l ]{ y | n }]
12 .RB [ \-\-alloc
13 .IR AllocationPolicy ]
14 .RB [ \-C | \-\-contiguous
15 .RI { y | n }]
16 .RB [ \-d | \-\-debug ]
17 .RB [ \-\-deltag
18 .IR Tag ]
19 .RB [ \-\-resync ]
20 .RB [ \-h | \-? | \-\-help ]
21 .RB [ \-\-ignorelockingfailure ]
22 .RB [ \-\-ignoremonitoring ]
23 .RB [ \-\-monitor
24 .RI { y | n }]
25 .RB [ \-\-poll
26 .RI { y | n }]
27 .RB [ \-\-sysinit ]
28 .RB [ \-\-noudevsync ]
29 .RB [ \-M | \-\-persistent
30 .RI { y | n }]
31 .RB [ \-\-minor
32 .IR minor ]
33 .RB [ \-P | \-\-partial ]
34 .RB [ \-p | \-\-permission
35 .RI { r | rw }]
36 .RB [ \-r | \-\-readahead
37 .RI { ReadAheadSectors | auto | none }]
38 .RB [ \-\-refresh ]
39 .RB [ \-t | \-\-test ]
40 .RB [ \-v | \-\-verbose]
41 .I LogicalVolumePath
42 .RI [ LogicalVolumePath ...]
43 .SH DESCRIPTION
44 lvchange allows you to change the attributes of a logical volume
45 including making them known to the kernel ready for use.
46 .SH OPTIONS
47 See \fBlvm\fP(8) for common options.
48 .TP
49 .BR \-a ", " \-\-activate " [" \fIe | \fIl ]{ \fIy | \fIn }
50 Controls the availability of the logical volumes for use.
51 Communicates with the kernel device-mapper driver via
52 libdevmapper to activate (\-ay) or deactivate (\-an) the
53 logical volumes.
54 .IP
55 If clustered locking is enabled, -aey will activate exclusively
56 on one node and -aly will activate only on the local node.
57 To deactivate only on the local node use -aln.
58 Logical volumes with single-host snapshots are always activated
59 exclusively because they can only be used on one node at once.
60 .TP
61 .BR \-C ", " \-\-contiguous " {" \fIy | \fIn }
62 Tries to set or reset the contiguous allocation policy for
63 logical volumes. It's only possible to change a non-contiguous
64 logical volume's allocation policy to contiguous, if all of the
65 allocated physical extents are already contiguous.
66 .TP
67 .B \-\-resync
68 Forces the complete resynchronization of a mirror. In normal
69 circumstances you should not need this option because synchronization
70 happens automatically. Data is read from the primary mirror device
71 and copied to the others, so this can take a considerable amount of
72 time - and during this time you are without a complete redundant copy
73 of your data.
74 .TP
75 .B \-\-minor \fIminor
76 Set the minor number.
77 .TP
78 .BR \-\-monitor " {" \fIy | \fIn }
79 Start or stop monitoring a mirrored or snapshot logical volume with
80 dmeventd, if it is installed.
81 If a device used by a monitored mirror reports an I/O error,
82 the failure is handled according to
83 \fBmirror_image_fault_policy\fP and \fBmirror_log_fault_policy\fP
84 set in \fBlvm.conf\fP.
85 .TP
86 .BR \-\-poll " {" \fIy | \fIn }
87 Without polling a logical volume's backgrounded transformation process
88 will never complete. If there is an incomplete pvmove or lvconvert (for
89 example, on rebooting after a crash), use \fB\-\-poll y\fP to restart the
90 process from its last checkpoint. However, it may not be appropriate to
91 immediately poll a logical volume when it is activated, use
92 \fB\-\-poll n\fP to defer and then \fB\-\-poll y\fP to restart the process.
93 .TP
94 .B \-\-sysinit
95 Indicates that \fBlvchange\fP(8) is being invoked from early system
96 initialisation scripts (e.g. rc.sysinit or an initrd),
97 before writeable filesystems are available. As such,
98 some functionality needs to be disabled and this option
99 acts as a shortcut which selects an appropriate set of options. Currently
100 this is equivalent to using \fB\-\-ignorelockingfailure\fP,
101 \fB\-\-ignoremonitoring\fP, \fB\-\-poll n\fP and setting
102 \fBLVM_SUPPRESS_LOCKING_FAILURE_MESSAGES\fP
103 environment variable.
104 .TP
105 .B \-\-noudevsync
106 Disable udev synchronisation. The
107 process will not wait for notification from udev.
108 It will continue irrespective of any possible udev processing
109 in the background. You should only use this if udev is not running
110 or has rules that ignore the devices LVM2 creates.
111 .TP
112 .B \-\-ignoremonitoring
113 Make no attempt to interact with dmeventd unless \fB\-\-monitor\fP
114 is specified.
115 Do not use this if dmeventd is already monitoring a device.
116 .TP
117 .BR \-M ", " \-\-persistent " {" \fIy | \fIn }
118 Set to y to make the minor number specified persistent.
119 .TP
120 .BR \-p ", " \-\-permission " {" \fIr | \fIrw }
121 Change access permission to read-only or read/write.
122 .TP
123 .BR \-r ", " \-\-readahead " {" \fIReadAheadSectors | \fIauto | \fInone }
124 Set read ahead sector count of this logical volume.
125 For volume groups with metadata in lvm1 format, this must
126 be a value between 2 and 120 sectors.
127 The default value is "auto" which allows the kernel to choose
128 a suitable value automatically.
129 "None" is equivalent to specifying zero.
130 .TP
131 .B \-\-refresh
132 If the logical volume is active, reload its metadata.
133 This is not necessary in normal operation, but may be useful
134 if something has gone wrong or if you're doing clustering
135 manually without a clustered lock manager.
136 .SH Examples
137 Changes the permission on volume lvol1 in volume group vg00 to be read-only:
138 .sp
139 .B lvchange -pr vg00/lvol1
140 .SH SEE ALSO
141 .BR lvm (8),
142 .BR lvcreate (8),
143 .BR vgchange (8)
This page took 0.044353 seconds and 6 git commands to generate.