~pr0gg3d/ubuntu/oneiric/util-linux/bug-805886

« back to all changes in this revision

Viewing changes to libs/blkid/libblkid.3

  • Committer: Bazaar Package Importer
  • Author(s): Scott James Remnant
  • Date: 2009-07-16 15:48:23 UTC
  • mfrom: (1.3.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20090716154823-i26fshvs4v8h90qh
Tags: 2.16-1ubuntu1
* Merge from Debian, remaining changes:
  - Since udev is required in Ubuntu, the hwclock.sh init script is
    not called on startup and the hwclockfirst.sh init script is
    removed.
  - Remove /etc/adjtime on upgrade if it was not used.
  - Install custom blkid.conf to use /dev/.blkid.tab since we don't
    expect device names to survive a reboot
  - No lsb_release call in mount.preinst since we'd need Pre-Depends
    (LP: #383697).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.\" Copyright 2001 Andreas Dilger (adilger@turbolinux.com)
2
 
.\"
3
 
.\" This man page was created for libblkid.so.1.0 from e2fsprogs-1.24.
4
 
.\"
5
 
.\" This file may be copied under the terms of the GNU Public License.
6
 
.\"
7
 
.\" Created  Wed Sep 14 12:02:12 2001, Andreas Dilger
8
 
.TH LIBBLKID 3 "May 2009" "util-linux-ng"
9
 
.SH NAME
10
 
libblkid \- block device identification library
11
 
.SH SYNOPSIS
12
 
.B #include <blkid/blkid.h>
13
 
.sp
14
 
.B cc
15
 
.I file.c
16
 
.B \-lblkid
17
 
.SH DESCRIPTION
18
 
The
19
 
.B libblkid
20
 
library is used to identify block devices (disks) as to their content (e.g.
21
 
filesystem type) as well as extracting additional information such as
22
 
filesystem labels/volume names, unique identifiers/serial numbers, etc.
23
 
A common use is to allow use of LABEL= and UUID= tags instead of hard-coding
24
 
specific block device names into configuration files.
25
 
.P
26
 
Block device information is normally kept in a cache file
27
 
.I /etc/blkid.tab
28
 
and is verified to still be valid before being returned to the user
29
 
(if the user has read permission on the raw block device, otherwise not).
30
 
The cache file also allows unprivileged users (normally anyone other
31
 
than root, or those not in the "disk" group) to locate devices by label/id.
32
 
The standard location of the cache file can be overridden by the
33
 
environment variable BLKID_FILE.
34
 
.P
35
 
In situations where one is getting information about a single known device,
36
 
it does not impact performance whether the cache is used or not (unless you
37
 
are not able to read the block device directly).  If you are dealing with
38
 
multiple devices, use of the cache is highly recommended (even if empty) as
39
 
devices will be scanned at most one time and the on-disk cache will be
40
 
updated if possible.  There is rarely a reason not to use the cache.
41
 
.P
42
 
In some cases (modular kernels), block devices are not even visible until
43
 
after they are accessed the first time, so it is critical that there is
44
 
some way to locate these devices without enumerating only visible devices,
45
 
so the use of the cache file is
46
 
.B required
47
 
in this situation.
48
 
.SH CONFIGURATION FILE
49
 
The standard location of the
50
 
.I /etc/blkid.conf
51
 
config file can be overridden by the environment variable BLKID_CONF.
52
 
The following options control the libblkid library:
53
 
.TP
54
 
.I SEND_UEVENT=<yes|not>
55
 
Sends uevent when
56
 
.I /dev/disk/by-{label,uuid}/
57
 
symlink does not match with LABEL or UUID on the device. Default is "yes".
58
 
.TP
59
 
.I CACHE_FILE=<path>
60
 
Overrides the standard location of the cache file. This setting can be
61
 
overridden by the environment variable BLKID_FILE. Default is
62
 
.I /etc/blkid.tab.
63
 
.TP
64
 
.I EVALUATE=<methods>
65
 
Defines LABEL and UUID evaluation method(s). Currently, the libblkid library
66
 
supports "udev" and "scan" methods. More than one methods may be specified in
67
 
a comma separated list. Default is "udev,scan". The "udev" method uses udev
68
 
.I /dev/disk/by-*
69
 
symlinks and the "scan" method scans all block devices from the
70
 
.I /proc/partitions
71
 
file.
72
 
.SH AUTHOR
73
 
.B libblkid
74
 
was written by Andreas Dilger for the ext2 filesystem utilties, with input
75
 
from Ted Ts'o.  The library was subsequently heavily modified by Ted Ts'o.
76
 
 
77
 
The low-level probing code was rewritten by Karel Zak.
78
 
.SH FILES
79
 
.TP 18
80
 
.I /etc/blkid.tab
81
 
caches data extracted from each recognized block device
82
 
.TP
83
 
.I /etc/blkid.conf
84
 
configuration file
85
 
.SH AVAILABILITY
86
 
.B libblkid
87
 
is part of the util-linux-ng package since version 2.15 and is available from
88
 
ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng/.
89
 
.SH COPYING
90
 
.B libblkid
91
 
is available under the terms of the GNU Library General Public License (LGPL),
92
 
version 2 (or at your discretion any later version).  A copy of the LGPL
93
 
should be included with this library in the file COPYING.  If not, write to
94
 
.RS
95
 
Free Software Foundation, Inc.
96
 
.br
97
 
51 Franklin St
98
 
.br
99
 
Fifth Floor
100
 
.br
101
 
Boston, MA  02110-1301  USA
102
 
.RE
103
 
.PP
104
 
or visit
105
 
.UR http://www.gnu.org/licenses/licenses.html#LGPL
106
 
http://www.gnu.org/licenses/licenses.html#LGPL
107
 
.UE
108
 
.SH "SEE ALSO"
109
 
.BR blkid (8)
110
 
.BR findfs (8)