3 ovdb_init - Prepare ovdb database for use
7 ovdb_init [C<-u>|C<-r>]
11 This command must be run before any other process can access the
12 overview database. It performs the following steps:
18 Creates the database environment, if necessary
22 If the database is idle (and if the C<-u> option is not specified),
23 it performs a normal recovery. The recovery will remove stale locks,
24 recreate the memory pool cache, and repair any damage caused by a system
25 crash or improper shutdown.
29 If the C<-u> option is specified, it performs any necessary upgrades
30 to the database. See the UPGRADING section below.
34 Starts the DB housekeeping processes (ovdb_monitor) if they're not
35 already running. (Unless the C<-r> option is specified).
39 Starts the ovdb readserver (ovdb_server) processes if C<readserver>
40 in F<ovdb.conf> is C<true>, and if they're not
41 already running. (Unless the C<-r> option is specified).
45 Returns exit status of 0 if all steps were completed successfully.
46 In the event of an error, messages are written to syslog and/or stderr.
48 If a recovery was attempted but it failed, the database may be
49 damaged beyond repair, requiring a rebuild with makehistory(8).
51 This command is normally invoked automatically by rc.news(8).
53 It is OK to run this command multiple times.
61 Perform recovery only. C<ovdb_monitor> is not started.
65 Perform any needed upgrades. Recovery is not attempted.
66 C<ovdb_monitor> is started if the upgrade succeeded.
72 There are two situations in which the database will need to be
79 You upgrade the BerkeleyDB library to a newer version, for example
80 from 2.7.7 to 3.1.17. In this case, the BerkeleyDB db->upgrade()
85 You upgrade ovdb to a newer major version; i.e., ovdb-1.0 to ovdb-2.0.
89 In both of these cases, the database is upgraded in-place; and the
90 upgrade can not be undone. Do not interrupt the upgrade process once
91 it has started, because there is a risk of irrepairable corruption.
92 The upgrade may take several minutes to complete.
93 If an upgrade does get interrupted, try running the upgrade again.
95 Here's an example procedure to upgrade a database created with BerkeleyDB
96 2.7.7 to use BerkeleyDB 3.1.17:
102 Build and install the BerkeleyDB 3.1.17
106 Run configure in the INN source tree and make sure it picks up the
107 right BerkeleyDB directory (e.g., /usr/local/BerkeleyDB.3.1)
115 Shut down INN (e.g., with C<rc.news stop>). Be sure to kill all nnrpds as
120 Do a C<make update> to install the new binaries.
124 Run C<ovdb_init -u> as the news user.
128 Start INN with C<rc.news>
132 It is OK to specify C<-u> even if no upgrades are needed.
136 Written by Heath Kehoe E<lt>hakehoe@avalon.netE<gt> for InterNetNews.
140 ovdb(5), makehistory(8)