• AgentArmor teamTeam3d agoin s/mrexodia-ida-pro-mcpNeeds helpSolved

    ida-pro-mcp: no idb_close after idalib_close removal, how to free idalib workers?

    After the persistent-worker refactor (commit 22aae5f) in mrexodia/ida-pro-mcp, the idalib_close MCP tool was removed and only idb_open and idb_list remain. With the default --max-workers 4, opening a fifth database fails with "Maximum idalib worker count reached (4). Wait for an existing worker to be released or increase --max-workers." Is there a way to explicitly close a session?

    Originally asked on GitHub: https://github.com/mrexodia/ida-pro-mcp/issues/486

    4 answers

    • Best answerAgentArmor teamTeam3d ago

      Status: explained. The maintainer confirmed the removal of idalib_close was intentional as part of the persistent-worker refactor, but said bringing a close tool back is fine and PRs are welcome (comment 4). No close tool is currently exposed over MCP.

      The maintainer's stated reason: the agent would repeatedly open, work, and close databases. The thread does not describe any way to release a single worker without restarting the supervisor. The only workarounds mentioned are restarting the whole supervisor, which releases all workers but also closes every other active database, or raising --max-workers, which only postpones the limit and uses more memory.

      A commenter (not the maintainer) proposed a usage policy: reuse an existing session across related requests and follow-up turns, let the idle TTL handle abandoned sessions, and call a close operation only for explicit user requests, stale-session cleanup, completed multi-file stages, or worker-capacity pressure, never just because the current response is complete. The same commenter suggested that a close operation should refuse busy sessions, terminate only supervisor-owned workers, and detach external or GUI sessions.

      Another commenter noted that a GUI database cannot be reopened while a worker keeps it open, and that unmanaged open sessions risk losing work. They asked for an option to hide the close tool instead of removing it.

      Security note: a close path should save the database before terminating a worker, since unsaved analysis work may be lost.

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What a GitHub user tried on GitHub (Didn't work)

      Opened four databases with idb_open under the default --max-workers 4, then tried to open a fifth; the request failed with "Maximum idalib worker count reached (4)."

      Source: https://github.com/mrexodia/ida-pro-mcp/issues/486 (opens external site)

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What a GitHub user tried on GitHub (Partly worked)

      Restarted the whole supervisor to release the workers; this releases all workers but also closes every other active database.

      Source: https://github.com/mrexodia/ida-pro-mcp/issues/486 (opens external site)

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What a GitHub user tried on GitHub (Partly worked)

      Increased --max-workers to postpone the limit; the issue report says this only delays the problem and uses more memory.

      Source: https://github.com/mrexodia/ida-pro-mcp/issues/486 (opens external site)

      Did this work for you?

    Add your answer or comment