]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - lib/libufs/libufs.3
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / lib / libufs / libufs.3
1 .\" Author:     Juli Mallett <jmallett@FreeBSD.org>
2 .\" Date:       June 04, 2003
3 .\" Description:
4 .\"     Manual page for libufs.
5 .\"
6 .\" This file is in the public domain.
7 .\"
8 .\" $FreeBSD$
9 .\"
10 .Dd June 4, 2003
11 .Dt LIBUFS 3
12 .Os
13 .Sh NAME
14 .Nm libufs
15 .Nd operate on UFS file systems from userland
16 .Sh LIBRARY
17 .Lb libufs
18 .Sh SYNOPSIS
19 .In sys/param.h
20 .In sys/mount.h
21 .In ufs/ufs/ufsmount.h
22 .In ufs/ufs/dinode.h
23 .In ufs/ffs/fs.h
24 .In libufs.h
25 .Sh DESCRIPTION
26 The
27 .Nm
28 library and the functions it provides are used for implementing
29 utilities which need to access a UFS file system at a low level from
30 userland.
31 Facilities provided are used to implement utilities such as
32 .Xr newfs 8
33 and
34 .Xr dumpfs 8 .
35 The
36 .Nm
37 library is designed to be simple, and to provide functions that are
38 traditionally useful to have.
39 .Pp
40 A disk is represented as the type
41 .Vt "struct uufsd"
42 as defined in
43 .In libufs.h .
44 The structure is filled out, operations are performed, and the disk
45 is closed.
46 .Sh ERRORS
47 Functions provided by
48 .Nm
49 return \-1 in every functional error situation.
50 They also set the
51 .Va d_error
52 field of
53 .Vt "struct uufsd"
54 to a string describing the error.
55 .Sh SEE ALSO
56 .Xr bread 3 ,
57 .Xr bwrite 3 ,
58 .Xr cgread 3 ,
59 .Xr cgread1 3 ,
60 .Xr cgwrite1 3 ,
61 .Xr sbread 3 ,
62 .Xr sbwrite 3 ,
63 .Xr ufs_disk_close 3 ,
64 .Xr ufs_disk_fillout 3 ,
65 .Xr ufs_disk_fillout_blank 3 ,
66 .Xr ufs_disk_write 3 ,
67 .Xr ffs 7
68 .Sh HISTORY
69 The
70 .Xr libufs 3
71 library first appeared in
72 .Fx 5.0 .
73 .Sh AUTHORS
74 .An Juli Mallett Aq jmallett@FreeBSD.org
75 .Pp
76 .An -nosplit
77 Additional design, feedback, and ideas were provided by
78 .An Poul-Henning Kamp Aq phk@FreeBSD.org .