1

I'm trying to update my node.js version following this tutorial: https://desertbot.io/blog/nodejs-git-and-pm2-headless-raspberry-pi-install

But at the command:

sudo cp -R node-v11.15.0-linux-armv6l/* /usr/local/

I'm getting this error:

cp: cannot create regular file '/usr/local/bin/node': Text file busy

I've searched around the internet for solutions, but didn't find any. I also tried to use "mv" like:

sudo mv node-v11.15.0-linux-armv6l/* /usr/local/

But then I'm getting these errors:

mv: cannot move 'node-v11.15.0-linux-armv6l/bin' to '/usr/local/bin': Directory not empty
mv: cannot move 'node-v11.15.0-linux-armv6l/include' to '/usr/local/include': Directory not empty
mv: cannot move 'node-v11.15.0-linux-armv6l/lib' to '/usr/local/lib': Directory not empty
mv: cannot move 'node-v11.15.0-linux-armv6l/share' to '/usr/local/share': Directory not empty

All I really just want to, is to update the node.js version

0

1 Answer 1

1

Ok. This made it work:

wget https://nodejs.org/dist/v8.10.0/node-v8.10.0-linux-armv6l.tar.xz

cd /usr/local

sudo tar xf ~/node-v8.10.0-linux-armv6l.tar.xz --strip=1

rm -rf node-v*

I not sure why. Seems like the above code extracts the content in the right folder instead of doing af copy / paste

2
  • 1
    Please accept your own answer with a click on the tick on its left side. Only this will finish the question and it will not pop up again year for year.
    – Ingo
    Commented Apr 12, 2020 at 21:19
  • @Ingo Sure! Was just waiting as you can’t press it immediately m. Thanks for reminding me Commented Apr 13, 2020 at 6:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.