owncloud refers to the URL to the root of your onCloud installation e.g. http://example.com/owncloud, user is your login and password is your password.
My default calendar is called calendar and my address book is called default.
First create a main configuration for ownCloud:
syncevolution --configure \ --template webdav \ username=Then configure remote URLs and link them to theuser\ password=password\ target-config@owncloud
owncloud config we just created.
First the calendar:
syncevolution --configure \ database=And the address book:owncloud/remote.php/caldav/calendars/user/calendar/ \ backend=caldav \ target-config@owncloud calendar
syncevolution --configure \ database=I think the next command creates the entry which will be available in the UI pointing to theowncloud/remote.php/carddav/addressbooks/user/default/ \ backend=carddav \ target-config@owncloud contacts
owncloud config we created with the first command, and yes, username and password are supposed to be empty:
syncevolution --configure \ --template SyncEvolution_Client \ sync=none \ syncURL=local://@owncloud \ username= \ password= \ owncloudNow create the configuration for the local storage. The calendar:
syncevolution --configure \ sync=two-way \ backend=calendar \ database=N900 \ owncloud calendarThe N900 database is the standard storage. You can see the available ones by running
syncevolution from the command line, and you can create new local calendars from the Calendar app and link them to e.g. your Work and Private calendars, just remember that the case matters, so the names must be entered exactly as they are printed by syncevolution.
And the address book:
syncevolution --configure \ sync=two-way \ backend=contacts \ database=file:///home/user/.osso-abook/db \ owncloud contactsNow everything should be OK, but let us make some quick tests.
syncevolution --print-items target-config@owncloud calendarThis should print the URI part and and the summary of all events.
syncevolution --print-items target-config@owncloud contactsThis should just show the URI part of all contacts. If everything worked out OK it's time to do the actual syncing. If you already have events and/or contacts on your device you want to keep you should do an initial slow sync:
syncevolution --sync slow owncloudSome times you need to do it several times for it to succeed, but once you don't get any more error you can run a normal incrementel sync just by running
syncevolution owncloudI chose to update everything from the server and ran
syncevolution --sync refresh-from-server owncloud calendar syncevolution --sync refresh-from-server owncloud contactsNote: Read this comment first!
Now you can also sync using the syncevolution-frontend app. Just click on the icon
and you will see owncloud listed, and when you click on it you will get to the sync options:
If you have any problems when configuring, please read the original post and any comments there first.





