From 3f3941525906cd71f8bb9daed65f46cfc8657be6efc80d8acb898075904a70cd Mon Sep 17 00:00:00 2001 From: Bin Liu Date: Tue, 14 Mar 2017 07:38:15 +0000 Subject: [PATCH] Accepting request 479175 from home:BinLiu:branches:network:ha-clustering:Factory 0001-logconfig.c-make-logging.syslog_priority-and-logging.patch OBS-URL: https://build.opensuse.org/request/show/479175 OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/corosync?expand=0&rev=81 --- ...-logging.syslog_priority-and-logging.patch | 47 +++++++++++++++++++ corosync.changes | 3 +- corosync.spec | 2 + 3 files changed, 51 insertions(+), 1 deletion(-) create mode 100644 0001-logconfig.c-make-logging.syslog_priority-and-logging.patch diff --git a/0001-logconfig.c-make-logging.syslog_priority-and-logging.patch b/0001-logconfig.c-make-logging.syslog_priority-and-logging.patch new file mode 100644 index 0000000..7fa2af3 --- /dev/null +++ b/0001-logconfig.c-make-logging.syslog_priority-and-logging.patch @@ -0,0 +1,47 @@ +From 5f47e2a8583995cdd80297d4493ce019b02edb14 Mon Sep 17 00:00:00 2001 +From: Bin Liu +Date: Fri, 10 Mar 2017 15:22:13 +0800 +Subject: [PATCH] logconfig.c: make logging.syslog_priority and + logging.logfile_priority to info + +logfile_priority and syslog_priority could be modified by +logging.logger_subsys.{logfile_priority|syslog_priority}. which could +lead to the following output(which are at notice level): + +corosync[21419]: [QUORUM] Using quorum provider corosync_votequorum +corosync[21419]: [QUORUM] Members[1]: 1084777643 +corosync[21419]: [QUORUM] This node is within the primary component + and will provide service. +corosync[21419]: [QUORUM] Members[3]: 1084777563 1084777584 1084777643 + +even the syslog_priority is warning. This patch could avoid the +overwrite. +--- + exec/logconfig.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/exec/logconfig.c b/exec/logconfig.c +index a4d348a..6d0bed6 100644 +--- a/exec/logconfig.c ++++ b/exec/logconfig.c +@@ -401,7 +401,7 @@ static int corosync_main_config_set ( + goto parse_error; + } + } +- else { ++ else if(strcmp(key_name, "logging.syslog_priority") == 0){ + if (logsys_config_syslog_priority_set(subsys, + logsys_priority_id_get("info")) < 0) { + error_reason = "unable to set syslog level"; +@@ -449,7 +449,7 @@ static int corosync_main_config_set ( + goto parse_error; + } + } +- else { ++ else if(strcmp(key_name,"logging.logfile_priority") == 0){ + if (logsys_config_logfile_priority_set(subsys, + logsys_priority_id_get("info")) < 0) { + error_reason = "unable to set syslog level"; +-- +2.6.6 + diff --git a/corosync.changes b/corosync.changes index 33f8abe..552fc21 100644 --- a/corosync.changes +++ b/corosync.changes @@ -1,9 +1,10 @@ ------------------------------------------------------------------- -Tue Feb 28 04:52:04 UTC 2017 - bliu@suse.com +Tue Mar 14 07:14:58 UTC 2017 - bliu@suse.com - L3-Question: corosync logging priority takes no effect(bsc#1023959) added: 0001-Logsys-Change-logsys-syslog_priority-priority.patch + 0001-logconfig.c-make-logging.syslog_priority-and-logging.patch ------------------------------------------------------------------- Tue Dec 6 08:19:09 UTC 2016 - bliu@suse.com diff --git a/corosync.spec b/corosync.spec index c665064..5851b83 100644 --- a/corosync.spec +++ b/corosync.spec @@ -61,6 +61,7 @@ Patch6: bsc#1001164-corosync.conf-example.patch Patch7: corosync-start-stop-level.patch Patch8: disable-build-html-docs.patch Patch9: 0001-Logsys-Change-logsys-syslog_priority-priority.patch +Patch10: 0001-logconfig.c-make-logging.syslog_priority-and-logging.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build # openais is indeed gone and should be uninstalled. Yes, we do not @@ -129,6 +130,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build %patch7 -p1 %patch8 -p1 %patch9 -p1 +%patch10 -p1 %build %if %{with_runautogen}