Hello everyone! Today I encountered a problem when starting the AI Agent node.
It doesn’t start, and an error is returned: Problem running workflow
/usr/lib/node_modules/n8n/node_modules/sqlite3/build/Release/node_sqlite3.node: invalid ELF header
Does it only happen with the AI Agent node or do you get an issue with all workflows?
I would recommend moving to a Docker based install which will have less issues but can you share the version of nodejs you are using? I think the issue is likely to be that the version of sqlite3 is not compatible with your CPU or OS like maybe you are using 32-bit ARM or something maybe an old Pi.
That is very odd, I have not seen any other reports of this. Just to rule out anything odd, What sort of CPU are you using and has your sqlite file always been on the Linux filesystem?
I would have thought that would be ok, I would be tempted to uninstall n8n and clear out the modules folder then try and install it again to see if that helps.
are you installing n8n directly on the machine that it is running on, or are you copying over the installation from another machine somehow?
This error comes from when the sqlite3 bindings in /usr/lib/node_modules/n8n/node_modules/sqlite3 do not match the correct CPU architecture, which is likely to happen if either the folder is copied from another machine, or if some other process on the machine is messing up the compiled bindings.
If it’s the first option, then the solution is to always install directly on the machine using npm -g install n8n.
If it’s the second thing, then using a docker container would be better.
Apparently, this is because I opened the sqlite3 file on my computer and then uploaded it back (replacing the original). Is there a way to reconcile the sqlite3 file with the virtual server now, or do I need to reinstall n8n?