1BLKDEACTIVATE(8) BLKDEACTIVATE(8)
2
3
4
6 blkdeactivate — utility to deactivate block devices
7
9 blkdeactivate [-d dm_options] [-e] [-h] [-l lvm_options]
10 [-m mpath_options] [-r mdraid_options] [-u] [-v] [device]
11
13 The blkdeactivate utility deactivates block devices. For mounted block
14 devices, it attempts to unmount it automatically before trying to deac‐
15 tivate. The utility currently supports device-mapper devices (DM),
16 including LVM volumes and software RAID MD devices. LVM volumes are
17 handled directly using the lvm(8) command, the rest of device-mapper
18 based devices are handled using the dmsetup(8) command. MD devices are
19 handled using the mdadm(8) command.
20
22 -d, --dmoptions dm_options
23 Comma separated list of device-mapper specific options.
24 Accepted dmsetup(8) options are:
25
26 retry Retry removal several times in case of failure.
27
28 force Force device removal.
29
30 -e, --errors
31 Show errors reported from tools called by blkdeactivate. Without
32 this option, any error messages from these external tools are
33 suppressed and the blkdeactivate itself provides only a summary
34 message to indicate the device was skipped.
35
36 -h, --help
37 Display the help text.
38
39 -l, --lvmoptions lvm_options
40 Comma-separated list of LVM specific options:
41
42 retry Retry removal several times in case of failure.
43
44 wholevg
45 Deactivate the whole LVM Volume Group when processing a
46 Logical Volume. Deactivating the Volume Group as a whole
47 is quicker than deactivating each Logical Volume sepa‐
48 rately.
49
50 -m, --mpathoptions mpath_options
51 Comma-separated list of device-mapper multipath specific
52 options:
53
54 disablequeueing
55 Disable queueing on all multipath devices before deacti‐
56 vation. This avoids a situation where blkdeactivate may
57 end up waiting if all the paths are unavailable for any
58 underlying device-mapper multipath device.
59
60 -r, --mdraidoptions mdraid_options
61 Comma-separated list of MD RAID specific options:
62
63 wait Wait MD device's resync, recovery or reshape action to
64 complete before deactivation.
65
66 -u, --umount
67 Unmount a mounted device before trying to deactivate it. With‐
68 out this option used, a device that is mounted is not deacti‐
69 vated.
70
71 -v, --verbose
72 Run in verbose mode. Use --vv for even more verbose mode.
73
75 Deactivate all supported block devices found in the system, skipping
76 mounted devices. # blkdeactivate
77
78 Deactivate all supported block devices found in the system, unmounting
79 any mounted devices first, if possible. # blkdeactivate -u
80
81 Deactivate the device /dev/vg/lvol0 together with all its holders,
82 unmounting any mounted devices first, if possible. # blkdeactivate -u
83 /dev/vg/lvol0
84
85 Deactivate all supported block devices found in the system. If the
86 deactivation of a device-mapper device fails, retry it. Deactivate the
87 whole Volume Group at once when processing an LVM Logical Volume. #
88 blkdeactivate -u -d retry -l wholevg
89
90 Deactivate all supported block devices found in the system. If the
91 deactivation of a device-mapper device fails, retry it and force
92 removal. # blkdeactivate -d force,retry
93
95 dmsetup(8), lsblk(8), lvm(8), mdadm(8), multipathd(8), umount(8)
96
97
98
99Red Hat, Inc LVM TOOLS 2.02.183(2) (2018-12-07) BLKDEACTIVATE(8)