File: features.rst

package info (click to toggle)
libblockdev 2.20-7%2Bdeb10u1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 2,908 kB
  • sloc: ansic: 16,376; python: 8,239; makefile: 560; sh: 487
file content (337 lines) | stat: -rw-r--r-- 5,593 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
Features
=========

*libblockdev* is a C library supporting GObject introspection for manipulation
of block devices. It has a plugin-based architecture where each technology (like
LVM, Btrfs, MD RAID, Swap,...) is implemented in a separate plugin, possibly
with multiple implementations (e.g. using LVM CLI or the new LVM DBus
API). Every plugin is also usable as a standalone shared library.


partitions
-----------

:supported technologies:
   MBR, GPT, partition manipulation on partitionable devices

:functions:
   * mklabel
   * create_part
   * resize_part
   * remove_part


filesystems
------------

:supported technologies:
   * DONE: ext2, ext3, ext4, xfs, vfat, ntfs

:functions:
   * make_FSTYPE
   * resize_FSTYPE
   * check_FSTYPE
   * repair_FSTYPE
   * change_label_FSTYPE

   * wipefs
   * mount
   * unmount
   * generic_resize


LVM
----

:supported technologies:
   "plain LVM", LVM Thin Provisioning

:TODO:
   * read-only locking and default config

:functions:
   * get_global_config
   * set_global_config
   * get_possible_pe_sizes
   * is_supported_pe_size
   * get_max_lv_size
   * round_size_to_pe
   * get_lv_physical_size
   * get_thpool_padding
   * is_valid_thpool_metadata_size
   * is_valid_thpool_chunk_size

   * pvcreate
   * pvresize
   * pvremove
   * pvmove
   * pvscan
   * pvinfo
   * pvs

   * vgcreate
   * vgextend
   * vgremove
   * vgactivate
   * vgdeactivate
   * vgreduce
   * vginfo
   * vgs

   * lvorigin
   * lvcreate
   * lvremove
   * lvresize
   * lvactivate
   * lvdeactivate
   * lvsnapshotcreate
   * lvsnapshotmerge
   * lvinfo
   * lvs

   * thpoolcreate
   * thlvcreate
   * thlvpoolname
   * thsnapshotcreate

   * cache_get_default_md_size
   * cache_get_mode_str
   * cache_get_mode_from_str
   * cache_create_pool
   * cache_attach
   * cache_detach
   * cache_create_cached_lv
   * cache_pool_name
   * cache_stats

   * data_lv_name
   * metadata_lv_name

   * thpool_convert
   * cache_pool_convert

BTRFS
------

:supported technologies:
   btrfs as both filesystem and multi-device volume, subvolumes, snapshots

:functions:
   * create_volume
   * add_device
   * remove_device
   * list_devices
   * create_subvolume
   * delete_subvolume
   * list_subvolumes
   * get_default_subvolume
   * set_default_subvolume
   * create_snapshot
   * filesystem_info
   * mkfs
   * resize
   * check
   * repair
   * change_label


SWAP
-----

:supported technologies:
   swap partitions/LVs, swap files

:functions:
   * mkswap
   * swapon
   * swapoff
   * swapstatus


MDRAID
-------

:supported technologies:
   all RAID levels supported by the MD RAID

:functions:
   * get_superblock_size
   * create
   * destroy
   * activate
   * deactivate
   * run
   * nominate
   * denominate
   * add
   * remove
   * examine
   * canonicalize_uuid
   * get_md_uuid
   * detail
   * node_from_name
   * name_from_node


CRYPTO/LUKS
------------

:supported technologies:
   LUKS1 and LUKS2 encrypted devices, TrueCrypt/VeraCrypt devices (open/close only)

:functions:
   * generate_backup_passphrase
   * device_is_luks
   * luks_uuid
   * luks_status
   * luks_format
   * luks_open
   * luks_close
   * luks_add_key
   * luks_remove_key
   * luks_change_key
   * luks_resize
   * luks_suspend
   * luks_resume
   * luks_header_backup
   * luks_header_restore
   * luks_kill_slot
   * luks_info
   * integrity_info
   * escrow_device
   * tc_open
   * tc_close


MULTIPATH
----------

:supported technologies:
   just very basic functionality

:functions:
   * flush_mpaths
   * device_is_mpath_member
   * get_mpath_members
   * set_friendly_names


LOOP
-----

:supported technologies:
   basic operations with loop devices

:functions:
   * get_backing_file
   * get_loop_name
   * loop_setup
   * loop_teardown


DEVICE MAPPER
--------------

:supported technologies:
   basic operations with raw device mapper and DM RAID sets

:functions:
   * create_linear
   * remove
   * node_from_name
   * name_from_node
   * map_exists
   * get_member_raid_sets
   * activate_raid_set
   * deactivate_raid_set
   * get_raid_set_type


s390
-----

:supported technologies:
   DASD, zFCP

:functions:
   * s390_dasd_format
   * s390_dasd_needs_format
   * s390_dasd_online
   * s390_dasd_is_ldl
   * s390_dasd_is_fba
   * s390_sanitize_dev_input
   * s390_zfcp_sanitize_wwpn_input
   * s390_zfcp_sanitize_lun_input
   * s390_zfcp_online
   * s390_zfcp_scsi_offline
   * s390_zfcp_offline


KBD (Kernel Block Devices)
---------------------------

:supported technologies:
   bcache, zram

:functions:
   * bcache_create
   * bcache_destroy
   * bcache_attach
   * bcache_detach
   * bcache_status
   * bcache_set_mode
   * bcache_get_mode
   * bcache_get_backing_device
   * bcache_get_cache_device

   * zram_create_devices
   * zram_destroy_devices
   * zram_get_stats

NVDIMM
-------

:supported technologies:
   namespaces

:functions:
   * namespace_enable
   * namespace_disable
   * namespace_info
   * namespace_reconfigure
   * list_namespaces

VDO
---

:functions:
   * info
   * create
   * remove
   * change_write_policy
   * enable_compression
   * disable_compression
   * enable_deduplication
   * disable_deduplication
   * activate
   * deactivate
   * start
   * stop
   * grow_logical
   * grow_physical
   * get_statistics

utils
------

Library (not a plugin) providing utility functions usable for multiple plugins
and any third-party code.

:functions:
   * exec_and_report_error
   * exec_and_capture_output
   * size_human_readable
   * size_from_spec
   * init_logging
   * version_cmp
   * check_util_version