Bug 10634 - Sync unreliable after server sleep (standby)
: Sync unreliable after server sleep (standby)
Status: CLOSED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Sync
: 7.0
: All Debian Linux
: P2 normal with 2 votes (vote)
: 7.x
Assigned To: Alan Young
http://forums.slimdevices.com/showthr...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-10 00:08 UTC by Alan Young
Modified: 2009-07-31 10:33 UTC (History)
1 user (show)

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alan Young 2009-01-10 00:08:53 UTC
When a server has been to sleep than, after it wakes up, sync may be unreliable for a period.

The server tracks the difference between each player's internal clock (called jiffies) and real time from the server's viewpoint. For each player this is known as the jiffiesEpoch. Tracking occurs on each status response from the player: every 5s while idle and every 1s while playing. A hysteresis-type algorithm is used to reduce jitter so that apparent clock drift caused by short-term network congestion or unusual latency is not over-compensated for. This algorithm does not allow for the possibility that a player's clock may drift for an extended period without SC being informed, such as may happen when when the SC server goes into suspend or hibernate modes.

If the unobserved drift has been in one direction (either fast or slow) then the correction will be immediate. In the other direction, and error of less that 50s will only be corrected at a rate of 5ms/correction (every 8s while playing or every 50s while idle). Even when playing, this could theoretically take  up to 22 hours to correct, although it is unlikely that the Squeezebox clock drift would have been so large; probably at most a second or two a SB clock drift is typically around 1ms/minute.
Comment 1 Alan Young 2009-01-10 00:36:18 UTC
Change 24612 resets the jiffiesEpoch upon player reconnect, which will happen after the SC comes out of standby.
Comment 2 Andrea 2009-01-10 02:33:48 UTC
Thanks for looking into this. Do you suggest I try some specific new build to check if this is solved? Is this what you meant with the Revision 24612 quote?

Also, I have this bug as well: https://bugs-archive.lyrion.org/show_bug.cgi?id=10325 I don't know if they are related at all. But considering both happen when coming back from standby, I mention it.
Comment 3 Alan Young 2009-01-10 06:41:13 UTC
It should be in tomorrow's nightly build.
Comment 4 Andrea 2009-01-11 08:49:00 UTC
SqueezeCenter-7.3.2-24612.exe this one should include it then?
Comment 5 Alan Young 2009-01-11 09:58:17 UTC
yes
Comment 6 Andrea 2009-01-12 06:23:48 UTC
Thanks a lot for all the help. This morning synch was perfect. All the family appreciated your effort! :)

I'll report in case there any problems, but it looks to be really fixed.

Great work! :D
Comment 7 James Richardson 2009-01-14 16:43:39 UTC
Verified fixed in

SqueezeCenter 7.3.2 r24638
Comment 8 James Richardson 2009-01-22 09:59:05 UTC
Fixed - Closed Message (SC)

This bug has been fixed in the 7.3.3 release version of SqueezeCenter!

Please download the new version from http://www.slimdevices.com/su_downloads.html if you haven't already.  

If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.
Comment 9 James Richardson 2009-01-22 13:54:53 UTC
Correction: SqueezeCenter version is 7.3.2
Comment 10 Chris Owens 2009-07-31 10:33:57 UTC
Reduce number of active targets for SC