afgoody
Posts: 3
Joined: Sun Jan 27, 2019 3:44 pm

Insufficient Space on NPM Install

Sun Jan 27, 2019 4:33 pm

Hello,
My project is to install https://github.com/tagyoureit/nodejs-poolController and I'm trying to follow the Installation Instructions listed a little bit down from the top. I've pasted them here:

If you don't know anything about NodeJS, these directions might be helpful.

1) Install Nodejs. (https://nodejs.org/en/download/)
2) Update NPM (https://docs.npmjs.com/getting-started/installing-node).
3) Download the latest code release OR clone with git clone [email protected]:tagyoureit/nodejs-poolController.git
4) Unzip into nodejs-poolController.
5) Run 'npm install' in the new folder (where package.json exists). This will automatically install all the dependencies (serial-port, express, sockets.io, etc).
6) Run the app by calling 'npm start'* (again, in the root directory). It should now run properly.
to run with a specific configuration, run node index.js arg where arg is the name of your current config file. eg npm start configCustomized.json. By default, the app will load config.json.


For step 4, I used my Windows 10 machine to unzip the files into a folder 'nodejs-poolController-5.3.0' in the /boot directory since that is the only directory I could see after using Etcher to write the Raspbian Stretch Lite image to my 32 GB SD card. I did receive one Etcher verification failure message (
1EtcherVerificationFail.JPG
1EtcherVerificationFail.JPG (26.14 KiB) Viewed 338 times
), so I tried it again starting with another format and received the same verification message, so I proceeded and was able to boot and continue via SSH and putty.

In step 5, I navigated to that folder and try to run 'npm install,' but get an error about permissions, so I ran 'sudo npm install,' but then got two messages about deprecation (#2 attached below) and then it appears to try and do the install, but then I get 100s of these messages:

npm WARN tar EPERM: operation not permitted, fchown

Then a bunch of ‘no space left on device, write’ and ‘no such file or directory…” messages and this at the end:

npm ERR! path /boot/nodejs-poolController-5.3.0/node_modules/.staging/snyk-go-plugin-f3127165
npm ERR! code ENOSPC
npm ERR! errno -28
npm ERR! syscall mkdir
npm ERR! nospc ENOSPC: no space left on device, mkdir '/boot/nodejs-poolController-5.3.0/node_modules/.staging/snyk-go-plugin-f3127165'
npm ERR! nospc There appears to be insufficient space on your system to finish.
npm ERR! nospc Clear up some disk space and try again.


So, it seemed like I needed to make more space on the disk, so I tried this https://raspberrypi.stackexchange.com/q ... -partition, and tried the 'sudo npm install' again, but received the same error messages. Then, I started looking at this forum and found the 26 pitfalls sticky and tried Step 15 https://www.raspberrypi.org/forums/view ... 45#p664906 (#3 attached below), and tried the 'sudo npm install' again, but received the same error messages still.

So, I'm kind of stuck. I appreciate any help anyone can provide.

Thank you.
Attachments
3ExpandRoot.JPG
3ExpandRoot.JPG (200.48 KiB) Viewed 336 times
2NPMInstallStepsDeprecationErrors.JPG
2NPMInstallStepsDeprecationErrors.JPG (134.62 KiB) Viewed 336 times

afgoody
Posts: 3
Joined: Sun Jan 27, 2019 3:44 pm

Re: Insufficient Space on NPM Install

Tue Jan 29, 2019 4:18 am

Does anyone have a recommendation?

Thank you

User avatar
rpdom
Posts: 14688
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Insufficient Space on NPM Install

Tue Jan 29, 2019 4:40 am

Move the file out of /boot before running the install. Put it in /tmp or something like that.

Normally nodejs and npm would be installed using the standard package management tools, although that would give you a slightly older version than the current one due to the Debian philosophy regarding stable software.

Return to “Beginners”