summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Lallemand <wlallemand@haproxy.org>2021-11-09 18:16:47 +0100
committerWilliam Lallemand <wlallemand@haproxy.org>2021-11-10 15:53:01 +0100
commit836bda226c730c6ffa4066ffa7be5fa91d70f545 (patch)
treea0aa3e36416a16775201d2ea50e4361bd7747082
parentfab0fdce981149a4e3172f2b81113f505f415595 (diff)
downloadhaproxy-836bda226c730c6ffa4066ffa7be5fa91d70f545.tar.gz
MINOR: mworker: clarify starting/failure messages
Clarify the startup and reload messages: On a successful configuration load, haproxy will emit "Loading success." after successfuly forked the children. When it didn't success to load the configuration it will emit "Loading failure!". When trying to reload the master process, it will emit "Reloading HAProxy".
-rw-r--r--src/haproxy.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/haproxy.c b/src/haproxy.c
index b404f173a..a379cbcae 100644
--- a/src/haproxy.c
+++ b/src/haproxy.c
@@ -777,10 +777,8 @@ static void mworker_reexec()
for (i = 1; i < old_argc; i++)
next_argv[next_argc++] = old_argv[i];
- ha_warning("Reexecuting Master process\n");
signal(SIGPROF, SIG_IGN);
execvp(next_argv[0], next_argv);
-
ha_warning("Failed to reexecute the master process [%d]: %s\n", pid, strerror(errno));
ha_free(&next_argv);
return;
@@ -801,6 +799,7 @@ static void mworker_reexec_waitmode()
/* reload haproxy and emit a warning */
void mworker_reload()
{
+ ha_notice("Reloading HAProxy\n");
mworker_reexec();
}
@@ -859,8 +858,8 @@ void reexec_on_failure()
{
if (!atexit_flag)
return;
- ha_warning("Reexecuting Master process in waitpid mode\n");
usermsgs_clr(NULL);
+ ha_warning("Loading failure!\n");
mworker_reexec_waitmode();
}
@@ -3260,6 +3259,7 @@ int main(int argc, char **argv)
} else {
/* if not in wait mode, reload in wait mode to free the memory */
+ ha_notice("Loading success.\n");
mworker_reexec_waitmode();
}
/* should never get there */