upstream issue < https://issues.apache.org/jira/browse/ZOOKEEPER-2095
suggests the following
ExecStart=/usr/bin/java \
-Dzookeeper.log.dir=/var/log/zookeeper \
-Dzookeeper.root.logger=INFO,ROLLINGFILE \
-cp /usr/share/java/zookeeper/* \
-Dlog4j.configuration=file:/etc/zookeeper/log4j.properties \
-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.local._only_=false \
org.apache.zookeeper.server.quorum.QuorumPeerMain \
/etc/zookeeper/zoo.cfg
and it's seems that this is accepted in their SVN (against trunk revision 1685685)
On Tue, Jan 12, 2016 at 2:44 PM, Muayyad AlSadi <alsadi@xxxxxxxxx> wrote:
> - If the socket availability doesn't matter, remove the nohup, redirection, fork stuff and use a "Type = simple" service. Presuming that the java process runs in foreground this should be fine.passing -f to solr or start-foreground to zookeeper would short-circuit the "nohup" as it would use "exec java blah blah" like thisstart-foreground)ZOO_CMD=(exec "$JAVA")"${ZOO_CMD[@]}" "-Dzookeeper.log.dir=${ZOO_LOG_DIR}" "-Dzookeeper.root.logger=${ZOO_LOG4J_PROP}" \which is my preferred way> - If the java process runs in background anyway,no it's not. ZK's java process is a foreground process> - If you need to socket(s) to be available and type = forking doesn't make it (exits parent to early, doesn't fork) the code should be fixed by teaching it to issue a sd_notify (-> Type = notify).can we do this using some "side" command like "ExecStartPost="
-- devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxxx http://lists.fedoraproject.org/admin/lists/devel@xxxxxxxxxxxxxxxxxxxxxxx