Prepend "ovs|" to syslog logs to make them easier to filter out of all
LOG_DAEMON logs.
---
lib/vlog.h | 2 +-
python/ovs/vlog.py | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/vlog.h b/lib/vlog.h
index ab746c8..c7ab206 100644
--- a/lib/vlog.h
+++ b/lib/vlog.h
@@ -52,7 +52,7 @@ enum vlog_level vlog_get_level_val(const char *name);
/* Facilities that we can log to. */
#define VLOG_FACILITIES \
- VLOG_FACILITY(SYSLOG, "%05N|%c%T|%p|%m") \
+ VLOG_FACILITY(SYSLOG, "ovs|%05N|%c%T|%p|%m") \
VLOG_FACILITY(CONSOLE, "%D{%Y-%m-%dT%H:%M:%SZ}|%05N|%c%T|%p|%m") \
VLOG_FACILITY(FILE, "%D{%Y-%m-%dT%H:%M:%SZ}|%05N|%c%T|%p|%m")
enum vlog_facility {
diff --git a/python/ovs/vlog.py b/python/ovs/vlog.py
index 7cfa415..75bf6d0 100644
--- a/python/ovs/vlog.py
+++ b/python/ovs/vlog.py
@@ -61,7 +61,7 @@ class Vlog:
return
now = datetime.datetime.utcnow().strftime("%Y-%m-%dT%H:%M:%SZ")
- syslog_message = ("%s|%s|%s|%s"
+ syslog_message = ("ovs|%s|%s|%s|%s"
% (Vlog.__msg_num, self.name, level, message))
level = LEVELS.get(level.lower(), logging.DEBUG)
--
1.8.1.3
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev