<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Here's the config I came up with that works. The biggest change is that type should be forking. Notify requires the service to signal back to systemd that the process has finished starting up which syslog-ng doesn't do and thus ends up timing out.<div class="">Tje -F flag actually blocked the start command when I ran systemctl start syslog-ng.</div><div class=""><br class=""></div><div class="">Since syslog-ng apparently forks over to the supervising process the correct type is forking as the service's exec start is expected to exit immediately after execution with the child process running the service.<br class=""><div class=""><br class=""></div><div class="">Looking at the status for the service show both the supervising and actual process.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div class="">● syslog-ng.service - System Logger Daemon</div><div class="">   Loaded: loaded (/etc/systemd/system/syslog-ng.service; enabled; vendor preset: enabled)</div><div class="">   Active: active (running) since Thu 2019-05-16 19:26:08 UTC; 14s ago</div><div class="">     Docs: man:syslog-ng(8)</div><div class="">  Process: 12591 ExecStart=/opt/syslog-ng/sbin/syslog-ng $SYSLOGNG_OPTIONS --cfgfile $SYSLOGNG_CONF_FILE --control $SYSLOGNG_CONTROL_FILE --persist-file $SYSLOGNG_PERSIST_FILE --pidfile $SYSLOGNG_PID_FILE (code=exited, status=0/SUCCESS)</div><div class=""> Main PID: 12592 (syslog-ng)</div><div class="">   CGroup: /system.slice/syslog-ng.service</div><div class="">           ├─12592 supervising syslog-ng</div><div class="">           └─12593 /opt/syslog-ng/sbin/syslog-ng --no-caps --cfgfile /opt/syslog-ng/etc/syslog-ng.conf --control /opt/syslog-ng/var//syslog-ng.ctl --persist-file /opt/syslog-ng/var//syslog-ng.persist --pidfile /var/run/...</div><div class=""><br class=""></div><div class="">May 16 19:26:08 ip-172-30-6-133.ec2.internal systemd[1]: Starting System Logger Daemon...</div><div class="">May 16 19:26:08 ip-172-30-6-133.ec2.internal systemd[1]: Started System Logger Daemon.</div></div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">syslog-ng.service</div><span class="">[Unit]<br class="">Description=System Logger Daemon<br class="">Documentation=man:syslog-ng(8)<br class="">Wants=network.target network-online.target<br class="">After=network.target network-online.target<br class=""><br class="">[Service]<br class="">Type=forking<br class="">Environment=SYSLOGNG_PID_FILE="/var/run/syslog-ng.pid"<br class="">Environment=SYSLOGNG_CONF_FILE="/opt/syslog-ng/etc/syslog-ng.conf"<br class="">Environment=SYSLOGNG_PERSIST_FILE="/opt/syslog-ng/var//syslog-ng.persist"<br class="">Environment=SYSLOGNG_CONTROL_FILE="/opt/syslog-ng/var//syslog-ng.ctl"<br class="">Environment=SYSLOGNG_OPTIONS="--no-caps"<br class="">ExecStart=/opt/syslog-ng/sbin/syslog-ng $SYSLOGNG_OPTIONS --cfgfile $SYSLOGNG_CONF_FILE --control $SYSLOGNG_CONTROL_FILE --persist-file $SYSLOGNG_PERSIST_FILE --pidfile $SYSLOGNG_PID_FILE<br class="">ExecReload=/bin/kill -HUP $MAINPID<br class="">StandardOutput=journal<br class="">StandardError=journal<br class="">Restart=on-failure<br class="">Environment=LD_LIBRARY_PATH=/usr/lib/jvm/jre-1.8.0/lib/amd64/server:$LD_LIBRARY_PATH<br class=""><br class="">[Install]<br class="">WantedBy=multi-user.target<br class=""><br class=""><br class=""><br class="">Hope this helps anyone else in the future<br class=""><div class="">Ronald Fenner<br class="">Network Architect<br class="">Game Circus LLC.<br class=""><br class=""><a href="mailto:rfenner@gamecircus.com" class="">rfenner@gamecircus.com</a><br class=""></div><br class=""><blockquote type="cite" class="">On May 16, 2019, at 1:07 PM, Ronald Fenner <<a href="mailto:rfenner@gamecircus.com" class="">rfenner@gamecircus.com</a>> wrote:<br class=""><br class="">Thanks I'll look through that and see what changes I may need to make.<br class=""><br class="">I may have found the problem but I'm still waiting on a build to finish is that my java command was broken when I check to see if I could see some of the Kafka streams to confirm it could access the cluster.<br class=""><br class="">I had based mine on the service file listed in GitHub for rhel package and on one that and one I worked up for consul.<br class=""><br class="">Ronald Fenner<br class="">Network Architect<br class="">Game Circus LLC.<br class=""><br class=""><a href="mailto:rfenner@gamecircus.com" class="">rfenner@gamecircus.com</a><br class=""><br class=""><blockquote type="cite" class="">On May 16, 2019, at 11:30 AM, Evan Rempel <erempel@uvic.ca> wrote:<br class=""><br class="">I think you are just missing the forground flag (-F) in the ExecStart command<br class=""><br class="">You can see a discussion of the systemd service unit file at<br class=""><br class="">https://github.com/balabit/syslog-ng/issues/2667<br class=""><br class="">and a proposed service file.<br class=""><br class="">On 5/16/19 8:27 AM, Ronald Fenner wrote:<br class=""><blockquote type="cite" style="font-family: Helvetica; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">I'm trying to switch from an init.d script to a system service and having problems getting the service to run.<br class="">The syslog-ng service gets timed out and never starts up.<br class=""><br class="">My service looks like this:<br class="">[Unit]<br class="">Description="Syslog-ng an enhanced syslog"<br class="">Documentation=man:syslog-ng(8)<br class="">After=network.target<br class="">ConditionFileNotEmpty=/opt/syslog-ng/etc/syslog-ng.conf<br class=""><br class="">[Service]<br class="">Type=notify<br class="">ExecStart=/opt/syslog-ng/sbin/syslog-ng --no-caps -p /var/run/syslogd.pid -rdvt<br class="">ExecReload=/bin/kill -HUP $MAINPID<br class="">StandardOutput=journal<br class="">StandardError=journal<br class="">Restart=on-failure<br class="">Environment=LD_LIBRARY_PATH=/usr/lib/jvm/java/jre/lib/amd64/server:$LD_LIBRARY_PATH<br class=""><br class="">[Install]<br class="">WantedBy=multi-user.target<br class=""><br class=""></blockquote><br class="">______________________________________________________________________________<br class="">Member info: https://lists.balabit.hu/mailman/listinfo/syslog-ng<br class="">Documentation: http://www.balabit.com/support/documentation/?product=syslog-ng<br class="">FAQ: http://www.balabit.com/wiki/syslog-ng-faq<br class=""></blockquote><br class=""></blockquote><br class=""></span></div></body></html>