zabbix-agent doesn't exist anymore since 3.0 '-f' option (foreground) is now in zabbix-agentd 003-change-user-and-foreground.patch fixes pending issue https://support.zabbix.com/browse/ZBX-10611 you might need to update your config file to add LogType=system Signed-off-by: Etienne CHAMPETIER <champetier.etienne@gmail.com>
17 lines
415 B
Diff
17 lines
415 B
Diff
--- a/src/libs/zbxnix/daemon.c
|
|
+++ b/src/libs/zbxnix/daemon.c
|
|
@@ -300,11 +300,14 @@ int daemon_start(int allow_root, const c
|
|
|
|
if (0 == allow_root && 0 == getuid()) /* running as root? */
|
|
{
|
|
+#if 0
|
|
+/* allow changing user and foreground */
|
|
if (0 != (flags & ZBX_TASK_FLAG_FOREGROUND))
|
|
{
|
|
zbx_error("cannot run as root!");
|
|
exit(EXIT_FAILURE);
|
|
}
|
|
+#endif
|
|
|
|
if (NULL == user)
|
|
user = "zabbix";
|