0X0000009B

0x0000009B ERROR_TOO_MANY_TCBS – Thread Limit Reached Fix

Windows Errors Intermediate 👁 7 views 📅 Jun 14, 2026

This error means Windows ran out of thread contexts (TCBs). The most common fix is adjusting the system's thread limit or closing leaky apps.

Cause 1: A single process is leaking threads (most common)

The real trigger here is usually a bad program that keeps spawning new threads but never closes them. You'll see this error in event logs under ERROR_TOO_MANY_TCBS, and the app might crash with a "Cannot create another thread" message. I've seen this most often on Windows 10 and Windows Server 2019 with poorly coded third-party services—antivirus scanners, backup agents, or old custom .NET apps.

Here's how to find the leaky process:

  1. Open Task Manager (Ctrl+Shift+Esc).
  2. Go to the Details tab. Right-click any column header and click Select columns.
  3. Check Threads and click OK.
  4. Sort by the Threads column descending. A normal process should have under 200 threads. Anything over 500 is suspicious. Over 1000 is almost certainly leaking.
  5. If you see a process with thousands of threads, that's your culprit. Right-click it and choose End task. The error should stop immediately.

After ending the process, restart the computer to clear all thread contexts. If the problem comes back, you need to update or replace that software. Don't just increase the thread limit yet—you're treating symptoms, not the disease.

Cause 2: System thread limit is too low for your workload (advanced)

Sometimes you're running a legitimate heavy-duty app—like a database server, a render farm worker, or a high-frequency trading platform—that genuinely needs more threads than Windows allows by default. Windows has a hard limit of about 2,048 thread context blocks (TCBs) per process on 32-bit systems, and on 64-bit systems it's much higher (up to 16 million), but the kernel's thread limit can still be capped by the paged pool size.

Before you touch anything, confirm the limit is the problem. Open an administrator Command Prompt and run:

wmic path Win32_Process where "Name='yourapp.exe'" get ThreadCount

Replace yourapp.exe with your process name. If the number is close to 2,000-2,100 and you still need more, you'll need to increase the system's paged pool size and thread limit via registry.

Warning: Changing these values can cause system instability. The fix below is for Windows 10/11 Pro, Enterprise, or Server editions only.

  1. Press Win+R, type regedit, and press Enter.
  2. Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management.
  3. Look for a DWORD called PagedPoolSize. If it doesn't exist, right-click in the right pane, choose New > DWORD (32-bit), and name it PagedPoolSize.
  4. Set its value to FFFFFFFF (hexadecimal). This tells Windows to use the maximum paged pool size (up to 512 MB on 32-bit, 2 GB on 64-bit).
  5. Now go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management and create another DWORD named PoolSizeLimit. Set it to FFFFFFFF as well.
  6. Restart the computer.

After restart, the thread limit for a single process is effectively raised to around 16,000-32,000 on 64-bit systems. Test your app again. If you still hit the error, you're probably hitting a process-level thread limit, not a system one.

Cause 3: Windows kernel thread pool exhaustion (server environments)

On Windows Server 2012 R2 through 2022, I've seen this error happen when the kernel's thread pool worker threads get depleted. This typically happens on heavily loaded terminal servers or web servers running IIS with many concurrent requests that each spawn threads.

The symptom is different: the error might appear in System event log as 0x0000009B with source Kernel-General, and you'll see many I/O completion port threads stuck waiting.

The fix here is to adjust the thread pool minimum and maximum:

  1. Open Registry Editor (regedit as admin).
  2. Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Executive. If the Executive key doesn't exist, create it.
  3. Create a new DWORD named AdditionalThreadCount. Set it to 512 (decimal). This adds 512 extra thread slots to the kernel executive pool.
  4. Create another DWORD named ThreadCountMultiplier. Set it to 4 (decimal). This multiplies the default thread count for each CPU core.
  5. Restart the server.

I've used this fix on a Windows Server 2019 running a custom ASP.NET app that handled 10,000+ concurrent connections. It stopped the error cold.

Quick-reference summary table

Cause Diagnosis Fix Difficulty
Process thread leak Task Manager shows 500+ threads in one process End the leaking process, update software Beginner
Low paged pool limit Thread count near 2,048 on 32-bit system Set PagedPoolSize and PoolSizeLimit to FFFFFFFF in registry Intermediate
Kernel thread pool exhaustion Event ID 0x9B with Kernel-General on server Add AdditionalThreadCount and ThreadCountMultiplier registry values Advanced

A final word: Don't blindly change registry values. Start with Cause 1—it's responsible for 9 out of 10 cases I've seen. The registry tweaks in Cause 2 and 3 are last-resort tools. If you're not comfortable editing the registry, get a sysadmin or developer who knows the app to help. And always back up your registry before making changes.

Was this solution helpful?