Jump to content

Sync Queue Robustness and Timely Completion


ginjaninja

Recommended Posts

ginjaninja

a bit of feedback. on multiple occasions tested emby was not reliable for me at using the capacity of my server / network / phone inc battery to process and complete the syncronisation queue in a timely manner.

 

test

a normal sync queue of tv shows, tv series, music artists, music albums, movies.

emby starts syncing reliably with a reasonable delay - good

emby is potentially managing queue efficiently (at least some of time) by transferring files not requiring transcode whilst transcoding takes place on other queue items - good

emby is syncing to external sd path not constrained to com.mb. android structure on a non rooted nougat device - excellent.

if emby is loaded all the while and used (current app, device not locked/ sleeping) then emby queue continues to be proccessed - good

but emby does not seem to be able to prevent android lock screen? or app switching? from interupting the queue proccessing.

on every occassion when i go to bed the next morning the media is not 100% transferrred. at some point emby queue media transfer to device was interupted.

 

that said emby queue transfer eventually starts again (not in a reasonable , understandable timeframe) the next day at some point and does eventually finish, although the ui suggests that partially transferred files are completely restarted for transfer. for example the queue is not complete..emby is in use..the device is not asleep and yet no syncing is taking place for the last 30 mins. android notification shows a single music file in mid copy with 0 kb/s. and now it has started 45 minutes after waking up.

 

the queue, despite all devices powered and with plenty of computing resources (server on no sleep profile), is never complete the next morning (all transferred)..because the queue halted.

 

does emby need some android rights for the sync task to prevent the queue transfer being interupted. the queue transfer would benefit from being more predictable, consistent, robust than it currently is imo.

do i need to set some paramters on emby to make it never go to sleep during sync.

 

in fairness emby android does eventually get there and i now have 256gb of media for my plane journeys this holiday season. but if i was in a rush and had limited time it would be very frustrating for the files not to transfer in a timely fashion.

 

in summary

as a user i would like to set a sync queue before sleep and have that sync queue finished by when i wake up (power/bandwidth allowing)

 

ty.

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

ginjaninja

twice ive tried to sync artist R.E.M. and twice it has failed to complete transfer to phone...theres about 700 tracks...my microsd card fills up with folders

r.e.m.

r.e.m. (1)

r.e.m. (2)

r.e.m. (3)

etc

to r.e.m. (32)

 

with tracks dotted between these and the transfer % been seen to go backwards i believe..saw it at 30% thiz morning...now at 17%.

 

will logs help or are these known challenges?

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

@@ginjaninja, today I tested several large sync jobs, for example, multi-disc albums. for my method of testing, i put another app in focus on top and then just set the device down. I then initiated the sync jobs from another device using the download to other device feature. In all cases the sync jobs completed within 30 minutes.

 

I would check system settings -> accounts -> sync and make sure the emby account has sync access. Also, do you have a lot of other apps that sync that it might be competing with? thanks.

Link to comment
Share on other sites

I also did another test that I think would be relevant to this topic. I even completely closed down the app, and then put another app in focus, set the device down.

 

Now, without the app even running at all, I created a sync from another device, a full music album. That sync job has just completed and again, the app is still not even running as it's all happening in the background service.

Link to comment
Share on other sites

ginjaninja

I also did another test that I think would be relevant to this topic. I even completely closed down the app, and then put another app in focus, set the device down.

 

Now, without the app even running at all, I created a sync from another device, a full music album. That sync job has just completed and again, the app is still not even running as it's all happening in the background service.

ty for feedback.the sync queues i were creating were 3 hours plus of copying. i think my syncing is reliable over 30mins time frame. i do have other apps syncing..but nothing unusually burdensome...some email mostly...ill try again and see if i can find a a way to replicate the issue...ive since learnt samsung have some power utilisation checking per app and have the concept of forcing badly behaved apps to sleep..maybe this is related.

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

ginjaninja

under power saving samsung has 'unmonitored apps-can use as much power as they like'. email was there..i added emby..will test again..

 

while i remember my queue was also transcoding to medium quality as well as being long/100Gb..

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

ginjaninja

with 2.9.1.1 i still get multiple r.e.m. folders  in my sync folder when syncing artist r.e.m.

log

have not tried a large sync yet with the samsung power saving setting..

Link to comment
Share on other sites

ginjaninja

@@ginjaninja so you initiated the sync on the artist and not an album or song?

Yes i initiated sync on the artist.

This artist has ~ 30 albums and ~ 600 tracks

Link to comment
Share on other sites

Ok I'll keep testing, thanks. It's odd because I'm able to sync the very same artist with no problem.

Link to comment
Share on other sites

  • 2 weeks later...
ginjaninja

