4 months ago
rm: cannot remove 'node_modules/.cache': Device or resource busy
npm warn config production Use --omit=dev
instead.
npm warn EBADENGINE Unsupported engine {
npm warn EBADENGINE package: 'react-router@7.6.0',
npm warn EBADENGINE required: { node: '>=20.0.0' },
npm warn EBADENGINE current: { node: 'v18.20.5', npm: '10.8.2' }
npm warn EBADENGINE }
npm warn EBADENGINE Unsupported engine {
npm warn EBADENGINE package: 'react-router-dom@7.6.0',
npm warn EBADENGINE required: { node: '>=20.0.0' },
npm warn EBADENGINE current: { node: 'v18.20.5', npm: '10.8.2' }
npm warn EBADENGINE }
npm error code EBUSY
npm error syscall rmdir
npm error path /app/node_modules/.cache
npm error errno -16
npm error EBUSY: resource busy or locked, rmdir '/app/node_modules/.cache'
npm error A complete log of this run can be found in: /root/.npm/_logs/2025-05-11T10_52_08_105Z-debug-0.log
3 Replies
4 months ago
This thread has been marked as public for community involvement, as it does not contain any sensitive or personal information. Any further activity in this thread will be visible to everyone.
Status changed to Open brody • 5 months ago
4 months ago
From the error messages you shared, it seems you're using a node version that isn't supported by the current version of react-router you're using. You can change the node version by specifying it in your package.json
file, in this case any version above node v20.
Something like this:
{
...
"engines": {
"node": ">=20.0.0"
}
}
4 months ago
rm: cannot remove 'node_modules/.cache': Device or resource busy
Have you maybe commited your node_modules
folder to the git repo?
This error usually shows up when the folder has some local read/write permissions applied and is commited. The server has no permissions to the folder.
4 months ago
I want to hire someone for this. Any recommendations?