Getting it running
First edit the following file:
# emacs /opt/Funambol/ds-server/config/Funambol.xml
Find this code:
<void property="serverURI">
<string></string>
</void>
and replace it with this:
<void property="serverURI">
<string>http://your.server.com:8080/funambol/ds</string>
</void>
Next we create a group and a user for funambol to run with, and set a password:
groupadd funambol
useradd -c "Funambol sync user" -g funambol -m funambol
# passwd funambol
Now change the owner and group permissions of the funambol folder:
# chown -R funambol:funambol /opt/Funambol
Now we want to have funambol automatically start when we boot the server. Create a startup file using your editor of choice:
# emacs /etc/init.d/funambol
Enter the following script and save (This is quick and dirty work, if you have made a better version please feel free to let me know and I will post it.)
#! /bin/sh
set -ecase "$1" in
start)
echo -n "Starting funambol server"
start-stop-daemon --start --quiet --chuid funambol:funambol --exec /opt/Funambol/tools/bin/funambol.sh start >> /var/log/syslog&
echo "."
;;stop)
echo -n "Stopping funambol server"
kill -9 `ps -ef|grep funambol|grep -v grep|awk '{print $2}'` >> /var/log/syslog&
echo "."
;;reload|force-reload)
echo -n "Reloading funambol server"
kill -9 `ps -ef|grep funambol|grep -v grep|awk '{print $2}'` >> /var/log/syslog&
start-stop-daemon --start --quiet --chuid funambol:funambol --exec /opt/Funambol/tools/bin/funambol.sh start >> /var/log/syslog&
echo "."
;;restart)
echo -n "Reloading funambol server"
kill -9 `ps -ef|grep funambol|grep -v grep|awk '{print $2}'` >> /var/log/syslog&
start-stop-daemon --start --quiet --chuid funambol:funambol --exec /opt/Funambol/tools/bin/funambol.sh start >> /var/log/syslog&
echo "."
;;*)
echo "Usage: /etc/init.d/ssh {start|stop|reload|force-reload|restart}"
exit 1
esac
exit 0
Now to get it to start at boot time, run the following command:
# update-rc.d funambol defaults
Now start the server:
Send me feedback on this article# /etc/init.d/funambol start
