[sync] Sync failed => Duplicated entries

Karsten Fourmont fourmont at gmx.de
Tue May 3 23:11:08 PDT 2005


Hans Henrik Gabelgaard wrote:

> Hi Karsten
> 
> Thanks! All-day events seems to be working, but now i've got a new problem: New appointments created today are been duplicated, probaly because something goes wrong in the sync proces and the P900 reports sync failure, but everything is synced, and at the next sync, todays entry are duplicated (and the P900 reports sync failure)

> In horde.log i've seen a lot of these messages:
> SyncML: add: 20050503222014.6owney44rshs at webmin.gabelgaard.org ignored, came from client [on line 196 of "/usr/share/php/Horde/SyncML/Backend.php"] 

they are perfectly okay: this occurs when a entry in the server has been 
added/replaced due to a request from the client. When the server then 
gets its change history from horde, this entry is returned as a change 
as well of course: Horde History does not know if a change is manually 
made on the horde gui or created by SyncML due to a client request. So 
in this case it should not be sent back to the client as that's where it 
came from.


> 
> And that ID match a duplicated entry
> 

> Later in the logs a lot of:
> SyncML: Unable to create change for CD0000008B9511D182D800C04FB1625D9D25EB1DA801B94BB43540A37EB0B7B2: client-id not found in map. Trying add instead. [on line 103 of "/usr/share/php/Horde/SyncML/Backend.php"]
That's where the problem occurs: the client sends a replace request. 
Horde SyncML is unable to map the client id to a horde server id and so 
it assumes it's a new event and adds it instead.

This may happen if you modify entries that you sync prior to the april 
24th upgrade: the map format has changed somewhat so it may no longer 
find the old map entries. But it should not happen for entries you 
created today.

> 
> But that ID came from an in Kronolith imported iCal file... Which on the first sync was sent to the P900 and on the next duplicatede back to Horde/Kronolith

I tried both

1) create new entry in horde
2) sync
3) modify in client
4) sync
works fine, no dupes
and

1) create new entry in client
2) sync
3) modify in server
4) sync
works fine for me, too.


> So somehow it's out-of-sync...
> 
> Conclusion:
> On calender sync, P900 reports failure everytime

ah, so you have an incomplete sync.

what exactly does the p900 report?

That may be the reason: there's no such thing as a "rollback" for 
incomplete sync sessions. So if you have a sync that does _not_ end with 
a line "SyncML: Summary:" in the logs, it is incomplete and will be 
retried on the next run. All entries already created during the partial 
sync will be probably duplicated.

So what does the log say? PHP error logs?


> On Contacts sync, P900 reports succes, but nothing is synced, horde logs says:
>  SyncML: Error in adding client entry due to replace request:Invalid address book [on line 114 of "/usr/share/php/Horde/SyncML/Sync.php"]
>  SyncML: api export call for 20050503180445.4pub50xbgow0 at webmin.gabelgaard.org failed:  Invalid address book [on line 187 of "/usr/share/php/Horde/SyncML/Sync.php"]

see my other mail on this one.

Cheers,
  Karsten



More information about the sync mailing list