[6dcb9e77] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
| 7 | <!ENTITY libblockdev-download-http
|
---|
[5bffcec7] | 8 | "https://github.com/storaged-project/libblockdev/releases/download/&libblockdev-version;-1/libblockdev-&libblockdev-version;.tar.gz">
|
---|
[6dcb9e77] | 9 | <!ENTITY libblockdev-download-ftp " ">
|
---|
[2c0da0f] | 10 | <!ENTITY libblockdev-md5sum "b03d1b4def6962aa2e3eb93b50c22163">
|
---|
[a4013fa] | 11 | <!ENTITY libblockdev-size "1.0 MB">
|
---|
[2c0da0f] | 12 | <!ENTITY libblockdev-buildsize "14 MB">
|
---|
[a4013fa] | 13 | <!ENTITY libblockdev-time "0.1 SBU">
|
---|
[6dcb9e77] | 14 | ]>
|
---|
| 15 |
|
---|
| 16 | <sect1 id="libblockdev" xreflabel="libblockdev-&libblockdev-version;">
|
---|
| 17 | <?dbhtml filename="libblockdev.html"?>
|
---|
| 18 |
|
---|
| 19 |
|
---|
| 20 | <title>libblockdev-&libblockdev-version;</title>
|
---|
| 21 |
|
---|
| 22 | <indexterm zone="libblockdev">
|
---|
| 23 | <primary sortas="a-libblockdev">libblockdev</primary>
|
---|
| 24 | </indexterm>
|
---|
| 25 |
|
---|
| 26 | <sect2 role="package">
|
---|
| 27 | <title>Introduction to libblockdev</title>
|
---|
| 28 |
|
---|
| 29 | <para>
|
---|
[0ecaac7] | 30 | libblockdev is a C library supporting GObject Introspection for
|
---|
[6dcb9e77] | 31 | manipulation of block devices. It has a plugin-based architecture where
|
---|
| 32 | each technology (like LVM, Btrfs, MD RAID, Swap,...) is implemented in a
|
---|
| 33 | separate plugin, possibly with multiple implementations (e.g. using LVM
|
---|
| 34 | CLI or the new LVM DBus API).
|
---|
| 35 | </para>
|
---|
| 36 |
|
---|
[6aa631b] | 37 | &lfs120_checked;
|
---|
[6dcb9e77] | 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
| 42 | <para>
|
---|
| 43 | Download (HTTP): <ulink url="&libblockdev-download-http;"/>
|
---|
| 44 | </para>
|
---|
| 45 | </listitem>
|
---|
| 46 | <listitem>
|
---|
| 47 | <para>
|
---|
| 48 | Download (FTP): <ulink url="&libblockdev-download-ftp;"/>
|
---|
| 49 | </para>
|
---|
| 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>
|
---|
| 53 | Download MD5 sum: &libblockdev-md5sum;
|
---|
| 54 | </para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>
|
---|
| 58 | Download size: &libblockdev-size;
|
---|
| 59 | </para>
|
---|
| 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
| 62 | <para>
|
---|
| 63 | Estimated disk space required: &libblockdev-buildsize;
|
---|
| 64 | </para>
|
---|
| 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
| 67 | <para>
|
---|
| 68 | Estimated build time: &libblockdev-time;
|
---|
| 69 | </para>
|
---|
| 70 | </listitem>
|
---|
| 71 | </itemizedlist>
|
---|
| 72 |
|
---|
| 73 | <bridgehead renderas="sect3">libblockdev Dependencies</bridgehead>
|
---|
| 74 |
|
---|
| 75 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
| 76 | <para role="required">
|
---|
[d5e4de79] | 77 | <xref linkend="glib2"/>
|
---|
[6dcb9e77] | 78 | </para>
|
---|
| 79 |
|
---|
[a4013fa] | 80 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
| 81 | <para role="recommended">
|
---|
[d5e4de79] | 82 | <xref linkend="cryptsetup"/>,
|
---|
| 83 | <xref linkend="gobject-introspection"/> (required for GNOME),
|
---|
| 84 | <xref linkend="keyutils"/>,
|
---|
| 85 | <xref linkend="libbytesize"/>,
|
---|
| 86 | <xref linkend="libnvme"/>, and
|
---|
| 87 | <xref linkend="lvm2"/>
|
---|
[a4013fa] | 88 | </para>
|
---|
| 89 |
|
---|
[6dcb9e77] | 90 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 91 | <para role="optional">
|
---|
| 92 | <xref linkend="btrfs-progs"/>,
|
---|
| 93 | <xref linkend="gtk-doc"/>,
|
---|
| 94 | <xref linkend="mdadm"/>,
|
---|
[d5e4de79] | 95 | <xref linkend="parted"/>,
|
---|
| 96 | <xref linkend="volume_key"/>,
|
---|
[8040828] | 97 | <!-- <ulink url="https://people.redhat.com/~heinzm/sw/dmraid/">dmraid</ulink>, -->
|
---|
| 98 | <!-- <ulink url="https://bcachefs.org/">bcachefs</ulink>, -->
|
---|
[cbffe27] | 99 | <ulink url="https://github.com/pmem/ndctl">ndctl</ulink>, and
|
---|
| 100 | <ulink url="https://github.com/Datera/targetcli">targetcli</ulink>
|
---|
| 101 | (for tests)
|
---|
[6dcb9e77] | 102 | </para>
|
---|
| 103 |
|
---|
| 104 | </sect2>
|
---|
| 105 |
|
---|
| 106 | <sect2 role="installation">
|
---|
| 107 | <title>Installation of libblockdev</title>
|
---|
[ca31bd3] | 108 | <!--
|
---|
[ce8e472] | 109 | <para>
|
---|
| 110 | Fix the usage of a glib function deprecated for security:
|
---|
| 111 | </para>
|
---|
| 112 |
|
---|
| 113 | <screen><userinput>sed 's/g_memdup/&2/' -i \
|
---|
| 114 | src/lib/plugin_apis/vdo.{c,api} \
|
---|
| 115 | src/plugins/vdo.c</userinput></screen>
|
---|
[ca31bd3] | 116 | -->
|
---|
[6dcb9e77] | 117 | <para>
|
---|
| 118 | Install <application>libblockdev</application> by running
|
---|
| 119 | the following commands:
|
---|
| 120 | </para>
|
---|
| 121 |
|
---|
[d5e4de79] | 122 | <screen><userinput>./configure --prefix=/usr \
|
---|
| 123 | --sysconfdir=/etc \
|
---|
| 124 | --with-python3 \
|
---|
| 125 | --without-escrow \
|
---|
| 126 | --without-gtk-doc \
|
---|
| 127 | --without-lvm \
|
---|
| 128 | --without-lvm_dbus \
|
---|
| 129 | --without-nvdimm \
|
---|
| 130 | --without-tools &&
|
---|
[6dcb9e77] | 131 | make</userinput></screen>
|
---|
| 132 |
|
---|
| 133 | <para>
|
---|
[cbffe27] | 134 | The test suite requires <application>targetcli</application>, which
|
---|
| 135 | is not a part of BLFS.
|
---|
[6dcb9e77] | 136 | </para>
|
---|
| 137 |
|
---|
| 138 | <para>
|
---|
| 139 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 140 | </para>
|
---|
| 141 |
|
---|
| 142 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 143 |
|
---|
| 144 | </sect2>
|
---|
[d5e4de79] | 145 |
|
---|
[6dcb9e77] | 146 | <sect2 role="commands">
|
---|
| 147 | <title>Command Explanations</title>
|
---|
| 148 |
|
---|
[d5e4de79] | 149 | <para>
|
---|
| 150 | <parameter>--without-escrow</parameter>: This switch allows building
|
---|
| 151 | <application>libblockdev</application> without
|
---|
| 152 | <xref linkend="volume_key"/> installed. Remove it if you've installed
|
---|
| 153 | <xref linkend="volume_key"/>.
|
---|
| 154 | </para>
|
---|
| 155 |
|
---|
| 156 | <para>
|
---|
| 157 | <parameter>--without-lvm --without-lvm_dbus
|
---|
| 158 | --without-tools</parameter>: The combination of these switches allows
|
---|
| 159 | building <application>libblockdev</application> without
|
---|
| 160 | <xref linkend="parted"/> installed. Remove it if you've installed
|
---|
| 161 | <xref linkend="parted"/> and wish to build the
|
---|
| 162 | <command>lvm-cache-stats</command> or <command>vfat-resize</command>
|
---|
| 163 | utilities, or wish <application>libblockdev</application> to support
|
---|
| 164 | logical volumes.
|
---|
| 165 | </para>
|
---|
| 166 |
|
---|
| 167 | <para>
|
---|
| 168 | <option>--without-btrfs --without-mdraid --without-tools</option>:
|
---|
| 169 | The combination of these switches allows building
|
---|
| 170 | <application>libblockdev</application> without
|
---|
| 171 | <xref linkend="libbytesize"/> installed. The
|
---|
| 172 | <option>--without-mdraid</option> option will break
|
---|
| 173 | <xref linkend="udisks2"/>, so don't use it unless you really know what
|
---|
| 174 | you are doing.
|
---|
| 175 | </para>
|
---|
| 176 |
|
---|
| 177 | <para>
|
---|
| 178 | <option>--without-crypto</option>: This switch allows building
|
---|
| 179 | <application>libblockdev</application> without
|
---|
| 180 | <xref linkend="cryptsetup"/> or <xref linkend="keyutils"/> installed.
|
---|
| 181 | This switch will break <xref linkend="udisks2"/>, so don't use it
|
---|
| 182 | unless you really know what you are doing.
|
---|
| 183 | </para>
|
---|
| 184 |
|
---|
| 185 | <para>
|
---|
| 186 | <option>--without-dm --without-lvm --without-lvm_dbus
|
---|
| 187 | --without-mpath</option>: The combination of these switches allows
|
---|
| 188 | building <application>libblockdev</application> without
|
---|
| 189 | <xref linkend="lvm2"/> installed. The <option>--without-dm</option>
|
---|
[2c0da0f] | 190 | and <option>--without-mpath</option> options are not in the instructions
|
---|
| 191 | provided by the book because <xref linkend="lvm2"/> is required for
|
---|
| 192 | <xref linkend="cryptsetup"/> and <xref linkend="cryptsetup"/> is a
|
---|
| 193 | recommended dependency of <application>libblockdev</application> anyway.
|
---|
[d5e4de79] | 194 | </para>
|
---|
| 195 |
|
---|
| 196 | <para>
|
---|
| 197 | <option>--without-nvme</option>: This switch allows building
|
---|
| 198 | <application>libblockdev</application> without
|
---|
| 199 | <xref linkend="libnvme"/> installed. This switch will break
|
---|
| 200 | <xref linkend="udisks2"/>, so don't use it unless you really know what
|
---|
| 201 | you are doing.
|
---|
| 202 | </para>
|
---|
[6dcb9e77] | 203 |
|
---|
| 204 | </sect2>
|
---|
[d5e4de79] | 205 |
|
---|
[6dcb9e77] | 206 | <sect2 role="content">
|
---|
| 207 | <title>Contents</title>
|
---|
| 208 |
|
---|
| 209 | <segmentedlist>
|
---|
| 210 | <segtitle>Installed Programs</segtitle>
|
---|
| 211 | <segtitle>Installed Libraries</segtitle>
|
---|
| 212 | <segtitle>Installed Directories</segtitle>
|
---|
| 213 |
|
---|
| 214 | <seglistitem>
|
---|
| 215 | <seg>
|
---|
[d5e4de79] | 216 | lvm-cache-stats and vfat-resize (both optional)
|
---|
[6dcb9e77] | 217 | </seg>
|
---|
| 218 | <seg>
|
---|
[8558044] | 219 | libbd_btrfs.so,
|
---|
[6dcb9e77] | 220 | libbd_crypto.so,
|
---|
[d5e4de79] | 221 | libbd_dm.so,
|
---|
[8558044] | 222 | libbd_fs.so,
|
---|
[6dcb9e77] | 223 | libbd_loop.so,
|
---|
[d5e4de79] | 224 | libbd_lvm.so (optional),
|
---|
| 225 | libbd_lvm-dbus.so (optional),
|
---|
[6dcb9e77] | 226 | libbd_mdraid.so,
|
---|
| 227 | libbd_mpath.so,
|
---|
[d5e4de79] | 228 | libbd_nvme.so,
|
---|
[6dcb9e77] | 229 | libbd_part.so,
|
---|
| 230 | libbd_swap.so,
|
---|
[d5e4de79] | 231 | libbd_utils.so, and
|
---|
[6dcb9e77] | 232 | libblockdev.so
|
---|
| 233 | </seg>
|
---|
| 234 | <seg>
|
---|
[fa30d84] | 235 | /etc/libblockdev,
|
---|
| 236 | /usr/include/blockdev, and
|
---|
[d5e4de79] | 237 | /usr/share/gtk-doc/html/libblockdev (optional)
|
---|
[6dcb9e77] | 238 | </seg>
|
---|
| 239 | </seglistitem>
|
---|
| 240 | </segmentedlist>
|
---|
[4163b584] | 241 |
|
---|
[6dcb9e77] | 242 | <variablelist>
|
---|
| 243 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 244 | <?dbfo list-presentation="list"?>
|
---|
| 245 | <?dbhtml list-presentation="table"?>
|
---|
| 246 |
|
---|
[4163b584] | 247 | <varlistentry id="lvm-cache-stats">
|
---|
| 248 | <term><command>lvm-cache-stats</command></term>
|
---|
[6dcb9e77] | 249 | <listitem>
|
---|
| 250 | <para>
|
---|
[4c24eb0a] | 251 | prints statistics on caches on LVM Logical Volumes
|
---|
[6dcb9e77] | 252 | </para>
|
---|
[4163b584] | 253 | <indexterm zone="libblockdev lvm-cache-stats">
|
---|
| 254 | <primary sortas="b-lvm-cache-stats">lvm-cache-stats</primary>
|
---|
[6dcb9e77] | 255 | </indexterm>
|
---|
| 256 | </listitem>
|
---|
| 257 | </varlistentry>
|
---|
| 258 |
|
---|
[d5e4de79] | 259 | <varlistentry id="vfat-resize">
|
---|
| 260 | <term><command>vfat-resize</command></term>
|
---|
| 261 | <listitem>
|
---|
| 262 | <para>
|
---|
| 263 | resizes <systemitem class="filesystem">vfat</systemitem>
|
---|
| 264 | file systems
|
---|
| 265 | </para>
|
---|
| 266 | <indexterm zone="libblockdev vfat-resize">
|
---|
| 267 | <primary sortas="b-vfat-resize">vfat-resize</primary>
|
---|
| 268 | </indexterm>
|
---|
| 269 | </listitem>
|
---|
| 270 | </varlistentry>
|
---|
[6dcb9e77] | 271 | </variablelist>
|
---|
[4163b584] | 272 |
|
---|
[6dcb9e77] | 273 | </sect2>
|
---|
| 274 |
|
---|
| 275 | </sect1>
|
---|