[root@MiWiFi-R3P-srv hao]# npm install sqlite3
npm WARN deprecated @npmcli/move-file@1.1.2: This functionality has been moved to @npmcli/fs
npm ERR! code 1
npm ERR! path /www/wwwroot/hao/node_modules/sqlite3
npm ERR! command failed
npm ERR! command sh -c node-pre-gyp install --fallback-to-build
npm ERR! Failed to execute ‘/www/server/nodejs/v16.18.1/bin/node /www/server/nodejs/v16.18.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/www/wwwroot/hao/node_modules/sqlite3/lib/binding/napi-v6-linux-glibc-arm64/node_sqlite3.node --module_name=node_sqlite3 --module_path=/www/wwwroot/hao/node_modules/sqlite3/lib/binding/napi-v6-linux-glibc-arm64 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6’ (1)
npm ERR! node-pre-gyp info it worked if it ends with ok
npm ERR! node-pre-gyp info using node-pre-gyp@1.0.10
npm ERR! node-pre-gyp info using node@16.18.1 | linux | arm64
npm ERR! node-pre-gyp info check checked for “/www/wwwroot/hao/node_modules/sqlite3/lib/binding/napi-v6-linux-glibc-arm64/node_sqlite3.node” (not found)
npm ERR! node-pre-gyp http GET https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-glibc-arm64.tar.gz
npm ERR! node-pre-gyp ERR! install request to https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-glibc-arm64.tar.gz failed, reason: connect ETIMEDOUT 20.205.243.166:443
npm ERR! node-pre-gyp WARN Pre-built binaries not installable for sqlite3@5.1.2 and node@16.18.1 (node-v93 ABI, glibc) (falling back to source compile with node-gyp)
npm ERR! node-pre-gyp WARN Hit error request to https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-glibc-arm64.tar.gz failed, reason: connect ETIMEDOUT 20.205.243.166:443
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.3.0
npm ERR! gyp info using node@16.18.1 | linux | arm64
npm ERR! gyp info ok
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.3.0
npm ERR! gyp info using node@16.18.1 | linux | arm64
npm ERR! gyp ERR! find Python
npm ERR! gyp ERR! find Python Python is not set from command line or npm configuration
npm ERR! gyp ERR! find Python Python is not set from environment variable PYTHON
npm ERR! gyp ERR! find Python checking if “python3” can be used
npm ERR! gyp ERR! find Python - “python3” is not in PATH or produced an error
npm ERR! gyp ERR! find Python checking if “pyt
npm install sqlite3 --save 报错
于 2022-11-26 02:12:47 首次发布
在Linux环境中,使用npm install sqlite3命令时遇到了ETIMEDOUT错误,尝试了更新npm、使用sudo等方法未果。进一步的排查发现是系统中GLIBCXX版本过低导致的问题。通过升级GCC至8.3.0版本,成功解决了GLIBCXX_1.3.8缺失的问题,从而完成了sqlite3的安装。
摘要由CSDN通过智能技术生成