diff options
author | Ben Pfaff <blp@nicira.com> | 2012-07-27 15:52:21 -0700 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2012-08-01 10:55:57 -0700 |
commit | f973f2af2fd4452c8e182caf6a4346cf2a2a394e (patch) | |
tree | eb0a4ac92b8457ef682dfa89447342b209bf0f88 /ovsdb | |
parent | 01ca539f5c89fab1ea9a355d4cb75383dfb25da5 (diff) | |
download | openvswitch-f973f2af2fd4452c8e182caf6a4346cf2a2a394e.tar.gz |
Make the location of the database separately configurable.
The default is unchanged, /etc/openvswitch/conf.db.
This makes it possible to transition each Open vSwitch packaging from
/etc/openvswitch/conf.db to /var/lib/openvswitch/conf.db independently.
Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'ovsdb')
-rw-r--r-- | ovsdb/ovsdb-server.1.in | 2 | ||||
-rw-r--r-- | ovsdb/ovsdb-server.c | 2 | ||||
-rw-r--r-- | ovsdb/ovsdb-tool.1.in | 2 | ||||
-rw-r--r-- | ovsdb/ovsdb-tool.c | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/ovsdb/ovsdb-server.1.in b/ovsdb/ovsdb-server.1.in index 4236f8ff2..1f5be03a8 100644 --- a/ovsdb/ovsdb-server.1.in +++ b/ovsdb/ovsdb-server.1.in @@ -26,7 +26,7 @@ vSwitch database (OVSDB). It supports JSON-RPC client connections over active or passive TCP/IP or Unix domain sockets. .PP The OVSDB file may be specified on the command line as \fIdatabase\fR. -The default is \fB@sysconfdir@/openvswitch/conf.db\fR. The database +The default is \fB@DBDIR@/conf.db\fR. The database file must already have been created and initialized using, for example, \fBovsdb\-tool create\fR. . diff --git a/ovsdb/ovsdb-server.c b/ovsdb/ovsdb-server.c index 139acc611..6c68e506b 100644 --- a/ovsdb/ovsdb-server.c +++ b/ovsdb/ovsdb-server.c @@ -808,7 +808,7 @@ parse_options(int argc, char *argv[], char **file_namep, switch (argc) { case 0: - *file_namep = xasprintf("%s/openvswitch/conf.db", ovs_sysconfdir()); + *file_namep = xasprintf("%s/conf.db", ovs_dbdir()); break; case 1: diff --git a/ovsdb/ovsdb-tool.1.in b/ovsdb/ovsdb-tool.1.in index c440e0d6b..9d3284457 100644 --- a/ovsdb/ovsdb-tool.1.in +++ b/ovsdb/ovsdb-tool.1.in @@ -148,7 +148,7 @@ record. .SS "Other Options" .so lib/common.man .SH "FILES" -The default \fIdb\fR is \fB@sysconfdir@/openvswitch/conf.db\fR. The +The default \fIdb\fR is \fB@DBDIR@/conf.db\fR. The default \fIschema\fR is \fB@pkgdatadir@/vswitch.ovsschema\fR. The \fBhelp\fR command also displays these defaults. .SH "SEE ALSO" diff --git a/ovsdb/ovsdb-tool.c b/ovsdb/ovsdb-tool.c index f5412f36b..49594781d 100644 --- a/ovsdb/ovsdb-tool.c +++ b/ovsdb/ovsdb-tool.c @@ -140,7 +140,7 @@ default_db(void) { static char *db; if (!db) { - db = xasprintf("%s/conf.db", ovs_sysconfdir()); + db = xasprintf("%s/conf.db", ovs_dbdir()); } return db; } |