Forum Discussion

Salahuddin1's avatar
Salahuddin1
Icon for Nimbostratus rankNimbostratus
Nov 08, 2019

NPM Package Installation Error

Hi everyone!

 

I wanted to ask about an error which I have encountered. It has to something with file system being only read - only. I have shared the error below. Anyone kind of help will be highly appreciated.

 

npm ERR! Linux 3.10.0-514.26.2.el7.ve.x86_64

npm ERR! argv "/usr/bin/node" "/usr/bin/.npm__" "install" "-g" "feo" "--save"

npm ERR! node v6.9.1

npm ERR! npm v3.10.8

npm ERR! path /usr/lib/node_modules

npm ERR! code EROFS

npm ERR! errno -30

npm ERR! syscall access

 

npm ERR! rofs EROFS: read-only file system, access '/usr/lib/node_modules'

npm ERR! rofs This is most likely not a problem with npm itself

npm ERR! rofs and is related to the file system being read-only.

npm ERR! rofs

npm ERR! rofs Often virtualized file systems, or other file systems

npm ERR! rofs that don't support symlinks, give this error.

 

npm ERR! Please include the following file with any support request:

npm ERR!   /var/ilx/workspaces/Common/ilxws_Demo/extensions/ilxex_Demo/npm-debug.log

 

 

 

2 Replies

  • i assume you are trying to install npm on a F5 BIG-IP? is this based on some manual, article or such?

     

    in principle installation of software on the linux layer isn't supported, so if it doesn't work i would just not do it.

     

    you can probably remove the read only part, but chance is you break the BIG-IP.

  • You can install npm modules on BIG-IP but with some restrictions.

     

    1) No -g option. The option attempts to install the module under /usr/lib/node_module but the filesystem is read-only. This is the reason why you got the "EROFS: read-only file system, access '/usr/lib/node_modules'" message. Try without -g under the extension directory under the workspace directory. See also Getting Started with iRules LX, Part 4: NPM & Best Practices for the exact steps.

     

    2) No C/C++ code. Some node modules have C/C++ components which require compilation. BIG-IP does not have development environment. If you see "stack Error: `make` failed with exit code: 2" error, that's the case. Seems like you attempted to install 'feo', which requires to compile iconv. You need to find a pure Node.js module with similar functionalities.

     

    3) No symlink. Some node modules contain symlink inside. Creating a symbolic link under the workspace directory is prohibited. Expand the npm locally and if this is the case, try --no-bin-links option. See also the npm-install man page.