]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core/service: downgrade "scheduling restart" message to debug 14112/head
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 22 Nov 2019 13:19:51 +0000 (14:19 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 22 Nov 2019 13:19:51 +0000 (14:19 +0100)
I see we log this during every boot, even though it is a routine expected event:
Nov 12 14:50:01 krowka systemd[1]: systemd-journald.service: Service has no hold-off time (RestartSec=0), scheduling restart.
(and for other services too). Let's downgrade this to debug level.

https://bugzilla.redhat.com/show_bug.cgi?id=1614871

src/core/service.c

index 4b17889eb4861178ce54ce549456fe1f6f9b4cd8..49ad166c26045643c9fc4b24505a929f40a0bd4d 100644 (file)
@@ -3758,12 +3758,12 @@ static int service_dispatch_timer(sd_event_source *source, usec_t usec, void *us
         case SERVICE_AUTO_RESTART:
                 if (s->restart_usec > 0) {
                         char buf_restart[FORMAT_TIMESPAN_MAX];
-                        log_unit_info(UNIT(s),
-                                      "Service RestartSec=%s expired, scheduling restart.",
-                                      format_timespan(buf_restart, sizeof buf_restart, s->restart_usec, USEC_PER_SEC));
+                        log_unit_debug(UNIT(s),
+                                       "Service RestartSec=%s expired, scheduling restart.",
+                                       format_timespan(buf_restart, sizeof buf_restart, s->restart_usec, USEC_PER_SEC));
                 } else
-                        log_unit_info(UNIT(s),
-                                      "Service has no hold-off time (RestartSec=0), scheduling restart.");
+                        log_unit_debug(UNIT(s),
+                                       "Service has no hold-off time (RestartSec=0), scheduling restart.");
 
                 service_enter_restart(s);
                 break;