Synchronizing Directly to Evolution via HTTP#
SyncEvolution makes it easy to keep two instances of Evolution in sync, or to keep a phone in sync with Evolution. This lets you share the data between a desktop and a laptop or phone without requiring any internet intermediary. Setting up SyncEvolution as such an intermediary on an Internet server is explained in another HOWTO.
Requirements#
Two instances of Evolution (or one instance and a phone with a SyncML client installed) on machines which can reach one another over the network. One host will act as the server (call this box “sauce”) and the other will be the client (call this box “cheese”). The names, of course, do not matter.
syncevo-http-server >= 1.2 installed on the server, with the Evolution Data Server backends (libebook, libecal) enabled
The Synthesis SyncML clients for iOS and Android are known to work.
Steps for two computers#
Warning
The configuration below uses empty username and password values. This disables access control, so anyone with access to the network on which the syncevo-http-server runs will have read/write access to the PIM data. To avoid that, choose an arbitrary combination of username and password and set those in the client and server configurations.
Start syncevo-http-server on the server:
syncevo-http-server http://localhost:9000/syncevolution
Warning
This listens on all interfaces, NOT localhost as it appears.
Configure a peer on the client to point to the server (you’ll need to fill in the right IP or hostname):
syncevolution --configure --template SyncEvolution \ syncURL=http://sauce:9000/syncevolution sauce
Run the sync on the client. This will fail, but will output the client device ID, which we need:
syncevolution sauce
On the server side, you should see something like:
[ERROR] sync: no configuration found for deviceID (some long string of chars)
Save that string, you need it for the next step.
On the server, configure a peer for the client:
syncevolution --configure --template SyncEvolution_Client \ --sync-property remoteDeviceId=<paste in the string> \ --sync-property username= \ --sync-property password= \ --source-property uri= \ cheese
On the client, kick off the sync process:
syncevolution sauce
Steps for a computer and a phone#
Start syncevo-http-server on the server:
syncevo-http-server http://localhost:9000/syncevolution
Warning
This listens on all interfaces, NOT localhost as it appears.
Configure the phone to point to the server (you’ll need to fill in the right IP or hostname). For example on the Synthesis server settings page, set the Server URL to:
http://sauce:9000/syncevolution
Run the sync on the client. This will fail, but will output the client device ID, which we need. On the server side, you should see something like:
[ERROR] sync: no configuration found for deviceID (some long string of chars)
Save that string, you need it for the next step.
On the server, configure a peer for the client:
syncevolution --configure --template SyncEvolution_Client \ --sync-property remoteDeviceId=<paste in the string> \ --sync-property username= \ --sync-property password= \ --source-property addressbook/uri=contacts \ --source-property calendar/uri=events \ --source-property todo/uri=tasks \ --source-property memo/uri=notes \ cheese-mobile
On the client, configure the server path for each item you would like to synchronize. The paths used by evolution are addressbook”, “calendar”, “todo”, “memo”. This step is optional for the Synthesis SyncML clients because the paths used by those clients were set as aliases above.
On the client, kick off the sync process. This will give you a setup that syncs the addressbook, calendar, memo, and todo sources. calendar+todo defaults to disabled; leave it, you don’t need it for this kind of setup.
Synchronizing additional databases#
The instructions above set up the usual set of databases: default address book, calendar, task list and memo list. SyncEvolution can synchronize additional databases. Here’s an example for adding a second “work” calendar to sync between the “sauce” and “cheese” computers.
On the server, list databases.
syncevolution --print-databases ... Evolution Calendar = evolution-calendar: Personal (local:system) <default> Work (local:1237386992.13712.0@sauce) ...
When printing all databases, syncevolution will list all available backends with all contained databases; the backend can easily be determined as the value after the “=” sign, in the previous example this would be “evolution-calendar”.
Database names are at the beginning of each subsequent line. The values in brackets are only identifiers, not database names. In the example above, the available databases are “Personal” and “Work”.
On the server, configure the additional calendar (only needs to be done once):
syncevolution --configure \ backend=evolution-calendar \ database=Work \ @default work-calendar
On the server, enable access to the work-calendar for the client (repeat for each client):
syncevolution --configure \ sync=two-way \ cheese work-calendar
On the client, list databases on client using the same commands as on the server.
On the client, configure and enable work-calendar:
syncevolution --configure \ backend=evolution-calendar \ database=Work \ sync=two-way \ sauce work-calendar
When using other SyncML clients, then configure them to use “calendar” as URI for the default calendar and “work-calendar” for the second calendar.