diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/gdbm.texi | 62 |
1 files changed, 58 insertions, 4 deletions
diff --git a/doc/gdbm.texi b/doc/gdbm.texi index 0876f8d..8920839 100644 --- a/doc/gdbm.texi +++ b/doc/gdbm.texi | |||
@@ -1956,6 +1956,24 @@ the database already exists, it will be deleted, so use it sparingly. | |||
1956 | @section gdbmtool invocation | 1956 | @section gdbmtool invocation |
1957 | @cindex command line options, @command{gdbmtool} | 1957 | @cindex command line options, @command{gdbmtool} |
1958 | 1958 | ||
1959 | When started without additional arguments, @command{gdbmtool} operates | ||
1960 | on the default database @file{junk.gdbm}. Otherwise, the first | ||
1961 | argument supplies the name of the database to operate upon. If neither | ||
1962 | any additional arguments nor the @option{-f} (@option{--file}) option | ||
1963 | are given, @command{gdbmtool} opens starts interactive shell and | ||
1964 | receives commands directly from the human operator. | ||
1965 | |||
1966 | If more than one arguments are given, all arguments past the database | ||
1967 | name are parsed as @command{gdbmtool} commands (@pxref{shell}, for a | ||
1968 | description of available commands) and executed in turn. All commands, | ||
1969 | except the last one, should be terminated with semicolons. Semicolon | ||
1970 | after the last command is optional. Note, that semicolons should be | ||
1971 | escaped in order to prevent them from being interpreted by the shell. | ||
1972 | |||
1973 | Finally, if the @option{-f} (@option{--file}) option is supplied, its | ||
1974 | argument specifies the name of the disk file with @command{gdbmtool} | ||
1975 | script. The program will open that file and read commands from it. | ||
1976 | |||
1959 | The following table summarizes all @command{gdbmtool} command line | 1977 | The following table summarizes all @command{gdbmtool} command line |
1960 | options: | 1978 | options: |
1961 | 1979 | ||
@@ -2022,10 +2040,11 @@ detects end-of-file on its standard input, whichever occurs first. | |||
2022 | 2040 | ||
2023 | A @command{gdbmtool} command consists of a @dfn{command verb}, | 2041 | A @command{gdbmtool} command consists of a @dfn{command verb}, |
2024 | optionally followed by @dfn{arguments}, separated by any | 2042 | optionally followed by @dfn{arguments}, separated by any |
2025 | amount of white space. A command verb can be entered either in full | 2043 | amount of white space and terminated with a newline or semicolon. |
2026 | or in an abbreviated form, as long as that abbreviation does not match | 2044 | A command verb can be entered either in full or in an abbreviated |
2027 | any other verb. For example, @samp{co} can be used instead of | 2045 | form, as long as that abbreviation does not match any other verb. For |
2028 | @samp{count} and @samp{ca} instead of @samp{cache}. | 2046 | example, @samp{co} can be used instead of @samp{count} and @samp{ca} |
2047 | instead of @samp{cache}. | ||
2029 | 2048 | ||
2030 | Any sequence of non-whitespace characters appearing after the command | 2049 | Any sequence of non-whitespace characters appearing after the command |
2031 | verb forms an argument. If the argument contains whitespace or | 2050 | verb forms an argument. If the argument contains whitespace or |
@@ -2305,6 +2324,14 @@ Print the number of entries in the database. | |||
2305 | Print the current bucket. | 2324 | Print the current bucket. |
2306 | @end deffn | 2325 | @end deffn |
2307 | 2326 | ||
2327 | @deffn {command verb} debug [[+-]@var{token}...] | ||
2328 | If @command{GDBM} is configured with additional debugging, this | ||
2329 | statement queries or sets @command{GDBM} internal debugging level. | ||
2330 | This is intended for debugging and testing purposes and requires | ||
2331 | good knowledge of @command{GDBM} internals. The use of this command is | ||
2332 | not recommended. | ||
2333 | @end deffn | ||
2334 | |||
2308 | @deffn {command verb} delete @var{key} | 2335 | @deffn {command verb} delete @var{key} |
2309 | Delete record with the given @var{key} | 2336 | Delete record with the given @var{key} |
2310 | @end deffn | 2337 | @end deffn |
@@ -2423,6 +2450,33 @@ Specifies the permissions to use in case a new file is created. | |||
2423 | Close the database and quit the utility. | 2450 | Close the database and quit the utility. |
2424 | @end deffn | 2451 | @end deffn |
2425 | 2452 | ||
2453 | @deffn {command verb} recover [@var{options}] | ||
2454 | Run database recovery. The following @var{options} are understood: | ||
2455 | |||
2456 | @table @option | ||
2457 | @item backup | ||
2458 | Create a backup copy of the original database. | ||
2459 | |||
2460 | @item max-failed-buckets=@var{n} | ||
2461 | Abort recovery process if @var{n} buckets could not be recovered. | ||
2462 | |||
2463 | @item max-failed-keys=@var{n} | ||
2464 | Abort recovery process if @var{n} keys could not be recovered. | ||
2465 | |||
2466 | @item max-failures=@var{n} | ||
2467 | Abort recovery process after @var{n} failures. A @dfn{failure} in this | ||
2468 | context is either a key or a bucket that failed to be recovered. | ||
2469 | |||
2470 | @item summary | ||
2471 | Print the recovery statistics at the end of the run. The statistics | ||
2472 | includes number of successfully recovered, failed and duplicate keys | ||
2473 | and the number of recovered and failed buckets. | ||
2474 | |||
2475 | @item verbose | ||
2476 | Verbosely list each error encountered. | ||
2477 | @end table | ||
2478 | @end deffn | ||
2479 | |||
2426 | @deffn {command verb} reorganize | 2480 | @deffn {command verb} reorganize |
2427 | Reorganize the database (@pxref{Reorganization}). | 2481 | Reorganize the database (@pxref{Reorganization}). |
2428 | @end deffn | 2482 | @end deffn |