After installing Cursor CLI and restarting the command line, when trying to run a prompt, it displays the following: Error: SQLITE_CANTOPEN: unable to open database file.
The message appears briefly and then returns to the input to type the prompt.
I also ran into this issue on native Ubuntu 20.04. I think it is an issue with libc compatibility with the built in node_sqlite3.node executable. I replaced the one under .local/share/cursor-agent/versions/…/build with one I pulled out of the node_modules of another project and it started working.
use jetbrains remote development, and login in jetbrains cmd, then copy authorize link into local www browser tool and complete login. start cursor-agent in jetbrains, say anything, and it show err above: SQLITE_CANTOPEN.
I copy this node_sqlite3.node to ‘~/.local/share/cursor-agent/versions/2025.08.08-f57cb59/build/node_sqlite3.node’, and then start cursor-agent, it works !
Thank you,It works!
I also build sqite3 node by npm install sqlite3 --build-from-source
and then cp node_modules/sqlite3/build/Release/node_sqlite3.node ~/.local/share/cursor-agent/versions/2025.08.08-f57cb59/build/
Also seems to be fixed on official installation, version 2025.08.09-d8191f3 was installed on another machine with the same WSL image and doesn’t have the sqlite error.