]> arthur.barton.de Git - netatalk.git/blob - man/man1/uniconv.1.tmpl
add uniconv man page
[netatalk.git] / man / man1 / uniconv.1.tmpl
1 .TH uniconv 1  24\ Jun\ 2004 "Netatalk 2.0-beta2" 
2 .SH NAME
3 uniconv \- convert Netatalk volume encoding
4 .SH SYNOPSIS
5 \fBuniconv\fR [\-ndv] \-c \fBcnidbackend\fR \-f \fBfromcode\fR \-t \fBtocode\fR [\-m \fBmaccode\fR] \fBvolumepath\fR 
6 .SH DESCRIPTION
7 uniconv converts the volume encoding of
8 \fIvolumepath\fR from the \fIfromcode\fR
9 to the \fItocode\fR encoding.
10 .SH OPTIONS
11 .TP 
12 \-c
13 CNID backend used on this volume, usually cdb or dbd. Should
14 match the backend selected with afpd for this volume. If not
15 specified, the default CNID backend `:DEFAULT_CNID_SCHEME:' is
16 used
17 .TP 
18 \-d
19 don't CAP encode leading dots (:2e), equivalent to
20 \fBusedots\fR in \fBAppleVolumes.default\fR(5)
21 .TP 
22 \-f
23 encoding to convert from, use ASCII for CAP encoded volumes
24 .TP 
25 \-h
26 display help
27 .TP 
28 \-m
29 Macintosh client codepage, required for CAP encoded volumes.
30 Defaults to `MAC_ROMAN'
31 .TP 
32 \-n
33 `dry run', don't do any real changes
34 .TP 
35 \-t
36 volume encoding to convert to, e.g. UTF8
37 .TP 
38 \-v
39 verbose output, use twice for maximum logging.
40 .TP 
41 \-V
42 print version and exit
43 .PP
44 .SH WARNING
45 Setting the wrong options might render your data unusable!!! Make
46 sure you know what you are doing. Always backup your data first.
47 .PP
48 It is \fB*strongly*\fR recommended to do
49 a `dry run' first and to check the output for conversion errors.
50 .PP
51 \fBafpd\fR(8)
52 should \fInot\fR be running while you change the volume
53 encoding. Remember to change \fBvolcodepage\fR in
54 \fBAppleVolumes.default\fR(5)
55 to the new codepage, before restarting afpd.
56 .PP
57 \fBUSE AT YOUR OWN RISK!!!\fR
58 .SH SELECTABLE\ CHARSETS
59 Netatalk provides internal support for UTF\-8 (pre\- and decomposed)
60 and CAP. If you want to use other charsets, they must be provided by
61 \fBiconv\fR(1)
62 .PP
63 uniconv also knows iso\-8859.adapted, an old style
64 1.x NLS widely used. This is only intended for upgrading old volumes,
65 \fBafpd\fR(8)
66 cannot handle iso\-8859.adapted anymore.
67 .SH CNID\ BACKGROUND
68 The CNID backends maintains name to ID mappings. If you change a
69 filename outside afpd(8) (shell, samba), the CNID db, i.e. the DIDNAME
70 index, gets inconsistent. Netatalk tries to recover from such
71 inconsistencies as gracefully as possible. The mechanisms to resolve such
72 inconsistencies may fail sometimes, though, as this is not an easy task to
73 accomplish. I.e. if several names in the path to the file or directory
74 have changed, things may go wrong.
75 .PP
76 If you change a lot of filenames at once, chances are higher that
77 the afpds fallback mechanisms fail, i.e. files will be assigned new IDs,
78 even though the file hasn't changed. uniconv
79 therefore updates the CNID entry for each file/directory directly after it
80 changes the name to avoid inconsistencies. The two supported backends for
81 volumes, dbd and cdb, use the same CNID db format. Therefore, you
82 \fIcould\fR use uniconv with cdb and
83 afpd with dbd later.
84 .PP
85 \fBWarning\fR: There must not be two
86 processes opening the CNID database using different backends at once! If a
87 volume is still opened with dbd (cnid_metad/cnid_dbd) and you start
88 uniconv with cdb, the result will be a corrupted CNID
89 database, as the two backends use different locking schemes. You might run
90 into additional problems, e.g. if dbd is compiled with transactions, cdb
91 will not update the transaction logs.
92 .PP
93 In general, it is recommended to use the same backend for
94 uniconv you are using with
95 \fBafpd\fR(8).
96 .SH EXAMPLES
97 convert 1.x CAP encoded volume to UTF\-8, clients used MacRoman
98 codepage, cnidscheme is dbd:
99 .PP
100 .nf
101 example%\fB uniconv \-c dbd \-f ASCII \-t UTF8 \-m MAC_ROMAN /path/to/share\fR
102 .fi
103 .PP
104 convert iso8859\-1 volume to UTF\-8, cnidscheme is cdb:
105 .PP
106 .nf
107 example%\fB uniconv \-c cdb \-f ISO\-8859\-1 \-t UTF8 \-m MAC_ROMAN /path/to/share\fR
108 .fi
109 .PP
110 convert 1.x volume using iso8859\-1 adapted NLS to CAP encoding:
111 .PP
112 .nf
113 example%\fB uniconv \-f ISO\-8859\-ADAPTED \-t ASCII \-m MAC_ROMAN/path/to/share\fR
114 .fi
115 .PP
116 convert UTF\-8 volume to CAP, for MacCyrillic clients:
117 .PP
118 .nf
119 example%\fB uniconv \-f UTF8 \-t ASCII \-m MAC_CYRILLIC /path/to/share\fR
120 .fi
121 .SH SEE\ ALSO
122 \fBAppleVolumes.default\fR(5),\fBafpd\fR(8),\fBiconv\fR(1),\fBcnid_metad\fR(8),\fBcnid_dbd\fR(8)