How to Disable the Phantom Process Killer in Android Developer Options to Prevent Background Task Termination

Beginning with Android 12 and continued through Android 13, 14, and 15, power users, developers, and system administrators running Linux environments (such as Termux, UserLAnd, or local development servers) began encountering sudden, unexplainable process terminations. Long-running compilation jobs, background SSH sessions, Git clones, and local Python scripts would abruptly crash with the terminal signal [Process completed (signal 9) - press Enter] whenever the app was minimized.

This aggressive process killing is enforced by an internal Android system feature known as the Phantom Process Killer. Designed to prevent rogue malware and unoptimized apps from exhausting CPU resources in the background, Android strictly limits all child processes spawned by a parent application to a maximum of 32 total processes. Once this threshold is exceeded, the Android Activity Manager automatically transmits a ruthless SIGKILL (signal 9) to terminate child tasks.

Fortunately, modern Android versions include native controls to adjust child process execution policies. This guide explains how to disable child process restrictions via Developer Options and ADB.

Method 1: Disabling Child Process Restrictions in Developer Options

On Android 14 and Android 15 devices (such as Google Pixel and modern custom ROMs):

  1. Open Settings on your Android device.
  2. Navigate to About phone, scroll to the bottom, and tap Build number seven times to unlock Developer Options.
  3. Return to Settings > System > Developer options.
  4. Scroll down to the Apps category.
  5. Locate the toggle labeled Disable child process restrictions.
  6. Switch the toggle to ON.
  7. Reboot your Android phone to apply the updated process scheduler policy.

Method 2: Disabling the Phantom Process Killer via ADB

For Android 12 and Android 13 devices where the developer toggle is absent, configure the system global setting using an ADB (Android Debug Bridge) command:

  1. Connect your Android phone to a computer with ADB installed, or use a local shell utility like Shizuku.
  2. Open your terminal and verify device connectivity:
    adb devices
  3. Execute the following system setting command to disable phantom process enforcement:
    adb shell /system/bin/device_config put activity_manager max_phantom_processes 2147483647
  4. To ensure the setting persists across device reboots on Android 13+, also disable the monitor service:
    adb shell /system/bin/device_config set_sync_disabled_for_tests persistent

System Impact Comparison Table

System Behavior Default Android Enforcement Child Process Restrictions Disabled
Maximum Child Processes Strictly capped at 32 child tasks Unlimited (Operating system limit)
Background Terminal Stability Termux sessions frequently killed Complex compilation & scripts run uninterrupted
Battery Impact Slightly more aggressive power savings Preserves background jobs (Minimal drain if idle)
Signal Sent on Limit SIGKILL (Signal 9) Normal POSIX process lifecycle

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.