1TKRZW_DBM_UTIL(1)                User Commands               TKRZW_DBM_UTIL(1)
2
3
4

NAME

6       tkrzw_dbm_util - manual page for tkrzw_dbm_util 1.0.24
7

DESCRIPTION

9       tkrzw_dbm_util: DBM utilities of Tkrzw
10
11   Usage:
12              tkrzw_dbm_util  create  [common_options]  [tuning_options]  [op‐
13              tions] file
14
15              : Creates a database file.
16
17              tkrzw_dbm_util inspect [common_options] file [attr]
18
19              : Prints inspection of a database file.
20
21              tkrzw_dbm_util get [common_options] file key
22
23              : Gets a record and prints it.
24
25              tkrzw_dbm_util set [common_options] [options] file key
26
27              : Sets a record.
28
29              tkrzw_dbm_util remove [common_options] file key
30
31              : Removes a record.
32
33              tkrzw_dbm_util rekey [common_options] file old_key new_key
34
35              : Changes the key of a record.
36
37              tkrzw_dbm_util list [common_options] file
38
39              : Lists up records and prints them.
40
41              tkrzw_dbm_util rebuild [common_options] [tuning_options] file
42
43              : Rebuilds a database file for optimization.
44
45              tkrzw_dbm_util restore [common_options] old_file [new_file]
46
47              : Restores a broken database file.
48
49              tkrzw_dbm_util merge [common_options] dest_file src_files...
50
51              : Merges database files.
52
53              tkrzw_dbm_util  export   [common_options]   [options]   dbm_file
54              rec_file
55
56              : Exports records to a flat record file.
57
58              tkrzw_dbm_util   import   [common_options]   [options]  dbm_file
59              rec_file
60
61              : Imports records from a flat record file.
62
63   Common options:
64       --dbm impl : The name of a DBM implementation: auto, hash, tree,  skip,
65              tiny,  baby,  cache,  stdhash,  stdtree,  poly, shard. (default:
66              auto)
67
68       --file impl : The name of a file implementation: mmap-para,  mmap-atom,
69              pos-para, pos-atom. (default: mmap-para)
70
71       --no_wait : Fails if the file is locked by another process.
72
73       --no_lock : Omits file locking.
74
75       --sync_hard : Synchronizes the file physically when closing.
76
77       --alloc_init num : The initial allocation size. (default: 1048576)
78
79       --alloc_inc num : The allocation increment factor. (default: 2.0)
80
81       --block_size  num  : The block size of the positional access file. (de‐
82              fault: 1)
83
84       --direct_io : Enables the direct I/O option of  the  positional  access
85              file.
86
87       --sync_io : Enables the synchronous I/O option of the positional access
88              file.
89
90       --padding : Enables padding at the end of the file.
91
92       --pagecache : Enables the mini page cache in the process.
93
94       --multi : Calls xxxMulti methods for get, set, and remove subcommands.
95
96   Options for the create subcommand:
97       --truncate : Truncates an existing database file.
98
99   Options for the inspect subcommand:
100       --validate : Validates records.
101
102   Options for the set subcommand:
103       --no_overwrite : Fails if there's an existing record with the same key.
104
105       --append str : Appends the value at the end after the given delimiter.
106
107       --incr num : Increments the value with the given initial value.
108
109       --reducer func : Sets the reducer for the skip database:  none,  first,
110              second,  last, concat, concatnull, concattab, concatline, total.
111              (default: none)
112
113   Options for the rekey subcommand:
114       --no_overwrite : Fails if there's an existing record with the same key.
115
116   Options for the list subcommand:
117       --move type : Type of movement: first, jump,  jumplower,  jumplowerinc,
118              jumpupper, jumpupperinc. (default: first)
119
120       --jump_key str : Specifies the jump key. (default: empty string)
121
122       --items num : The number of items to print. (default: 10)
123
124       --escape : C-style escape is applied to the TSV data.
125
126       --keys : Prints keys only.
127
128   Options for the rebuild subcommand:
129       --restore : Skips broken records to restore a broken database.
130
131   Options for the restore subcommand:
132       --auto  str  :  The restore mode automatically done: none, default, de‐
133              fault-ns, sync, sync-ns. (default: none)
134
135       --end_offset : The exclusive end offset of records to  read.  (default:
136              -1)
137
138       --class : The class name given to PolyDBM or ShardDBM.
139
140   Options for the merge subcommand:
141       --reducer  func  : Sets the reducer for the skip database: none, first,
142              second, last, concat, concatnull, concattab, concatline,  total.
143              (default: none)
144
145   Options for the export and import subcommands:
146       --tsv : The record file is in TSV format instead of flat record.
147
148       --escape : C-style escape/unescape is applied to the TSV data.
149
150       --keys : Exports keys only.
151
152       --ulog num : Uses update logs based on the timestamp.
153
154       --ulog_ids  num  num  :  Sets the server ID and the DBM index of update
155              logs.
156
157   Tuning options for HashDBM:
158       --in_place : Uses in-place rather than pre-defined ones.
159
160       --append : Uses appending rather than pre-defined ones.
161
162       --record_crc num : The record CRC mode: -1, 0, 8, 16, 32.  (default:  0
163              or -1)
164
165       --record_comp  str  : The record compression mode: default, none, zlib,
166              zstd, lz4, lzma. (default: none or default)
167
168       --offset_width num : The width to represent the offset of records. (de‐
169              fault: 4 or -1)
170
171       --align_pow num : Sets the power to align records. (default: 3 or -1)
172
173       --buckets  num  :  Sets  the  number  of buckets for hashing. (default:
174              1048583 or -1)
175
176   Tuning options for TreeDBM:
177       --in_place : Uses in-place rather than pre-defined ones.
178
179       --append : Uses appending rather than pre-defined ones.
180
181       --record_crc num : The record CRC mode: -1, 0, 8, 16, 32.  (default:  0
182              or -1)
183
184       --record_comp  str  : The record compression mode: default, none, zlib,
185              zstd, lz4, lzma. (default: none or default)
186
187       --offset_width num : The width to represent the offset of records. (de‐
188              fault: 4 or -1)
189
190       --align_pow num : Sets the power to align records. (default: 10 or -1)
191
192       --buckets  num  :  Sets  the  number  of buckets for hashing. (default:
193              131101 or -1)
194
195       --max_page_size num : Sets the maximum size of a page.  (default:  8130
196              or -1)
197
198       --max_branches  num  :  Sets  the  maximum  number of branches of inner
199              nodes. (default: 256 or -1)
200
201       --comparator func : Sets the key comparator: lex,  lexcase,  dec,  hex.
202              (default: lex)
203
204   Tuning options for SkipDBM:
205       --offset_width num : The width to represent the offset of records. (de‐
206              fault: 4)
207
208       --step_unit num : Sets the step unit of the skip list. (default: 4)
209
210       --max_level num : Sets the maximum level of the  skip  list.  (default:
211              14)
212
213       --sort_mem_size  num : Sets the memory size used for sorting. (default:
214              268435456)
215
216       --insert_in_order : Inserts records in ascending order of the key.
217
218   Options for PolyDBM and ShardDBM:
219       --params str : Sets the parameters in "key=value,key=value" format.
220
221
222
223tkrzw_dbm_util 1.0.24             April 2022                 TKRZW_DBM_UTIL(1)
Impressum