Jump to content


Photo

Emby Server will not sleep if Android app has been used, but is now closed and cleared from recents

sleep suspend active

  • Please log in to reply
13 replies to this topic

#1 MarkCranness OFFLINE  

MarkCranness

    Newbie

  • Members
  • 4 posts
  • Local time: 10:02 PM

Posted 23 April 2019 - 03:32 AM

I note that my Emby server will not go to sleep if my mobile has used Emby, BUT then the Emby app has been closed and cleared from android recent apps.

 

The server dashboard still show the device in Active Devices: "Emby for Android Mobile 3.0.45"

 

But I have a clue and a way to get the device removed.

Apparently, Android 6.0+ will keep apps Active, even though they are not "open" and even if removed from the list of recent apps.

 

The feature is "App Standby": https://developer.an...te/doze-standby

The Emby app shows as "Active" (not in standby) even when closed.

 

You can enable Developer mode, and see which apps are in Standby, and which are Active:

https://www.howtogee...ntly-stop-apps/

(Scroll to "How to See Which Apps Are Currently in Standby")

 

Follow instructions above, scroll to Emby, tap it to toggle from Active to Inactive.

 

Then after a while, the server dashboard drops the device from Active Devices, and will go to sleep.

 

Is there some way to force the Emby app to Inactive/Standby when it is closed?


Edited by MarkCranness, 23 April 2019 - 04:39 AM.


#2 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 24 April 2019 - 12:36 AM

Hi, this is due to the background sync process in the app. It is something we will be looking at improving in an upcoming update. thanks.



#3 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 11 May 2019 - 02:29 PM

This is resolved for the next update to the android app, with Emby Server 4.0+. Thanks !



#4 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 22 June 2019 - 01:22 PM

Can you try 3.0.51+ and see how that compares:

https://emby.media/c...id-mobile-3051/

Thanks.



#5 MarkCranness OFFLINE  

MarkCranness

    Newbie

  • Members
  • 4 posts
  • Local time: 10:02 PM

Posted 23 June 2019 - 01:34 AM

Hi Luke,

 

Yes, 3.0.51 fixes it.

 

Thank you for the good work you are doing!

 

There is another (unrelated) problem:

I have to be careful of what order I stop Emby playback on the mobile, otherwise the server thinks it is still playing media (shall I create another form issue for this beta problem?)

 

- If I close Emby for mobile with the Back (back loop) button while still playing media, the media stops playing, and the Emby notification disappears, and Emby is still shown in the Android Recents list, but the server thinks that media is still playing back.

If I restart Emby for android, the Emby notification re-appears, but tapping Pause does not do anything (no media is playing anyway).

 

 

- If I pause media playback in Emby for mobile close Emby on android with the Back (back loop) button while still playing media, the media stops playing, the Emby notification stays, and Emby is still shown in the Android Recents list, but the server thinks that media is still playing back, but paused.

If I restart Emby for android, and swipe down the Emby notification, and tap Pause, it does not do anything (no media is playing anyway).

 

- If I pause media playback (either in Emby app, or in the Emby notification), THEN swipe away the Emby notification, then the server sees that the app is no longer playing media (neither playing nor paused). After a while (without browsing media in a the app), the device disappears from Active Devices, as expected.



#6 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 23 June 2019 - 01:54 AM

Thanks for the feedback. To clarify on those, if you close the app in a way that the app isn't able to notify the server, then that's why that happens. You'll just have to wait a few minutes for it to go away from the server dashboard.



#7 MarkCranness OFFLINE  

MarkCranness

    Newbie

  • Members
  • 4 posts
  • Local time: 10:02 PM

Posted 23 June 2019 - 02:43 AM

I confirm that it does disappear from the server dashboard, so not a problem: Just how it works, thanks.



#8 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 23 June 2019 - 09:54 AM

I confirm that it does disappear from the server dashboard, so not a problem: Just how it works, thanks.

 

Thanks for the feedback. Shouldn't take long. Five minutes for the current release server. The next release will bring that down to three.



#9 PontusN OFFLINE  

PontusN

    Member

  • Members
  • 15 posts
  • Local time: 10:02 AM

Posted 19 February 2020 - 02:35 AM

This is resolved for the next update to the android app, with Emby Server 4.0+. Thanks !

Hello, I thought this was the best place to alert you with this issue, the problem has come back again with 3.0.97, I now have 3 phones keeping my server awake at all times.

 

In dev options the Standby State is set to "Active" by default with the lowest possible option being "RARE" and not "NEVER".


Edited by PontusN, 19 February 2020 - 02:43 AM.


#10 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 19 February 2020 - 01:45 PM

Hello, I thought this was the best place to alert you with this issue, the problem has come back again with 3.0.97, I now have 3 phones keeping my server awake at all times.

 

In dev options the Standby State is set to "Active" by default with the lowest possible option being "RARE" and not "NEVER".

Please attach the emby server log from when you thought it should have gone to sleep. Thanks.



#11 PontusN OFFLINE  

PontusN

    Member

  • Members
  • 15 posts
  • Local time: 10:02 AM

Posted 20 February 2020 - 02:59 AM

Please attach the emby server log from when you thought it should have gone to sleep. Thanks.

Here is the serverlog from tonight, all phones have changed the standbystate for the app to the lowest possible "RARE" before this.

Attached Files



#12 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 21 February 2020 - 01:46 AM

And what time do you think the system should have gone to sleep?



#13 PontusN OFFLINE  

PontusN

    Member

  • Members
  • 15 posts
  • Local time: 10:02 AM

Posted 21 February 2020 - 10:39 AM

And what time do you think the system should have gone to sleep?


During the night, but as you can see in the log file a lot of activity is coming from two phones, a Nexus 6 and a OnePlus

#14 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 153204 posts
  • Local time: 05:02 AM

Posted 23 February 2020 - 12:54 AM

At that particular time, yes. Is it consistent?







Also tagged with one or more of these keywords: sleep, suspend, active

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users