You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using Grist on a FreeBSD server crashes with a SIGILL.
I suspect the crash is related to the modifications in the @gristlabs/sqlite3 fork of node-sqlite3 (I've used the latter myself, and it worked fine last I tested --- though it's been a while).
This happens on multiple FreeBSD versions. The database file itself is fine, as Grist runs properly when the same exact file is hosted in Linux.
The crash happens in multiple version of FreeBSD 13, as well as 14.
Steps to reproduce
Install Grist on FreeBSD, following the instructions on the website
Start grist using yarn start:prod or a similar method
Node also generates a core dump; I won't be uploading the whole thing as it's nearly 250MB, but at least a backtrace might be of help:
Core was generated by `/usr/local/bin/node _build/stubs/app/server/server.js'.
Program terminated with signal SIGILL, Illegal instruction.
Privileged opcode.
#0 0x000000085bb07f81 in Marshaller::_writeBytes(void const*, unsigned long) ()
from /usr/home/grist/grist-core/node_modules/@gristlabs/sqlite3/lib/binding/napi-v6-freebsd-unknown-x64/node_sqlite3.node
[Current thread is 1 (LWP 426848)]
(gdb) bt
#0 0x000000085bb07f81 in Marshaller::_writeBytes(void const*, unsigned long) ()
from /usr/home/grist/grist-core/node_modules/@gristlabs/sqlite3/lib/binding/napi-v6-freebsd-unknown-x64/node_sqlite3.node
#1 0x000000085bb107b6 in node_sqlite3::Statement::Work_AllMarshal(napi_env__*, void*) ()
from /usr/home/grist/grist-core/node_modules/@gristlabs/sqlite3/lib/binding/napi-v6-freebsd-unknown-x64/node_sqlite3.node
#2 0x00000000022ce924 in node::ThreadPoolWork::ScheduleWork()::{lambda(uv_work_s*)#1}::operator()(uv_work_s*) const ()
#3 0x00000000022ce7ff in node::ThreadPoolWork::ScheduleWork()::{lambda(uv_work_s*)#1}::__invoke(uv_work_s*) ()
#4 0x0000000826315519 in ?? () from /usr/local/lib/libuv.so.1
#5 0x000000082e7a4b05 in ?? () from /lib/libthr.so.3
#6 0x0000000000000000 in ?? ()
Backtrace stopped: Cannot access memory at address 0x860635000
The text was updated successfully, but these errors were encountered:
Hi @darkuranium, thanks for the report especially the backtrace! Your diagnosis looks correct, something funky in our patch to node-sqlite3 (in the "Marshaller"). cc @dsagal
If you were interested in debugging further, since you have the advantage of being on a FreeBSD setup, you could clone: https://github.com/gristlabs/node-sqlite3/
then do the following (might be slightly off, I find building this package a bit confusing and flail about every time):
npm install
npx node-pre-gyp configure
npm run build
npm run pretest
npm run test
Interested in whether you get a SIGILL during the tests.
Describe the current behavior
Using Grist on a FreeBSD server crashes with a SIGILL.
I suspect the crash is related to the modifications in the @gristlabs/sqlite3 fork of node-sqlite3 (I've used the latter myself, and it worked fine last I tested --- though it's been a while).
This happens on multiple FreeBSD versions. The database file itself is fine, as Grist runs properly when the same exact file is hosted in Linux.
The crash happens in multiple version of FreeBSD 13, as well as 14.
Steps to reproduce
yarn start:prod
or a similar methodDescribe the expected behavior
The application should not crash.
Where have you encountered this bug?
Instance information (when self-hosting only)
Grist instance:
yarn install
/yarn build:prod
Browser name, version and platforms on which you could reproduce the bug: any
Link to server log if relevant:
Node also generates a core dump; I won't be uploading the whole thing as it's nearly 250MB, but at least a backtrace might be of help:
The text was updated successfully, but these errors were encountered: