2

I've been trying to run a ssh and a http server on my non-rooted Android phone using Termux.

I've installed Termux:Boot and termux-services to run them.

The server processes run for a while after I release the wakelock but are then killed by the system:

09-23 13:25:21.592  4450  5008 I ActivityManager: KPU : put [com.termux] : 15433 K
09-23 13:25:21.592  4450  5008 I ActivityManager: Killing 25360:com.termux/u0a171 (adj 904): DHA:empty #17

I tried disabling the app power monitor (Setting -> Device maintenance -> Battery) but it doesn't seem to make any difference.

Save rooting the phone, or keeping a wakelock in place, is there any way I can stop the ActivityManager killing my processes?

Setup: Samsung Galaxy A5 with stock-rom (Android 8 / Samsung Experience 9)

0

1 Answer 1

1

I don't have Galaxy A5, but I have Galaxy A10s and this helped me:

  1. Go to Settings -> Apps -> Termux.
  2. Tap Battery.
  3. Enable Allow background activity.
  4. Open Termux.
  5. In Termux notification, click Acquire wakelock.
  6. Tap Allow.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .