We have moved to a new Sailfish OS Forum. Please start new discussions there.
2

SyncEvolution fatal error could not save calendar

asked 2014-04-20 11:18:30 +0300

FloR707 gravatar image

Hi there!

I read several HowTo's (for example here) to setup SyncEvolution with OwnCould on my Jolla. All post I read made me think that this should be easy but it is not. I got my contacts synced right a way but my calendar is just not syncing. After I deleted all my repeating events I got a successful sync but a fatal error that the calendar could not be saved. The full error text is:

First ERROR encountered: error code from SyncEvolution fatal error (local, status 10500): @owncloud-/calendar: could not save calendar

Has anyone seen that, too? Is there a way to solve that? According to my internet search I am the only one who got this problem...

I use Sailfish OS 1.0.5.16 and my OwnCloud is running on my own server.

Any help would be appreciated.

edit retag flag offensive close delete

Comments

you try to sync with calendar store default?

domnk ( 2014-04-20 13:38:47 +0300 )edit

and have entered three URL?

domnk ( 2014-04-20 13:39:38 +0300 )edit

Yes, I try to sync with the default calendar. I am not sure what you mean with three URL. I have entered my URLs as explained in the HowTo.

FloR707 ( 2014-04-20 13:47:58 +0300 )edit

i mean url to cloud, url to contacts and url to calendar. you tried to delete and then recreate the account i think.

domnk ( 2014-04-20 17:21:03 +0300 )edit

I am quite sure that the URL to the OwnCloud calendar is correct since the log tells me that the sync was done successfully and in the log SyncEvolution displays I can see all the events that need to be updated. Somehow SyncEvolution has no write permissions for the calendar. Also the error log html SyncEvolution is mentioning does not exist on the device. Do I have to change some folder permissions?

FloR707 ( 2014-04-20 18:24:26 +0300 )edit

2 Answers

Sort by » oldest newest most voted
2

answered 2014-04-20 18:36:01 +0300

stormc gravatar image

updated 2014-04-20 18:40:06 +0300

I also ran into this error while sync'ing a formerly exchange-sync'd calendar with syncevolution. My wild guess is that even after manual cleanup of the calendar there are still some leftover entries in the db that hinder consistent synchronization.

In the following I lay out a very rude way to interact with the calendar db and you may break things easily! You have been warned... :)

What helped me was to manually tinker with the sqlite calendar db which you can access as root via sqlite3 /home/nemo/.local/share/system/privileged/Calendar/mkcal/db.

First, I deleted events not associated to a calendar and events associated to a non-existing calendar via the following sql statements:

delete from alarm where ComponentId in (select ComponentId from components where Notebook not in (select CalendarId from Calendars));

delete from attendee where ComponentId in (select ComponentId from components where Notebook not in (select CalendarId from Calendars));

delete from customproperties where ComponentId in (select ComponentId from components where Notebook not in (select CalendarId from Calendars));

delete from rdates where ComponentId in (select ComponentId from components where Notebook not in (select CalendarId from Calendars));

delete from recursive where ComponentId in (select ComponentId from components where Notebook not in (select CalendarId from Calendars));

delete from components where Notebook not in (select calendarid from calendars);

delete from components where Notebook = '';

Note: you may replace delete with select * to see if there are any entries.

Then, I cleaned the calendar in question via the following sql statements:

delete from alarm where ComponentId in (select ComponentId from components where Notebook in (select CalendarId from Calendars where Name = "$1"));

delete from attendee where ComponentId in (select ComponentId from components where Notebook in (select CalendarId from Calendars where Name = "$1"));

delete from customproperties where ComponentId in (select ComponentId from components where Notebook in (select CalendarId from Calendars where Name = "$1"));

delete from rdates where ComponentId in (select ComponentId from components where Notebook in (select CalendarId from Calendars where Name = "$1"));

delete from recursive where ComponentId in (select ComponentId from components where Notebook in (select CalendarId from Calendars where Name = "$1"));

delete from components where Notebook in (select CalendarId from Calendars where Name = "$1");

where you have to replace $1 with your calendar's name as listed by select Name from calendars;. As above, you may replace delete with select * to see if there are any entries. Note: I assume that your calendars are distinctly named!

Finally, I sync'd with syncevolution first in slow mode and then in two-way mode without further problems.

edit flag offensive delete publish link more

Comments

Sorry that you did not hear from me but I got no notification that another answer was posted. I found this by accident. So what if I just clean my calendar? All entries are on my computer. My plan was to move them to the phone. Regarding the db. I am just looking into SQLite but this is way ahead. And looks like my system is different. The folder privileged is empty.

FloR707 ( 2014-04-23 18:04:07 +0300 )edit

Stupid me, was not root.

FloR707 ( 2014-04-23 18:08:12 +0300 )edit

Sync'ing the calendar data from my PC (owncloud) to the phone was exactly my use case as well. Prior to using syncevolution I tried sync'ing via oczpush which worked OK for my former Android phone but not so well with Jolla. That's where the leftovers came from that prevented syncevolution sync'ing with this obscure error which is at least misleading in this case. After cleaning the calendar(s), it worked as expected.

stormc ( 2014-04-23 18:19:28 +0300 )edit
0

answered 2014-04-23 18:54:29 +0300

FloR707 gravatar image

Okay I think I got it. I played a little with the sync from server/client options and as mentioned in the HowTo it destroyed everything. Luckily I made my backup first and could start from scratch. First I redid my calendar on my Mac and took out all the fancy stuff from the events, like adding people. The fresh calendar was sent to my OwnCloud sever. From there I imported all my events into my empty calendar on my phone. During the first sync I got an error but it synced anyway. I added an event on my Mac, changed to two-way in SyncEvolution and know it synced without an error. Hope it stays that way.

You probably do not have to destroy your calendar first, I guess it could also work if you just create a new calendar and sync with this one.

Thanks for the help!

edit flag offensive delete publish link more
Login/Signup to Answer

Question tools

Follow
4 followers

Stats

Asked: 2014-04-20 11:18:30 +0300

Seen: 539 times

Last updated: Apr 23 '14