tests: Fix unit test failures related to additional logging.
[openvswitch] / ovsdb / ovsdb-server.c
index 7f53e177fc20de85380cee9d6888945fb0cc2080..139acc61107b4037564977ca97eaafc8d96b9b0d 100644 (file)
@@ -137,6 +137,13 @@ main(int argc, char *argv[])
 
     daemonize_complete();
 
+    if (!run_command) {
+        /* ovsdb-server is usually a long-running process, in which case it
+         * makes plenty of sense to log the version, but --run makes
+         * ovsdb-server more like a command-line tool, so skip it.  */
+        VLOG_INFO("%s (Open vSwitch) %s", program_name, VERSION);
+    }
+
     unixctl_command_register("exit", "", 0, 0, ovsdb_server_exit, &exiting);
     unixctl_command_register("ovsdb-server/compact", "", 0, 0,
                              ovsdb_server_compact, file);