华为智能手机(Huawei smartphone)被全球数百万人使用。不幸的是,它们都有一个令人讨厌的功能:当您锁定屏幕时,它们会关闭在后台运行的应用程序,以节省电池电量(battery power)。这包括您希望在后台运行的应用程序,例如为保护而安装的防病毒软件、孩子的家长控制、健身追踪器(fitness tracker)或 GPS 导航。以下是如何阻止您的华为智能手机(Huawei smartphone)关闭您想要在后台运行的应用程序,即使您关闭了屏幕:
“受保护的应用程序”或华为强制(Huawei force)关闭后台运行的应用程序的原因
总之,节省电池电量。(In short, to save battery power.) 华为(Huawei)的EMUI Android 操作系统(operating system)一直有激进的省电算法。想法是,当你关闭屏幕时,你不需要大多数应用程序在后台运行,华为(Huawei)将它们杀死,这样它们就不会消耗能量。这意味着华为(Huawei)智能手机往往具有出色的电池寿命(battery life),但这是以用户烦恼为代价的。为了帮助用户,在他们基于 Android 7 的智能手机 ( Android Nougat ) 上,华为(Huawei)有一个名为“受保护的应用程序”的功能。("Protected Apps.")它允许用户和应用程序开发人员将某些应用程序设置为“受保护”("protected")即使屏幕关闭,它们也能在后台运行。不幸的是,从Android 8 Oreo 和 EMUI(Oreo and EMUI) 8 开始,这个功能被重命名为“应用启动”(App launch,"),知道“受保护的应用”("Protected Apps")的人已经找不到它了。
哪些应用会受到华为算法(Huawei algorithms)的负面影响?
并非所有应用程序都会受到此问题的影响。华为(Huawei)维护着一份热门应用程序列表,这些应用程序不会停止在后台执行其操作。此外,一些应用程序开发人员已经将他们的Android 应用程序(Android apps)与华为(Huawei)智能手机很好地集成在一起,并且没有出现问题。
但是,也有一长串受到负面影响的应用程序。首先是防病毒应用程序,例如AVG Antivirus、Avast antivirus、Kaspersky Mobile Antivirus、ESET Mobile Security & Antivirus、Bitdefender Mobile Security等。另一类受影响的应用程序是家长控制工具,例如ESET Parental Control、Kaspersky Parental Control、Kids Place等。此类应用程序的最大问题是华为(Huawei)完全禁用它们,使它们无用。因此,告别家长控制,您的孩子仍然不受保护。
其他有问题的应用程序是各种健身追踪器:Fitbit、Garmin、Endomondo、Runkeeper、Strava、Under Armour Record等等。假设你出去跑步,或者你为一项运动而训练。关闭屏幕后,您的华为智能手机(Huawei smartphone)可能会强制关闭您的跟踪应用程序和连接的GPS,因此无法跟踪任何内容,因为该应用程序已被阻止。
运输和导航应用程序(Transport and navigation apps)也受到华为(Huawei)方法的负面影响。假设您需要旅行并使用Uber、Bolt或Yango去某个地方。您设置目的地,然后叫车。您关闭华为智能手机(Huawei smartphone)的屏幕,将其放在口袋里,并期待应用程序为您找到司机,等待他或她到达您的位置时收到通知。华为(Huawei)的算法可能会因为您关闭屏幕而关闭应用程序以节省电量。
其他受到负面影响的应用类型包括VPN 应用(VPN apps)、录音机、聊天应用、新闻应用(news apps)、基于位置的应用和各种跟踪应用。要为所有类型的应用程序解决此问题,请按照本教程中的后续步骤操作:
步骤 1(Step 1)。将您的华为智能手机(Huawei smartphone)设置为允许特定应用程序在后台运行
解锁(Unlock)您的华为智能手机(Huawei smartphone)并转到其设置(Settings)应用程序。然后,点击设置的电池(Battery)类别。
您会看到许多与电池相关的设置和开关。点击应用启动(App launch)。
您会看到华为智能手机(Huawei smartphone)上安装的所有应用程序的列表。除了少数由华为(Huawei)控制的例外,所有例外都应设置为“自动管理”("Manage automatically,"),如下面的屏幕截图所示。
这意味着每次锁定屏幕时,您的华为智能手机(Huawei smartphone)都可以根据其算法自由强制关闭您的任何应用程序。找到您要配置的应用程序,然后将其开关关闭为“手动管理”。("Manage manually.")系统会在询问您希望允许应用执行何种活动的位置显示提示:
-
“自动启动”("Auto-launch") - 允许应用程序在您打开智能手机或需要在后台运行时自动启动。
-
“二次启动”("Secondary launch") - 允许该应用程序由需要它的其他应用程序启动。
-
“在后台运行”("Run in background") - 允许应用程序在需要时在后台继续运行,只要它需要这样做。
要消除所有问题,最好让应用程序执行所有三种类型的活动,因此启用所有三个开关,然后点击确定。
找到您要在后台运行的所有应用程序并重复相同的设置。执行此操作时,请注意他们的开关已关闭,并且在他们的名字下方,您会看到文本“手动管理”。(Manage manually.")这很好,因为这意味着华为(Huawei)停止杀死他们。
如果您对华为(Huawei)在锁定屏幕时关闭后台应用程序(background apps)的方式感到沮丧,您可以为您的所有应用程序禁用此“功能”。为此,在“应用程序启动”("App launch")屏幕中,点击开关“自动管理所有”(Manage all automatically")并将其设置为禁用。这将禁用后台应用程序(background apps)的自动处理,并允许所有应用程序在他们想要的时候做他们想做的事。这似乎是个好主意,但请记住,此设置会缩短智能手机的电池寿命(battery life)。最好单独设置应用程序。
为一个或多个应用禁用此功能后,一个新选项可用。在EMUI 9 ( Android 9 ) 和 EMUI 10 ( Android 10 ) 上,点击右上角的三个点,然后点击手动管理(Manage manually)。
您会看到所有禁用强制关闭的应用程序。您可以为所有三种类型的任务单独设置要授予的权限类型:“自动启动”、“辅助启动”("Auto-launch," "Secondary launch,")和“在后台运行”。("Run in background.")
不幸的是,您的工作并不止于此。为确保您的华为智能手机(Huawei smartphone)永远不会杀死您想要在后台运行的应用程序,您应该为您在此步骤中配置的相同应用程序禁用电池优化(Battery optimization)功能。
步骤 2(Step 2)。禁用相同应用的电池优化(Battery optimization)
再次打开设置(Settings)。然后,点击Battery上方的(Battery)应用程序(Apps)设置类别。
您会看到一个包含许多类别和应用设置的屏幕。再次点击应用程序(Apps)。
您会看到安装在您的华为智能手机(Huawei smartphone)上的所有应用程序的列表。点击右上角的三个点,然后点击特殊访问(Special access)。
您会看到几个类别的高级设置。点击电池优化(Battery optimization)。
您现在看到应用程序设置为“不允许”。这意味着华为(Huawei)永远不会杀死的应用程序,即使您的电池优化(Battery optimization)已打开。这个列表很短,它包括由华为(Huawei)和其他一些公司制作的应用程序,比如Facebook或你的相机(Camera)。点击不允许(Not allowed),然后选择所有应用程序(All apps)。
您会看到华为设备(Huawei device)上的所有应用程序。点击您不想被杀死的应用程序,选择“不允许”("Don't allow,"),然后按OK。选择“不允许”听起来违反直觉,("Don't allow,")但该设置意味着“不允许电池优化杀死应用程序”。("Do not allow the battery optimization to kill the app.")这就是您被告知该设置可能会更快耗尽电池电量的原因。
对您不希望华为设备(Huawei device)杀死的所有应用程序重复此操作,您终于完成了。
这适用于哪些华为(Huawei)智能手机?
本教程是在搭载 Android 10 (EMUI 10) 的华为P30(Android 10)智能手机(EMUI 10)上创建的,并在华为(Huawei P30 smartphone)P20(Huawei P20)和华为 P30 lite(Huawei P30 lite)上进行了确认。它应该适用于所有配备Android 9 Pie或更高版本的EMUI 版本 9的(EMUI version 9)华为(Huawei)智能手机。这包括华为 P20(Huawei P20)、P30和P40系列中的所有型号,以及华为 Mate 系列(Huawei Mate family)设备。如果一切顺利,请在下面的评论中告诉我们。
Stop your Huawei smartphone from killing background apps
Huaweі smartphones are used by millions of peoplе all over the world. Unfortunately, all of them have one annoying feature: they close apps that run in the background when you lock the screen, to save battеry power. This includes apps that you want running in the background, like the antivirus you installed for protection, the parental controls for your сhild, your fitness tracker, or your GPS navigation. Here is how to stop уour Huawei smartphone from closing apps that you want to run in the background, even when уou cloѕe the screen:
"Protected apps" or why Huawei force closes apps running in the background
In short, to save battery power. Huawei's EMUI Android operating system has always had aggressive battery saving algorithms. The thinking is that, when you close the screen, you do not need most apps to run in the background, and Huawei kills them so that they do not consume energy. This means that Huawei smartphones tend to have excellent battery life, but this comes at the cost of annoyances for users. To help users, on their Android 7-based smartphones (Android Nougat), Huawei had a feature called "Protected Apps." It allowed users and app developers to set certain apps as "protected" to keep them running in the background even when the screen is turned off. Unfortunately, starting with Android 8 Oreo and EMUI 8, this feature was renamed to "App launch," and people who knew about "Protected Apps" can no longer find it.
What kinds of apps are negatively affected by Huawei algorithms?
Not all apps are affected by this problem. Huawei maintains a list of popular apps that are not stopped from doing their thing in the background. Also, some app developers have integrated their Android apps well with Huawei smartphones and do not have problems.
However, there is also a long list of apps that are negatively affected. These are, first of all, antivirus apps like AVG Antivirus, Avast antivirus, Kaspersky Mobile Antivirus, ESET Mobile Security & Antivirus, Bitdefender Mobile Security, and more. Another category of affected apps is parental control tools like ESET Parental Control, Kaspersky Parental Control, Kids Place, and others. The big issue with this category of apps is that Huawei completely disables them, rendering them useless. Therefore, goodbye parental controls and your child remains unprotected.
Other apps that have issues are fitness trackers of all kinds: Fitbit, Garmin, Endomondo, Runkeeper, Strava, Under Armour Record, and more. Let's say that you go out running, or you train for a sport. After you close the screen, it is likely that your Huawei smartphone force closes your tracking app and your connected GPS, so nothing gets tracked because the app was blocked.
Transport and navigation apps are also negatively impacted by Huawei's approach. Let's assume that you need to travel and use Uber, Bolt, or Yango to get someplace. You set the destination, and then order a ride. You close the screen on your Huawei smartphone, place it in your pocket, and expect the app to find you a driver, waiting to get notifications on when he or she arrives at your place. Huawei's algorithms might close the app to save battery because you closed the screen.
Other types of apps that are negatively impacted are VPN apps, voice recorders, chat apps, news apps, location-based apps, and all kinds of tracking apps. To solve this problem for all types of apps, follow the next steps in this tutorial:
Step 1. Set your Huawei smartphone to allow specific apps to run in the background
Unlock your Huawei smartphone and go to its Settings app. Then, tap the Battery category of settings.
You see many battery-related settings and switches. Tap on App launch.
You see a list of all the apps that are installed on your Huawei smartphone. With a few exceptions controlled by Huawei, all of them should be set to "Manage automatically," as seen in the screenshot below.
This means that your Huawei smartphone is free to force-close any of your apps, as it sees fit according to its algorithms, each time you lock the screen. Find the app that you want to configure and turn off its switch to "Manage manually." A prompt is shown where you are asked what kind of activities you want to allow the app to perform:
-
"Auto-launch" - allow the app to start itself automatically when you turn on the smartphone or when it needs to run in the background.
-
"Secondary launch" - allows the app to be launched by other apps that need it.
-
"Run in background" - allow the app to keep running in the background for as long as it needs, whenever it needs to do that.
To eliminate all issues, it is a good idea to allow the app to perform all three types of activities, so enable all three switches, and tap OK.
Find all the apps which you want to run in the background and repeat the same settings. As you do this, notice that they have their switches turned off, and, beneath their name, you see the text "Manage manually." This is good, as it means that Huawei stops killing them.
If you are frustrated by how Huawei closes background apps when you lock the screen, you can disable this "feature" for ALL your apps. To do that, in the "App launch" screen, tap the switch "Manage all automatically" and set it to disabled. This disables the automatic handling of background apps, and allows all apps do what they want when they want. This might seem like a great idea, but do keep in mind that this setting is going to reduce your smartphone's battery life. It might be best to set up apps individually.
After you disable this feature for one app or more, a new option becomes available. On both EMUI 9 (Android 9) and EMUI 10 (Android 10), tap the three dots on the top-right corner, and then on Manage manually.
You see all the apps for which the forced closure was disabled. You can set individually what kind of permissions you want to give, for all three types of tasks: "Auto-launch," "Secondary launch," and "Run in background."
Unfortunately, your work doesn't stop here. To be sure that your Huawei smartphone never kills the apps that you want to run in the background, you should disable the Battery optimization feature for the same apps you configured during this step.
Step 2. Disable the Battery optimization for the same apps
Open the Settings one more time. Then, tap the Apps category of settings that is above Battery.
You see a screen with lots of categories and app settings. Tap on Apps one more time.
You are shown a list of all the apps installed on your Huawei smartphone. Tap the three dots on the top-right corner, and then on Special access.
You see several categories of advanced settings. Tap on Battery optimization.
You now see the apps set as "Not allowed." This means the apps that Huawei never kills, not even when your Battery optimization is turned on. This list is short, and it includes apps made by Huawei and a few others, like Facebook or your Camera. Tap on Not allowed and then choose All apps.
You see all the apps on your Huawei device. Tap on the app you don't want to be killed, choose "Don't allow," and press OK. It sounds counterintuitive to choose "Don't allow," but that setting means "Do not allow the battery optimization to kill the app." This is why you are informed the setting may drain your battery more quickly.
Repeat this for all the apps that you do not want your Huawei device to kill, and you are finally done.
On which Huawei smartphones does this work?
This tutorial was created on a Huawei P30 smartphone with Android 10 (EMUI 10), and also confirmed on a Huawei P20 and a Huawei P30 lite. It should work on ALL Huawei smartphones that have EMUI version 9 with Android 9 Pie, or newer. This includes all the models in the Huawei P20, P30, and P40 lineups, as well as the Huawei Mate family of devices. Let us know if everything went well in the comments below.