/ gnu-linux

Installing funambol and synchronizing

This is a quick and dirty guide how to install and configure your own funambol server (The example is on Debian linux, but procedure is similar for other linux distros. It is also possible to install funambol on windows, if you don't have a linux server to install it on). Installing funambol is not trivial, but the rewards are great.

The guide will also show you how to set up user accounts, and use them to synchronize contacts and calendars on your N80 and with outlook. The procedure is the same on all symbian 3rd edition phones. Any syncml compatible device should be able to do the same, but the procedure might differ. You can also sync other applications and devices (like PDAs).

Article continues after ad

Downloading and installing

The first step is to download funambol. We will be using funambol v3 for this example as it is stable.

wget http://download.forge.objectweb.org/sync4j/funambol-3.0a.bin

Run the installer.

sh funambol-3.0a.bin

When prompted choose to install in the /opt directory.

Getting it running

First edit the following file:

/opt/Funambol/ds-server/config/Funambol.xml

Find this code:

and replace it with this:

http://your.server.com:8080/funambol/ds

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 -e case "$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:

/etc/init.d/funambol start

Article continues after ad

Configure

Now we'll start configuring the funambol server. Download the funambol admin application. We chose the windows version.

Install the application and start it. Log on to the server you configured, using username/password admin/sa. Make sure to change the password for the admin account,then log on again with the new password. To do this, double-click on Users, hit Search, select the admin account and hit Edit

Now double-click on Server settings. Change the Officer: option to:

com/funambol/server/security/DBOfficer.xml

If you don't do this funambol will auto generate users, devices and principals. We of course want to add these manually.

Now we add a user for ourselves. Double-click Users: and hit Add:. Make sure you remember the username and password you enter (duh!) and give use Roles: User:.

Setting up your phone

This is generally for Symbian 3rd edition phones, and N80ie specifically. Other phones would have similar ways of doing it.

On your phone go to Connect., Sync. And select Options,New sync profile. When the phone asks you if you want to copy the existing profile, answer No.

Give the profile any name you like:

Hit Back. Now select Calendar, change Include in sync to Yes and enter cal in Remote database. Hit Back twice.

Now enter Connection settings. Enter your Host address and Port. Remember the serverURI we entered while getting funambol running? This is what we are talking about. So in our example we would enter Host address:

http://your.server.com/funambol/ds

and Port:

8080

Next enter User name and Password. Use the same username and password that you added to funambol earlier.

I also choose to change Accept all sync reqs. to Yes for my own convenience, but this is optional. You can also change the access point to a specific access point if you only want to use one. Leave all other settings alone though. Hit Back twice.

Now choose Options, Synchronize on the sync profile you just created. You will get an error stating that you have entered an invalid username and password.

Now go back to the funambol admin tool. Double-click on Devices and hit Search. You should now be able to see a device called IMEI: in the list.

Double-click on Principals and hit Add. Under the user column hit Search and click on the username that you specified earlier. Under the device column hit Search and select the IMEI item you found in the last step. Hit Add Principal

Back on your phone choose Options, Synchronize on the sync profile you created earlier. This time the phone should synchronize properly.

Article continues after ad

Setting up outlook

Install the funambol outlook plug-in. We chose version 6 beta as it adds Outlook 2007 support.

Start outlook. On the menu choose Funambol, Options…. Under Account, Location enter the url of your server. (In our example http://your.server.com:8080/funambol/ds) Enter the same username and password that we created earlier and used on our phone.

Under Sync, Items make sure that Contacts and Calendar are checked.

First hit Details next to Contacts and change Remote name to card and Data format to vCard.

Next hit Details next to Calendar and change Remote name to cal and Data format to iCal.

If you like you can also tell outlook to automatically sync. You may also check Notes and Tasks to be synchronized (nice if you have more than one computer running outlook), but these will not synchronize on your phone. Finally Hit OK.

Now click on the Sync All button. You will receive an error message stating that you have entered an invalid username or password.

Go back to the funambol admin tool. Follow the same procedure we used to add a principal between your IMEI and your user account. But this time you should find a device that starts with fol or similar.

Go back in outlook and hit Funambol, Sync All. This time the plug-in should synchronize properly, and all of the contacts and calendar items that were on your phone should be available in outlook.

Congratulations! You server is now online and you should be able to sync your outlook and your phone whenever you like. You should also be able to add additional devices by following the procedures we used above. You can also add additional users if you like so that everybody you know (or who works for you) can synchronize their devices.