Skip to content
IT // Adventures

Installing Murmur on CentOS

Quick guide: installing the Mumble server 'Murmur' on CentOS 6.

1 min read

Recently I had the chance to set up a Mumble server (aka “Murmur”) on CentOS 6. I use MySQL as the database and “MyMumb Panel” as the management interface (see GitHub: MyMumb-Panel).

The installation itself was very easy, but things started to get stuck when setting up the init.d script, so my documentation is (still) a bit thin. More to follow.

Preparation

When starting the service, Murmur uses the “lsb” command, which isn’t available on CentOS by default. To avoid an annoying error message and a process marked as “defunct”, we install the “redhat-lsb-core” package:

yum install redhat-lsb-core

Installation & Configuration

Since I didn’t feel like compiling Murmur myself for now, I fell back on the “stable” binaries (see SourceForge: Mumble).

  • Unpack & create directories
  • Create a MySQL database (or use the bundled .sqlite database)
  • Open the ports in IPtables with iptables -A INPUT -p udp -dport 64738 -j ACCEPT iptables -A INPUT -p tcp -dport 64738 -j ACCEPT
  • Adjust Murmur.ini, i.e. enter the credentials for the MySQL database, disable dBus, adjust the paths for log and PID files, etc.
  • Create an init.d startup script. (Example below)

BONUS: Setting up the MyMumb management interface with ZeroC Ice

(At this point I had to compile ZeroC Ice, because no suitable binaries were available - instructions to follow…)

Generate the matching PHP file for MyMumb from the Murmur Ice “slice”:

/opt/Ice-3.5.1/bin/slice2php -I/opt/Ice-3.5.1/slice Murmur.ice

…and place it in the MyMumb directory

mv Murmur.php /srv/www/mumble/htdocs/inc/

Example CentOS init.d startup script

#!/bin/bash
#
# /etc/rc.d/init.d/murmurd
#
# Murmur VoIP Server
#
# chkconfig: 345 70 30
# description: Murmur VoIP Server
# processname: murmur.x86
# config: /etc/murmur.ini
# pidfile: /var/run/murmur/murmur.pid
# Source function library.
. /etc/init.d/functions
RETVAL=0
NAME=murmurd
DESC="Murmur VoIP Server"
PIDDIR=/var/run/$NAME
PIDFILE=$PIDDIR/$NAME.pid
INIFILE=/etc/murmur.ini
LOCKFILE=/var/lock/subsys/murmur
DAEMON=/usr/local/murmur/murmur.x86
DAEMON_OPTS="-ini $INIFILE"
USER=murmur
GROUP=murmur

start() {
    echo -n "Starting $NAME: "
    daemon --user $USER $DAEMON $DAEMON_OPTS
    RETVAL=$?
    [ $RETVAL -eq 0 ] && touch $LOCKFILE
    echo
    return $RETVAL
}

stop() {
echo -n "Shutting down $NAME: "
    killproc $DAEMON
    RETVAL=$?
    [ $RETVAL -eq 0 ] && rm -f $LOCKFILE
    echo
    return $RETVAL
}

case "$1" in
    start)
        start
        ;;
    stop)
        stop
        ;;
    status)
        status murmur
        ;;
    restart|reload|condrestart)
        stop
        start
        ;;
    *)
        echo "Usage: $NAME {start|stop|status|reload|restart[|probe]"
        exit 1
        ;;
esac

exit $RETVAL