re sync robustness it seems that sync task can not survive me closing the samsung case on my samsung s8+....the transfer halts at 0kbs but the notificafion bar continues to show for last media being transfering before i closed the case, when i reopen the case after 2 mins, is that be expected? is closing case different to just letting display timeout kick in....i will check now (or when the sync starts again hopefully in next 15minutes)

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

No, not expected, and I cannot reproduce that. I may have to get my hands on a samsung to test that out.

Link to comment
Share on other sites

ginjaninja

so its not just closing the case, once the display timeout kicks in and a few more seconds have passed to the point that i would have to enter pin to unlock...the device stops syncing...currently the only way i could get the phone to sync (i believe) would to play a game non stop for X hours...whilst the queue got progressed.

 

I guess this explains the initial reason for the thread...is there a android call that could stop the phone going to sleep?

I cant set the screen timeout to never.

I have set the samsung setting to never let emby go to sleep..maybe that doesnt affect the sync task..does that have a separate app name?

 

then of course even if i do start using the device...syncing does not robustly kick in after 15minutes...

 

 

since i enabled remote access and published https to remote clients, and i logged the android client on using emby connect remotely...

now the client continues to ask do i trust certificate repeatedly after a device reboot (when on the lan)..and syncing seems to be kicked in to life by answering yes to that question once emby gets to stage of needing to ask that question again (do you trust cert) - whatever causes that.

 

its anecdotal, but if i let the device screen time out..but then wake it within a few seconds, the speed has reportedly to drop to 500Kbits but then picks back up again to 12MB/s...so perhaps its not emby going to sleep, rather the network services. ro the network card is put into low power...

 

when the sync does fail...its more often than not taking more than 15 minutes to start syncing again (im fairly sure) after waking the device. although not a long term design requirement perhaps, but for this reason a 'sync now' could be helpful in the meantime.

Link to comment
Share on other sites

ginjaninja

oh dear...i fear im an idiot...

 

just turned off power saving...and one of the things it said was ...background network on...LOL

 

hopefully that will have fixed the robustness..bar the certificate acceptance issue...i will report back

Link to comment
Share on other sites

ginjaninja

yay the device is copying even when case is closed...and the cert acceptance dialogue didnt appear after last reboot...

now i just need to cancel my syncs and resync  to get back to medium quality...will try r.e.m. again now im on a roll.

Link to comment
Share on other sites

ginjaninja

nope it still seems there are a multitude of ways that syncing will stop. the starting and stopping of syncing is closely related to the emby app...i thought the whole point of the sync task was to decouple the two?...on more than one occassion syncing has started at the point of opening app...and also stopped at the point of closing app. emby has used 150gb of wifi data bandwidth to transfer 50gb of files at home with perfect wifi signal today...not withstanding http overhead that is alot of failed attempts and retries...could resumes be supported? a 2gb file requires about 5 min uninterrupted connection to transfer...it appears more often than not, general use or not use of the device / emby can get in the way?

 

Sent from my SM-G955F using Tapatalk

Link to comment
Share on other sites

ginjaninja

So I think i have found a reliable way to sync on Galaxy S8.

  • Ensure powersaving of device is switched off (this step is important)
  • Ensure that the wifi settings are set to always on even on battery (i think this will be the case as a result of the powersaving setting)
  • Ensure Emby is set to never sleep (in power saving settings) (this step may not be necessary)
  • restart the device
  • leave the device connected to mains (this step may not be necessary)
  • reboot the device
  • do NOT touch the device :-) (this is the key step, but perhaps could be relaxed to 'do not start Emby')

 

Its a bit cumbersome, but it seems to get the job done.

As the size of the jobs increases (eg high quality feature length movies) i think the process success becomes exponentially more sensitive....for syncing music, there is enough of a window under more relaxed conditions for the approach not to matter.

Link to comment
Share on other sites

Thanks. I think you can touch the device though. I'm sure some of these can be removed.

Link to comment
Share on other sites

  • 3 weeks later...

So I think i have found a reliable way to sync on Galaxy S8.

  • Ensure powersaving of device is switched off (this step is important)
  • Ensure that the wifi settings are set to always on even on battery (i think this will be the case as a result of the powersaving setting)
  • Ensure Emby is set to never sleep (in power saving settings) (this step may not be necessary)
  • restart the device
  • leave the device connected to mains (this step may not be necessary)
  • reboot the device
  • do NOT touch the device :-) (this is the key step, but perhaps could be relaxed to 'do not start Emby')

 

Its a bit cumbersome, but it seems to get the job done.

As the size of the jobs increases (eg high quality feature length movies) i think the process success becomes exponentially more sensitive....for syncing music, there is enough of a window under more relaxed conditions for the approach not to matter.

 

@@ginjaninja I don't believe these procedures are necessary anymore. thanks.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...