1uniconv(1) Netatalk uniconv(1)
2
3
4
6 uniconv - convert Netatalk volume encoding
7
9 uniconv [-ndv] -c cnidbackend -f fromcode -t tocode [-m maccode] vol‐
10 umepath
11
13 uniconv converts the volume encoding of volumepath from the fromcode to
14 the tocode encoding.
15
17 -c CNID backend used on this volume, usually cdb or dbd. Should
18 match the backend selected with afpd for this volume. If not
19 specified, the default CNID backend `cdb' is used
20
21 -d don't CAP encode leading dots (:2e), equivalent to usedots in
22 AppleVolumes.default(5)
23
24 -f encoding to convert from, use ASCII for CAP encoded volumes
25
26 -h display help
27
28 -m Macintosh client codepage, required for CAP encoded volumes.
29 Defaults to `MAC_ROMAN'
30
31 -n `dry run', don't do any real changes
32
33 -t volume encoding to convert to, e.g. UTF8
34
35 -v verbose output, use twice for maximum logging.
36
37 -V print version and exit
38
40 Setting the wrong options might render your data unusable!!! Make sure
41 you know what you are doing. Always backup your data first.
42
43 It is *strongly* recommended to do a `dry run' first and to check the
44 output for conversion errors.
45
46 afpd(8) should not be running while you change the volume encoding.
47 Remember to change volcodepage in AppleVolumes.default(5) to the new
48 codepage, before restarting afpd.
49
50 USE AT YOUR OWN RISK!!!
51
53 Netatalk provides internal support for UTF-8 (pre- and decomposed) and
54 CAP. If you want to use other charsets, they must be provided by
55 iconv(1)
56
57 uniconv also knows iso-8859.adapted, an old style 1.x NLS widely used.
58 This is only intended for upgrading old volumes, afpd(8) cannot handle
59 iso-8859.adapted anymore.
60
62 The CNID backends maintains name to ID mappings. If you change a file‐
63 name outside afpd(8) (shell, samba), the CNID db, i.e. the DIDNAME
64 index, gets inconsistent. Netatalk tries to recover from such inconsis‐
65 tencies as gracefully as possible. The mechanisms to resolve such
66 inconsistencies may fail sometimes, though, as this is not an easy task
67 to accomplish. I.e. if several names in the path to the file or direc‐
68 tory have changed, things may go wrong.
69
70 If you change a lot of filenames at once, chances are higher that the
71 afpds fallback mechanisms fail, i.e. files will be assigned new IDs,
72 even though the file hasn't changed. uniconv therefore updates the CNID
73 entry for each file/directory directly after it changes the name to
74 avoid inconsistencies. The two supported backends for volumes, dbd and
75 cdb, use the same CNID db format. Therefore, you could use uniconv with
76 cdb and afpd with dbd later.
77
78 Warning: There must not be two processes opening the CNID database
79 using different backends at once! If a volume is still opened with dbd
80 (cnid_metad/cnid_dbd) and you start uniconv with cdb, the result will
81 be a corrupted CNID database, as the two backends use different locking
82 schemes. You might run into additional problems, e.g. if dbd is com‐
83 piled with transactions, cdb will not update the transaction logs.
84
85 In general, it is recommended to use the same backend for uniconv you
86 are using with afpd(8).
87
89 convert 1.x CAP encoded volume to UTF-8, clients used MacRoman code‐
90 page, cnidscheme is dbd:
91
92 example% uniconv -c dbd -f ASCII -t UTF8 -m MAC_ROMAN /path/to/share
93
94 convert iso8859-1 volume to UTF-8, cnidscheme is cdb:
95
96 example% uniconv -c cdb -f ISO-8859-1 -t UTF8 -m MAC_ROMAN /path/to/share
97
98 convert 1.x volume using iso8859-1 adapted NLS to CAP encoding:
99
100 example% uniconv -f ISO-8859-ADAPTED -t ASCII -m MAC_ROMAN/path/to/share
101
102 convert UTF-8 volume to CAP, for MacCyrillic clients:
103
104 example% uniconv -f UTF8 -t ASCII -m MAC_CYRILLIC /path/to/share
105
107 AppleVolumes.default(5),afpd(8),iconv(1),cnid_metad(8),cnid_dbd(8)
108
109
110
111
1122.0.3 24 Jun 2004 uniconv(1)