From: Arkadiusz Miƛkiewicz Date: Tue, 6 May 2014 21:27:34 +0000 (+0200) Subject: - rel 3; run all command via daemon(), so limits gets applied correctly and we don... X-Git-Tag: auto/th/ejabberd-13.12-4~1 X-Git-Url: http://git.pld-linux.org/gitweb.cgi?a=commitdiff_plain;h=a778ff6ace9bd8175c2f263817492b937b2f63b9;p=packages%2Fejabberd.git - rel 3; run all command via daemon(), so limits gets applied correctly and we don't hit: File operation error: emfile. --- diff --git a/ejabberd.init b/ejabberd.init index 4b655d1..17514f7 100644 --- a/ejabberd.init +++ b/ejabberd.init @@ -21,19 +21,14 @@ export EJABBERD_DOC_PATH EJABBERD_PID_PATH start() { # Check if the service is already running? if [ ! -f /var/lock/subsys/ejabberd ]; then - msg_starting ejabberd ; busy - /usr/sbin/ejabberdctl start + msg_starting ejabberd + daemon /usr/sbin/ejabberdctl start RETVAL=$? if [ $RETVAL -eq 0 ]; then - /usr/sbin/ejabberdctl started + msg_starting "ejabberd start confirmation" + daemon /usr/sbin/ejabberdctl started RETVAL=$? fi - if [ $RETVAL -eq 0 ]; then - touch /var/lock/subsys/ejabberd - ok - else - fail - fi else msg_already_running ejabberd fi @@ -42,18 +37,14 @@ start() { stop() { # Stop daemons. if [ -f /var/lock/subsys/ejabberd ]; then - msg_stopping ejabberd ; busy - /usr/sbin/ejabberdctl stop 2>/dev/null + msg_stopping ejabberd + daemon /usr/sbin/ejabberdctl stop RETVAL=$? if [ $RETVAL -eq 0 ]; then - /usr/sbin/ejabberdctl stopped 2>/dev/null + msg_starting "ejabberd stop confirmation" + daemon /usr/sbin/ejabberdctl stopped RETVAL=$? fi - if [ $RETVAL -eq 0 ]; then - ok - else - fail - fi rm -f /var/lock/subsys/ejabberd else msg_not_running ejabberd diff --git a/ejabberd.spec b/ejabberd.spec index 0a7454a..bec73f5 100644 --- a/ejabberd.spec +++ b/ejabberd.spec @@ -8,7 +8,7 @@ Summary: Fault-tolerant distributed Jabber/XMPP server Summary(pl.UTF-8): Odporny na awarie rozproszony serwer Jabbera/XMPP Name: ejabberd Version: 13.12 -Release: 2 +Release: 3 License: GPL Group: Applications/Communications Source0: http://www.process-one.net/downloads/ejabberd/%{version}/%{name}-%{version}.tgz