Unfortunately it does not work for me. When I try to create the main configuration, I get the Error "no configuration for `webdav`available.
Wolfgang
After I reinstalled syncevolution everything works now with calendar and contacts.
Thanx very much.
Wolfgang
This now rocks with OwnCloud 4.0.5 thanx a lot for work out the config.
Dreams come true with OwnCloud on Debian!
When I do the testing command: syncevolution --print-items target-config@owncloud calendar
I get the following error:
[ERROR] REPORT 'meta data': Neon error code 1, no HTTP status: Server certificate verification failed: issuer is not trusted
I am using owncube, which uses https, that might be the reason. Do you know of a workaround for this?
Yep, I should have added that. In the first syncevolution --configure command add:
SSLVerifyServer=0
I did all the steps again with that line too and I get this error now:
[ERROR] REPORT 'meta data': bad HTTP status:
Maybe I should have clear the previous configuration? How do I do that?
sorry, full error is:
[ERROR] REPORT 'meta data': bad HTTP status: status 1.1, code 404, class 4, Not Found
From the previous post I referred to in this post
"if you mess something up, just run rm -rf ~/.config/syncevolution/"
It looks like you entered the wrong path.
I get an error at "syncevolution --sync slow owncloud" and dont know how to proceed. I get the error even when i run the command 5 times or more. Maybe someone knows:
First ERROR encountered: transport problem: REPORT 'meta data': status: redirected to http://myserver/owncloud/index.php
My owncloud version is trunk.
That is the error message from syncevolution, right? Try to check what your web server access and error log says when you try to sync.
Also, did the "syncevolution --print-items ..." commands succeed?
Well it gives the error after the print-items command already. No errors in the webserver log.
Here is the complete log of what i did:
http://pastebin.com/nYnCbBHG
I notice you configure it with calendar URL database=http://myserver/owncloud/remote.php/caldav/calendars/user/calendar/
Is that in fact the correct URL? As I mentioned I've changed mine from "default calendar" to just "calendar" to avoid problems with spaces.
You should go to http://myserver/owncloud/remote.php/caldav/ with your browser to get the correct URL.
When going to http://myserver/owncloud/remote.php/caldav/ i always get redirected to http://myserver/owncloud/index.php
I will test tommorow.
I tried it, but no success till now. I always get the redirected message.
When i use the gui of syncevolution i get some output with the --print commands for the calender (not for the contacts)
I also get that redirect error. I tried the URL to which I get redirected, doesn't work. It seems like the server wants to redirect, but syncevolution doesn't support this feature?
Any solution?
@moony: If you go to http://myserver/owncloud/remote.php/caldav/ with your browser,you should get an authentication dialog. If you don't get that something is wrong with your installation and you should check owncloud.log and your web servers error log.
@tanghus: I tried https://SERVER/owncloud/remote.php/caldav/ in my browser, it says "cloud not found". Then I tried: https://SERVER/index.php/caldav/calendars/USER/caldav/ that works.
but with changed url in owncloud config, I get another error:
# syncevolution --print-items target-config@owncloud calendar
[ERROR] transport problem: REPORT 'meta data': 302 status: redirected to https://SERVER/index.php/caldav/calendars/USER/calendar/
[ERROR] calendar: reading items
I don't get another url for redirect anymore, I get exactly the same url...
@moony: The base URL for your two links differ. One starts at https://server/owncloud/ the other at https://server/. Where is your ownCloud instance located?
Just wrote it wrong here, got the same url for redirect, but found out it was the wrong url for me. It's https://SERVER/remote.php/caldav/calendars/USER/defaultcalendar yeah
In the parent directory the file defaultcalendar was listet. Maybe they changed the whole structure in newer versions of owncloud..
@moony: Ah, forgot about the calendar name. But to be fair to myself
I noted both in this article and it's predecessor that the name "calendar" was one I had given it - not the default name.
Anyways I'm glad you got it working.
contacts: https://SERVER/remote.php/contacts/addressbooks/USER/contacts
and files: https://SERVER/remote.php/files
that redirect error means just, you got the wrong link.
thanks for your help
I've setup syncing on my N9 as described here and have it working for the calendar. However, when I try to sync the contacts I get dbus timeout errors. It managed to sync the first several contacts, but then gave up. I'm assuming it is because I have too many contacts (~400) and the sync is taking too long. Is there any way to change the timeout value to fix this?
No idea, sorry. Better ask on a syncevolution mailing list or in an Maego/Meego forum.
Did you use the configuration as described above? I had to change it slightly (omitting the local database definitions) for the N9(50). I also had to dig around to find a syncevolution compiled with DAV support.
Yes, I followed the setup, but changed the databases slightly (found the names using syncevolution --print-databases); and it does sync the first ~100 contacts, but then stops with the timeout. I use the binaries from http://people.debian.org/~ovek/harmattan/ which have dav support (and can be setup as an apt source, so easy install
).
I suppose I'll try the mailing list. Thanks
I just noticed 10 minutes ago that Ove had released a version compiled with DAV support. I wrote to him some weeks ago to ask if it was possible, but he kinda brushed me off saying it was "not just flipping a switch". When I then found a thread about a guy who had made it work, I of course mailed him the link - apparently it was not as hard
I hope you find an answer to your problems.
Yes, I did read those posts, and was wondering what all the fuss was about. Dav support seemed to just work.
Anyway, posting to the mailing list revealed that the timeout turned out to occur because syncevolution did not set a timeout value properly, so it should be fixed for the next version. Yay!
Once again thanks for the guide, and subsequent help!
Hey! It took me two weeks of my summer holiday to add DAV support and debug the problems. Unlike that other guy, I took the time to do it properly, making sure everything works (including some autoconfiguration stuff that wouldn't have worked with that guy's package), and with a full source package that can even be autobuilt without needing to manually compile dependencies, thus of a quality that it could be hosted on official software repositories. I'd appreciate not having to hear "apparently it was not as hard"...
He, I had a feeling that would come back to bite me
Well, I maybe sensitive when it comes to communication, but consider the following scenario:
- You write a (maybe overly) polite mail asking if it would be possible to make a certain feature available in a software package.
- You receive a reply that could be from lkml when Linus is having PMS.
- You send a reply apologizing for your n00bness to which you receive no reply.
At that point I still have deep respect for the hard work and the good result, but I'm not that concerned if your feelings are a bit hurt.
Ovek, please contact me if you want me to remove these two comments. I will of course also moderate my previous comment that ticked you off if you would want that.
- I've had other people demanding this stuff based on even worse misinformation, as if I, with 20 years of international software engineering experience (including being a Debian Developer), was somehow too stupid to realize that I needed to enable a simple configure option (though it had been enabled in my Fremantle build for years), and that in the year I've build Harmattan packages, somehow nobody else had told me about this magical configure option I clearly missed for some reason.
Although I was low on patience at this point, I still replied to you and explained the situation and the misunderstandings fairly calmly and comprehensively, because you seemed to deserve that much. I can't help it if you didn't understand it that way.
In reality, without a proper build-dependency chain, I couldn't do much about this before I could get enough free time. And as a Debian Developer, I don't churn out half-baked .debs, I do things properly. Anyone should be able to take my source packages and build the same binaries, and be sure of what they were built from. That's what Open Source (and the Debian Free Software Guidelines) is all about.
- You weren't asking for any further replies. You had no other questions, it all sounded as "ok, thanks, later" to me.
And no, I see no need to remove any comments. I'm not all that upset, it just feels good to set the record straight, blow off some steam, and maybe keep people on their toes a bit.
Hello,
first I want to say THX for your work!
But for me it's not possible to sync my contacts using syncevolution.
I tried your config posted in jan/2012 and this one and everytime I get this error:
[INFO] addressbook: looking for databases...
Segmentation fault
Here's my config:
- Owncloud 4.0.7 running on Windows Apache webserver
- Nokia N900 PR1.3 (u2d)
Any suggestions?
Thx in advance.
-Tarnatos
HA!!!
After 3 days of trying and a full vanilla reflash of my N900 I HAVE IT!
The fault was that I did the configuration as "SU"!
So if you get the "segmentation fault" error at the contacts part stop and turn off X-term. Delete the /home/user/.cache/syncevolution AND the /home/user/.config/syncevolution folder! Open X-term again an do the config above as NORMAL user. Than everything works fine!
I've made the same mistake myself more than once
Doesn't look like SyncEvolution will be supporting Tasks sync on N900 in the near future:
See https://bugs.freedesktop.org/show_bug.cgi?id=52666
Too bad. I wonder if Ove did implement it for the N9 - I didn't even think of testing if it supported it.
Thanks for the link
I also have a segmentation fault when i do the slow sync. Every time i run the slow sync it proceeds further. You stated that …
> Some times you need to do it several times for it to succeed
Did you had the same issues?
No, I never experienced that.
You should probably file a bug report at https://bugs.freedesktop.org/enter_bug.cgi?product=SyncEvolution
Thank you very much for this Howto.
It works great.
But after I synced my contacts and the first calendar, I tried to sync also the other ones.
To sync another calendar it is neccessary to change the following part of code:
...database=N900... -> ...database=PRIVATE... or what ever the database name would be (to see the database names type "syncevolution --print-databases")
and the according owncloud database name and the path here:
database=owncloud/remote.php/caldav/calendars/user/PRIVATE/
Now I tried to create several configurations for each calendar. But this will not work, because the entry for the database is at the
.config/syncevolution/default/sources/calendar/config.ini
and this file is active for all configurations.
Is there any possibility to overwrite this entry for each configuration?
I tried to move this entry, but I dont understand the way syncevolution works and I couldnt find some documentation for caldav and syncevolution, where I can see which config file will be for what.
So until now I am not able to get this work with several configurations.
Do you have any ideas?
Thank you,
Lamu
Hi Lamu
You should be able to setup syncevolution with multiple calendars running a setup like this multi-calendar example.
You will of course need to modify it to your own needs and the run
rm -rf ~/.config/syncevolution/*to remove the old configuration first. I quickly found out that was the easiest thing to do instead of messing with the config files manually.Oh WOW!
I can´t believe it really works!
Thank you so much!!!
After three days trying around you fixed my problem.
Thank you,
Lamu
Good to hear
I had to adjust URLs for use with owncloud4.5:
syncevolution --configure \
database=http://owncloud.orlives.de/remote.php/caldav/calendars/spiollinux/defaultcalendar/ \
backend=caldav \
target-config@owncloud calendar
syncevolution --configure \
database=http://owncloud.orlives.de/remote.php/carddav/ \
backend=carddav \
target-config@owncloud contacts
(I took the URLs from the web interface)
Calendar works fine, but Contacts causes: First ERROR encountered: error code from SyncEvolution access denied (remote, status 403): PUT: bad HTTP status:
The URLs used in the post is meant as examples, as you can delete and create addressbooks and calendars.
For Contacts I can see you use the base URL which is probably why you get the error message.
You should use the full URL which would be something like:
http://owncloud.orlives.de/remote.php/carddav/addressbooks/spiollinux/contacts/
"contacts" is the new default name instead of "default" - I thought it would be more intuitive
The URL should also be available in the web UI under "More..."/Address books/CardDAV URL.
Hey there! Great Tutorial! Thanks for taking the time to research it.
syncevolution v1.3.1 is officially in the repos, you stated earlier it might add functionality for vtodo and vjournal.
As you've obviously put a lot more time into this than I did so far, are you by any chance in the mood to update this great HowTo yet again to include ToDo and Notes?
I've just set up my server a few days ago, It would probably take me weeks to figure out what I was actually doing if anything went wrong...
Another thing: you use "owncloud" as context name in your examples. is that just an arbitrary string which for convenience you chose to be identical to the server's name, or does it actually trigger additional settings because it is recognized by syncevolution? In short: can I change it to say "target-config@MySuperFancySyncServer" or will that cause trouble? I know the "target-config" part is mandatory for local sync configs...
Greetings,
Jost
I will put it on my ToDo list (no pun intended), but being quite busy atm I don't know when I can test it.
The 'owncloud' in 'target-config@owncloud' is as you suggest just an arbitrary string used to identify the configuration. I just thought it would be a memorizable name
(my spell checker says I've just invented a new word?)
Thanks, that would be great. Although I just saw a bug report through google stating that support for it is implemented in the Harmatten release (N9) only, not in the fremantle (N900) release, since no one bothered to do the extra work for such an old device, so this might be a show stopper.
Speaking of show stoppers: I just repeatedly ran into a problem. Syncing the first few dozen events/contacts works fine, but when syncing a lot of data (6 calendars + address book) after a while syncevolution exits prematurely with the ever so popular segmentation fault. I have a feeling it's got to do with character encoding (some german Umlauts don't display correctly after sync, others do).
The point it crashes differs from attempt to attempt (with identical data), but I haven't had a single complete sync run through cleanly, yet! How is your experience with stability?
I've heard it from others, but never experienced it myself. I haven't had problems with special chars either.
Mostly I sync the different configs separately as in
You could try that to at least figure out which config it fails with.
I just installed a fresh copy of OwnCloud and had to use these URIs:
Calendar:
database=owncloud/remote.php/caldav/calendars/user/defaultcalendar/
Contacts:
database=owncloud/remote.php/carddav/addressbooks/user/contacts
HTH, HAND
@Rand0m: You can add/delete calendars and addressbooks. The examples I mentioned above are just examples.
I am using the git repo of owncloud and ran into problems with carddav sync and the latest supplied SabreDAV implementation. SabreDAV rejected all put commands with error 400 and the message: 'Every vcard must have an UID'.
So i had to disable the following lines in /var/www/owncloud/3rdparty/Sabre/CardDAV/Plugin.php:
if (!isset($vobj->UID)) {
throw new Sabre_DAV_Exception_BadRequest('Every vcard must have an UID.');
}
Now everything seems to work fine with my N900 and with evolution on my desktop.
Greetings,
Leo
Hi leo. You should file a bug report at https://github.com/owncloud/apps/issues and give it the labels "app:contacts" and "Bug".
Which client do you use which saves vCards without UIDs?
I believe the latest Sabre\VObject does some basic validation. It is my plan to create a plugin that intercepts invalid vCards and try to repair them before they are being saved, but I haven't gotten around to it yet.
Ah, just now read that it was you N900, sorry.
I'm getting a strange error using owncloud 4.0.9:
First ERROR encountered: unsupported media type or format (local, status 10415)
See whole process here:
http://pastie.org/5552144
Any ideas what to check/change,..?
I can't really tell. Have you tried looking at /home/user/.cache/syncevolution/target_+config@owncloud-2012-12-19-11-30-a/syncevolution-log.html as the log suggests?
hmm. I've read the last part of it. It ha 1000 lines. I see nothing important really.
I've uploaded it here: http://pastebin.com/6eQn3Wwd
Any ideas?
I don't know much (anything) about the inner workings of syncevolution. I suggest you consult their support page https://syncevolution.org/support
"I chose to update everything from the server and ran
syncevolution --sync refresh-from-server owncloud calendar
syncevolution --sync refresh-from-server owncloud contacts"
Be careful about how the word server is defined. syncevolution --help prints:
" **Warning:** in local sync (`CalDAV and CardDAV`_/ActiveSync, ...) and
direct sync with a phone, the sync is started by the side which acts
as server. Therefore the ``from-server`` variants
(``one-way-from-server``, ``refresh-from-server``) transfer data
from the sync config into the target config (see "Synchronization
beyond SyncML" below) resp. to a phone. The ``from-client`` variants
transfer in the other direction, even if the target config happens
to access data on a remote server."
DerYo-->
Yeah, I think it's rather confusing and unintuitive. Now that you mention it I think I managed to wipe the data in my ownCloud instance once in the process
Always have backups!
Thanks for this tutorial - it sure saved me a lot of time!
I got it up and running using SyncEvolution 1.3 / ownCloud 4.5.6 on my N900 with community SSU.
I just see one issue here: 'all-day-events' are not synchronised properly (after the first slow sync from the N900 to ownCloud).
In ownCloud they show up from 0:00 start date date until 0:00 end date - instead of being 'all-day-events'. It doesn't matter if they span one ore more days.
Has anybody of you seen this as well?
Creating an 'all-day-event' in ownCloud and synchronising it to the phone works correctly though.
Greetings,
Tempura
I experienced the same issue: All-day events show up as events going from 0:00 that day to 0:00 the next day. That is kind of "all day" though
BTW: Where did you get SyncEvolution 1.3 for N900? Mine prints (syncevolution --version) 1.2.2+20120123+...
I got the version from http://people.debian.org/~ovek/maemo/ - there is also a README on how to add the repository to apt (thanks ovek!).
After digging around the problem seems to be on how DTSTART and DTEND are defined.
ownCloud expects the format:
DTEND;VALUE=DATE:20130102
DTSTART;VALUE=DATE:20130101
while the N900 (SyncEvolution) seems (not 100% sure) to send:
DTSTART:20130101T000000
DTEND:20130102T000000
So the DATE tag is not detected. This is checked for in ownCloud owncloud/apps/calendar/lib/app.php, line 318:
$allday = ($vevent->DTSTART->getDateType() == Sabre_VObject_Element_DateTime::DATE)?true:false;
It seems that there is more than one way to indicate that an event is an 'all-day-event' and SyncEvolution's way is also valid - but it will fail with ownCloud.
Maybe there is some way to fix this using the scripting facility of SyncEvolution?
I have written a short test program to verify what SyncEvolution gets from the maemo-backend.
Unfortunately it seems, that the Maemo calendar-backend is bugged. It does not matter if one requests ICAL or VCAL data, the date field is always like in VCAL - without the 'VALUE=DATE...' entry. Also in both cases the version is reported as '1.0' - although it should be '2.0' for ICAL...
So for the time being there is no way to correctly synchronise 'all-day-events' with ownCloud - please correct me if I am wrong.
Greetings,
Tempura
The problem is fixed - at least for me.
See https://bugs.maemo.org/show_bug.cgi?id=12682 for the bug filed against calendar-backend and the details.
A working patch is also attached there if you want to test for yourself.
Greetings,
Tempura
thanks a lot for the awesome guide!
on my n900 however i had issues finding the local addressbook. setting the backend to "addressbook" and removing the local uri to the addressbook solved the problem. i.e. something like this should work (i did it manually in /home/user/.config/syncevolution/default/sources/contacts/config.ini)
syncevolution --configure \
sync=two-way \
backend=addressbook \
owncloud contacts
@daniel: thanks for the input. I am not running syncevolution on the N900 currently, but it may come apply for others.