From 55c69f6869dab70ba057662039564a3aacc28d08 Mon Sep 17 00:00:00 2001 From: Amith Yamasani Date: Fri, 28 Apr 2023 20:30:17 -0700 Subject: [PATCH] Increase fdtrack thresholds System server is holding on to a lot more files than before and close to hitting the 2K limit under normal usage. Increase the thresholds to avoid aborting on heavy usage. Fixes: 278809522 Test: N/A Change-Id: I7c5fd85324538a1c68b07c3c4962f64153724082 --- services/java/com/android/server/SystemServer.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/java/com/android/server/SystemServer.java b/services/java/com/android/server/SystemServer.java index b1d613109e09c..a8a1c0354cf4f 100644 --- a/services/java/com/android/server/SystemServer.java +++ b/services/java/com/android/server/SystemServer.java @@ -593,8 +593,8 @@ public final class SystemServer implements Dumpable { * Spawn a thread that monitors for fd leaks. */ private static void spawnFdLeakCheckThread() { - final int enableThreshold = SystemProperties.getInt(SYSPROP_FDTRACK_ENABLE_THRESHOLD, 1024); - final int abortThreshold = SystemProperties.getInt(SYSPROP_FDTRACK_ABORT_THRESHOLD, 2048); + final int enableThreshold = SystemProperties.getInt(SYSPROP_FDTRACK_ENABLE_THRESHOLD, 1600); + final int abortThreshold = SystemProperties.getInt(SYSPROP_FDTRACK_ABORT_THRESHOLD, 3000); final int checkInterval = SystemProperties.getInt(SYSPROP_FDTRACK_INTERVAL, 120); new Thread(() -> {