AW: Kolab eating memory & CPU

Martin Konold martin.konold at erfrakon.de
Mon Jan 31 23:52:57 CET 2005


Am Montag, 31. Januar 2005 19:14 schrieb Bernhard Reiter:

Hi,

> Martin,
> can you say where those permissions are set?

As also mentioned in the comprehensive OpenPKG documentation the users and 
permissions are controlled via rc.service files in /kolab/etc/rc.d.

E.g. kolabd is started as user root.

#!/kolab/lib/openpkg/bash /kolab/etc/rc
##
##  rc.kolabd -- Run-Commands
##

%config
    kolabd_enable="$openpkg_rc_def"

%common
    kolabd_pidfile="/kolab/var/kolab/kolab.pid"
    kolabd_signal () {
        [ -f $kolabd_pidfile ] && kill -$1 `cat $kolabd_pidfile`
    }

%status -u root -o
    kolabd_usable="unknown"
    kolabd_active="no"
    rcService kolabd enable yes && \
        kolabd_signal 0 && kolabd_active="yes"
    echo "kolabd_enable=\"$kolabd_enable\""
    echo "kolabd_usable=\"$kolabd_usable\""
    echo "kolabd_active=\"$kolabd_active\""

%start -p 600 -u root
    rcService kolabd enable yes || exit 0
    rcService kolabd active yes && exit 0
    /kolab/sbin/kolabd &
    sleep 5

%stop -p 600 -u root
    rcService kolabd enable yes || exit 0
    rcService kolabd active no  && exit 0
    kolabd_signal TERM
    sleep 5

%restart -u root
    rcService kolabd enable yes || exit 0
    rcService kolabd active no  && exit 0
    rc kolabd stop start

%reload -u root
    rcService kolabd enable yes || exit 0
    rcService kolabd active no  && exit 0
    kolabd_signal HUP
    sleep 5

Sometime services are started as user root e.g. apache and then later they run 
with the unpriviledged kolab-n user.

mail:/kolab/etc/rc.d # grep kolab-n ../apache/*
../apache/apache.base:User	kolab-n
../apache/apache.base:Group	kolab-n
../apache/apache.conf:User	kolab-n
../apache/apache.conf:Group	kolab-n

Regards,
-- martin

-- 
"I am committed to helping Ohio deliver its electoral votes to the
President next year."  -- 2004, Wally O'Dell - CEO of Diebold, Inc. 
e r f r a k o n - Stuttgart, Germany
Erlewein, Frank, Konold & Partner - Beratende Ingenieure und Physiker




More information about the users mailing list