Control Web Panel

WebPanel => CentOS 7 Problems => Topic started by: baronnath on March 24, 2023, 03:10:14 AM

Title: Node installation
Post by: baronnath on March 24, 2023, 03:10:14 AM
Hi,

I'm trying to deploy my react website. I need to run npm once ssh connected, but I get the following error:
Code: [Select]
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.25' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
node: /lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by node)
node: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by node)
node: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by node)

I got that same error with command "node --version"
I already have installed node via web panel node.js manager, actually I have a nodejs api running in a subdomain with node 14.x version.

¿What am I missing to have node and npm available?
Title: Re: Node installation
Post by: baronnath on March 24, 2023, 04:09:51 PM
A collegue just helped me.

I just needed to execute node and npm from the path. In the nodejs manager version selection page, in the web control panel, there's a button to show the path where node was intalled.

So instead of just executing "npm whatever" I had to execute "/opt/nvm/versions/node/v14.21.3/bin/npm whatever"
Title: Re: Node installation
Post by: tiagocaus on July 28, 2023, 09:53:50 AM
A collegue just helped me.

I just needed to execute node and npm from the path. In the nodejs manager version selection page, in the web control panel, there's a button to show the path where node was intalled.

So instead of just executing "npm whatever" I had to execute "/opt/nvm/versions/node/v14.21.3/bin/npm whatever"

I'm new to CWP. do i have to do this every time i use a new version of nodejs?

Is there a way to send a print of the screen or video showing how to do it?
Title: Re: Node installation
Post by: Sandeep on July 28, 2023, 10:21:08 AM
officially nodejs 18 is not supported in centos 7 upgrade to lates el release.
Title: Re: Node installation
Post by: overseer on July 29, 2023, 08:02:40 PM
Time to ELevate to AlmaLinux 8.8...