• About Us
  • Disclaimers
  • Privacy Policy
  • Sitemap
Linux Tutorials for Beginners
Advertisement
  • Ubuntu
    Install and Secure phpMyAdmin on Ubuntu 22.04

    How To Install and Secure phpMyAdmin on Ubuntu 22.04

    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Ubuntu 22.04

    Install Uptime Kuma on Ubuntu 22.04

    How To Install Uptime Kuma on Ubuntu 22.04

    Install Ubuntu Server 22.04

    How To Install Ubuntu Server 22.04 LTS with Screenshots

    Set Up Firewall on Ubuntu 22.04

    How To Set Up a Firewall with UFW on Ubuntu 22.04

    Install Nginx on Ubuntu

    How To Install Nginx on Ubuntu 22.04: A Comprehensive Guide

    Install MySQL 8.0 on Ubuntu 22.04

    How To Install MySQL 8.0 on Ubuntu Server 22.04

    install-php74-ubuntu2204

    How To Install PHP 7.4 on Ubuntu 22.04

    Install Snipe-IT on Ubuntu 22.04

    How To Install Snipe-IT Asset Management on Ubuntu 22.04

  • Debian
    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Debian 11

    Install Debian 11 Server

    How To Install Debian 11 (Bullseye) Server with Pictures

    Install and Setup Node.js on Debian 11

    How To Install and Setup Node.js on Debian 11

    Install PHP 8.2 on Debian 11

    How To Install PHP 8.2 on Debian 11

    Install Nginx on Debian 11

    How To Install Nginx on Debian 11: A Comprehensive Guide

    Set Up Firewall with UFW on Debian

    How To Set Up a Firewall with UFW on Debian 11

    install php74 on debian 11

    How To Install PHP 7.4 on Debian 11

    Install MariaDB 10.9 on Debian 11

    How To Install MariaDB 10.9 on Debian 11 Server

    Initial Setup Debian Server

    Initial Setup Debian 11 Server: Secure and Efficient

  • Rocky Linux
    Install phpMyAdmin on Rocky Linux 9

    How To Install phpMyAdmin on Rocky Linux 9

    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Rocky Linux 9

    Install Rocky Linux 9.2 Server

    How To Install Rocky Linux 9.2 Server with Screenshots

    setup Firewall Using Firewalld Rocky Linux 9

    How To Set Up a Firewall Using FirewallD on Rocky Linux 9

    Install Nginx on Rocky Linux 9

    How To Install Nginx on Rocky Linux 9: A Comprehensive Guide

    Install Apache on Rocky Linux

    How To Install and Configure Apache on Rocky Linux 9

    Install MongoDB on Rocky Linux 9

    How To Install MongoDB 6.0 on Rocky Linux 9

    Install Docker on Rocky Linux

    How To Install Docker CE on Rocky Linux 9

  • CentOS
    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on CentOS 7

    Install PHP8.2 on CentOS 7

    How To Install PHP 8.2 on CentOS 7 / RHEL 7

    Install Apache on CentOS 7

    How To Install Apache Web Server on CentOS 7

    Set Up FirewallD on CentOS 7

    How To Set Up a Firewall Using FirewallD on CentOS 7

    Initial Setup CentOS 7 Server

    Initial Setup CentOS 7 Server: Secure and Efficient

    Install Nginx on CentOS 7

    How To Install Nginx on CentOS 7: A Comprehensive Guide

    Build NGINX from Source on Centos 7

    How To Build NGINX from Source (Compile) on Centos7

    Install Docker Swarm on CentOS 7

    Install and Configure Docker Swarm Mode on Centos 7

    Install Docker Compose on Centos 7

    How To Install and Use Docker Compose on Centos 7

  • Linux
    Manage Groups on Linux

    A Simple Guide: How To Manage Groups on Linux

    Logrotate In Linux

    How To Manage Log Files Using Logrotate In Linux

    Check File Size in Linux

    The Easy Ways to Check File Size in Linux

    Linux server security system administrators

    Best Practices Linux Server Security for System Administrator

    Backup Files From Remote Linux VPS Using Rsync Script

    How To Backup Files From Remote Linux VPS Using Rsync Script

    SSH Key-based Authentication

    How To Configure SSH Key-based Authentication In Linux

    Linux File Permissions

    Understanding Linux File Permissions for Beginners

    Create Multiboot USB with Ventoy

    How To Create Multiboot USB with Ventoy in Linux

    Find Hard Disk Drive Information in Linux

    How To Find Hard Disk Drive Information in Linux

No Result
View All Result
Linux Tutorials for Beginners
  • Ubuntu
    Install and Secure phpMyAdmin on Ubuntu 22.04

    How To Install and Secure phpMyAdmin on Ubuntu 22.04

    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Ubuntu 22.04

    Install Uptime Kuma on Ubuntu 22.04

    How To Install Uptime Kuma on Ubuntu 22.04

    Install Ubuntu Server 22.04

    How To Install Ubuntu Server 22.04 LTS with Screenshots

    Set Up Firewall on Ubuntu 22.04

    How To Set Up a Firewall with UFW on Ubuntu 22.04

    Install Nginx on Ubuntu

    How To Install Nginx on Ubuntu 22.04: A Comprehensive Guide

    Install MySQL 8.0 on Ubuntu 22.04

    How To Install MySQL 8.0 on Ubuntu Server 22.04

    install-php74-ubuntu2204

    How To Install PHP 7.4 on Ubuntu 22.04

    Install Snipe-IT on Ubuntu 22.04

    How To Install Snipe-IT Asset Management on Ubuntu 22.04

  • Debian
    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Debian 11

    Install Debian 11 Server

    How To Install Debian 11 (Bullseye) Server with Pictures

    Install and Setup Node.js on Debian 11

    How To Install and Setup Node.js on Debian 11

    Install PHP 8.2 on Debian 11

    How To Install PHP 8.2 on Debian 11

    Install Nginx on Debian 11

    How To Install Nginx on Debian 11: A Comprehensive Guide

    Set Up Firewall with UFW on Debian

    How To Set Up a Firewall with UFW on Debian 11

    install php74 on debian 11

    How To Install PHP 7.4 on Debian 11

    Install MariaDB 10.9 on Debian 11

    How To Install MariaDB 10.9 on Debian 11 Server

    Initial Setup Debian Server

    Initial Setup Debian 11 Server: Secure and Efficient

  • Rocky Linux
    Install phpMyAdmin on Rocky Linux 9

    How To Install phpMyAdmin on Rocky Linux 9

    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on Rocky Linux 9

    Install Rocky Linux 9.2 Server

    How To Install Rocky Linux 9.2 Server with Screenshots

    setup Firewall Using Firewalld Rocky Linux 9

    How To Set Up a Firewall Using FirewallD on Rocky Linux 9

    Install Nginx on Rocky Linux 9

    How To Install Nginx on Rocky Linux 9: A Comprehensive Guide

    Install Apache on Rocky Linux

    How To Install and Configure Apache on Rocky Linux 9

    Install MongoDB on Rocky Linux 9

    How To Install MongoDB 6.0 on Rocky Linux 9

    Install Docker on Rocky Linux

    How To Install Docker CE on Rocky Linux 9

  • CentOS
    Secure SSH with Fail2Ban

    How To Secure SSH with Fail2Ban on CentOS 7

    Install PHP8.2 on CentOS 7

    How To Install PHP 8.2 on CentOS 7 / RHEL 7

    Install Apache on CentOS 7

    How To Install Apache Web Server on CentOS 7

    Set Up FirewallD on CentOS 7

    How To Set Up a Firewall Using FirewallD on CentOS 7

    Initial Setup CentOS 7 Server

    Initial Setup CentOS 7 Server: Secure and Efficient

    Install Nginx on CentOS 7

    How To Install Nginx on CentOS 7: A Comprehensive Guide

    Build NGINX from Source on Centos 7

    How To Build NGINX from Source (Compile) on Centos7

    Install Docker Swarm on CentOS 7

    Install and Configure Docker Swarm Mode on Centos 7

    Install Docker Compose on Centos 7

    How To Install and Use Docker Compose on Centos 7

  • Linux
    Manage Groups on Linux

    A Simple Guide: How To Manage Groups on Linux

    Logrotate In Linux

    How To Manage Log Files Using Logrotate In Linux

    Check File Size in Linux

    The Easy Ways to Check File Size in Linux

    Linux server security system administrators

    Best Practices Linux Server Security for System Administrator

    Backup Files From Remote Linux VPS Using Rsync Script

    How To Backup Files From Remote Linux VPS Using Rsync Script

    SSH Key-based Authentication

    How To Configure SSH Key-based Authentication In Linux

    Linux File Permissions

    Understanding Linux File Permissions for Beginners

    Create Multiboot USB with Ventoy

    How To Create Multiboot USB with Ventoy in Linux

    Find Hard Disk Drive Information in Linux

    How To Find Hard Disk Drive Information in Linux

No Result
View All Result
Linux Tutorials for Beginners
No Result
View All Result

Home » Rocky Linux » How To Install Node.js on Rocky Linux 9 With 3 Different Ways

How To Install Node.js on Rocky Linux 9 With 3 Different Ways

sammbysamm
October 17, 2023
Install Node.js on Rocky Linux

How To Install Node.js on Rocky Linux 9 With 3 Different Ways

Share on FacebookShare on LinkedinShare on Whatsapp

Introduction of Node.js

Node.js is a powerful JavaScript runtime environment that is widely used for server-side and web development. At the present time Node.js has revolutionized web development with its versatile capabilities and efficient runtime environment. If you’re running an Rocky Linux 9 and want to harness the power of Node.js for your web projects, for that reason this step-by-step guide will walk you through how to install Node.js on Rocky Linux 9 With 3 Different Ways.

As I have said, we’ll take you step by step through the process of installing Node.js on Rocky Linux 9. We’ll cover three different methods: the Default repository, the NodeSource repository, and the Node Version Manager (NVM).

OTHER POSTS

How To Install phpMyAdmin on Rocky Linux 9

How To Secure SSH with Fail2Ban on Rocky Linux 9

How To Install Rocky Linux 9.2 Server with Screenshots

Table of Contents

  • Introduction of Node.js
  • Prerequisites for Install Node.js
    • System Update for Install Node.js
    • Method 1: Install Node.js with dnf from the Default Repositories
      • Install Node.js with Default Repositories
      • Verify Node.js Installation
    • Method 2: Install Node.js Using the NodeSource Repository
      • Add the NodeSource Repository:
      • Install Node.js Using the NodeSource
      • Verify Node.js Installation
    • Method 3: Install Node.js Using the Node Version Manager
      • Install NVM
      • Source NVM
      • Install Node.js with NVM
      • Verify Node.js Installation
  • Conclusion

Node.js has become incredibly popular for modern web development, especially for applications requiring real-time interactions, such as chat applications, streaming services, and online gaming platforms. Even more Its performance, scalability, and extensive package ecosystem have made it a favorite among developers for building a wide range of applications and services.

Prerequisites for Install Node.js

Important to realize this guide assumes that you are using Rocky Linux 9 for install Node.js. Before you begin, you should have a non-root user account with sudo privileges set up on your system. You can learn how to do this by following below tutorial :

  • Initial Setup Rocky Linux 9 Server: Secure and Efficient

System Update for Install Node.js

Basically It’s always a good practice to start by updating your package repository and upgrading installed packages to their latest versions. Update the package lists by running the following command:

Bash
[samm@node-js ~]$ sudo dnf update -y

[samm@node-js ~]$ sudo dnf upgrade --refresh
Extra Packages for Enterprise Linux 9 - x86_64                                                                                                                                     9.5 kB/s | 6.5 kB     00:00    
Extra Packages for Enterprise Linux 9 - x86_64                                                                                                                                     4.5 MB/s |  18 MB     00:04    
Rocky Linux 9 - BaseOS                                                                                                                                                             2.1 kB/s | 4.1 kB     00:01    
Rocky Linux 9 - AppStream                                                                                                                                                          3.3 kB/s | 4.5 kB     00:01    
Rocky Linux 9 - Extras                                                                                                                                                             1.8 kB/s | 2.9 kB     00:01    
Dependencies resolved.
Nothing to do.
Complete!

[samm@node-js ~]$ sudo dnf install dnf-utils

In this guide, given these points you will review three different ways of getting Node.js installed on a Rocky Linux 9 server:

  • Using dnf to install the nodejs package from Rocky’s default software repository.
  • Using dnf with the Nodesource software repository to install specific versions of the nodejs package
  • Installing nvm, the Node Version Manager, and using it to install and manage multiple versions of Node.js

Method 1: Install Node.js with dnf from the Default Repositories

Basically Rocky Linux 9 contains a version of Node.js in its default repositories that can be used to provide a consistent experience across multiple systems. At this time of writing, the version in the repositories is v16.19.1. This will not be the latest version, but it should be stable and sufficient for quick experimentation with the language.

Install Node.js with Default Repositories

To get this version, you can use the dnf package manager by running the following command:

Bash
[samm@node-js ~]$ sudo dnf install nodejs -y
Last metadata expiration check: 0:54:33 ago on Fri 28 Jul 2023 07:05:11 PM WIB.
Dependencies resolved.
===================================================================================================================================================================================================================
 Package                                             Architecture                              Version                                                          Repository                                    Size
===================================================================================================================================================================================================================
Installing:
 nodejs                                              x86_64                                    1:16.19.1-2.el9_2                                                appstream                                    111 k
Installing dependencies:
 nodejs-libs                                         x86_64                                    1:16.19.1-2.el9_2                                                appstream                                     14 M
Installing weak dependencies:
 nodejs-docs                                         noarch                                    1:16.19.1-2.el9_2                                                appstream                                    7.0 M
 nodejs-full-i18n                                    x86_64                                    1:16.19.1-2.el9_2                                                appstream                                    8.2 M
 npm                                                 x86_64                                    1:8.19.3-1.16.19.1.2.el9_2                                       appstream                                    1.7 M

Transaction Summary
===================================================================================================================================================================================================================
Install  5 Packages

Total download size: 32 M
Installed size: 168 M

Verify Node.js Installation

Then check the install was successful by querying node for its version number:

Bash
[samm@node-js ~]$ node -v

Output

Bash
v16.19.1

If the package in the repositories suits your needs, then this is all you need to do to get set up with Node.js. The Node.js package from Rocky’s default repositories also comes with npm, the Node.js package manager.

At this point you have successfully installed Node.js and npm using dnf and the default Rocky software repositories. Henceforth the next section will show you how to use an alternate repository to install different versions of Node.js.

Method 2: Install Node.js Using the NodeSource Repository

In another case to install a different version of Node.js, you can use the NodeSource repository.

Add the NodeSource Repository:

First, you’ll need to configure the repository locally, in order to get access to its packages.

Bash
[samm@node-js ~]$ curl -sL https://rpm.nodesource.com/setup_18.x -o nodesource_setup.sh

In detail about the available versions, check out the NodeSource documentation.

Now, run the script with sudo using following command:

Bash
[samm@node-js ~]$ sudo bash nodesource_setup.sh

Then you should see the output similar to the following:

Bash
## Installing the NodeSource Node.js 18.x repo...


## Inspecting system...

+ uname -m
rocky-release-9.2-1.6.el9.noarch
exec redhat-release
Release package: rocky-release-9.2-1.6.el9.noarch

## Confirming "el9-x86_64" is supported...

+ curl -sLf -o /dev/null 'https://rpm.nodesource.com/pub_18.x/el/9/x86_64/nodesource-release-el9-1.noarch.rpm'

## Downloading release setup RPM...

+ mktemp
+ curl -sL -o '/tmp/tmp.RYY47cxmpV' 'https://rpm.nodesource.com/pub_18.x/el/9/x86_64/nodesource-release-el9-1.noarch.rpm'

## Installing release setup RPM...

+ rpm -i --nosignature --force '/tmp/tmp.RYY47cxmpV'

## Cleaning up...

+ rm -f '/tmp/tmp.RYY47cxmpV'

## Checking for existing installations...

+ rpm -qa 'node|npm' | grep -v nodesource

## Your system appears to already have Node.js installed from an alternative source.
Run `sudo yum remove -y nodejs npm` to remove these first.

## Run `sudo yum install -y nodejs` to install Node.js 18.x and npm.
## You may run dnf if yum is not available:
     sudo dnf install -y nodejs
## You may also need development tools to build native addons:
     sudo yum install gcc-c++ make
## To install the Yarn package manager, run:
     curl -sL https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo
     sudo yum install yarn

Install Node.js Using the NodeSource

At this point the repository will be added to your configuration and your local package cache will be updated automatically. You can now install the Node.js package in the same way you did in the previous section. It may be a good idea to fully remove your older Node.js packages before installing the new version, by using sudo dnf remove nodejs npm.

This won’t change your settings in any way; but only update the installed software versions. Must be remembered that third-party repositories may not always package their software in a manner that seamlessly upgrades over the default packages. If you encounter any issues, for this reason you can always go back to the original, unmodified setup as a fallback option.

Use following command:

Bash
[samm@node-js ~]$ sudo dnf remove nodejs npm -y
Dependencies resolved.
===================================================================================================================================================================================================================
 Package                                             Architecture                              Version                                                         Repository                                     Size
===================================================================================================================================================================================================================
Removing:
 nodejs                                              x86_64                                    1:16.19.1-2.el9_2                                               @appstream                                    369 k
 npm                                                 x86_64                                    1:8.19.3-1.16.19.1.2.el9_2                                      @appstream                                    6.5 M
Removing unused dependencies:
 nodejs-docs                                         noarch                                    1:16.19.1-2.el9_2                                               @appstream                                     76 M
 nodejs-full-i18n                                    x86_64                                    1:16.19.1-2.el9_2                                               @appstream                                     29 M
 nodejs-libs                                         x86_64                                    1:16.19.1-2.el9_2                                               @appstream                                     56 M

Transaction Summary
===================================================================================================================================================================================================================
Remove  5 Packages

Freed space: 168 M
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                                                                                           1/1 
  Erasing          : nodejs-1:16.19.1-2.el9_2.x86_64                                                                                                                                                           1/5 
  Erasing          : npm-1:8.19.3-1.16.19.1.2.el9_2.x86_64                                                                                                                                                     2/5 
  Erasing          : nodejs-docs-1:16.19.1-2.el9_2.noarch                                                                                                                                                      3/5 
  Erasing          : nodejs-full-i18n-1:16.19.1-2.el9_2.x86_64                                                                                                                                                 4/5 
  Erasing          : nodejs-libs-1:16.19.1-2.el9_2.x86_64                                                                                                                                                      5/5 
  Running scriptlet: nodejs-libs-1:16.19.1-2.el9_2.x86_64                                                                                                                                                      5/5 
  Verifying        : nodejs-1:16.19.1-2.el9_2.x86_64                                                                                                                                                           1/5 
  Verifying        : nodejs-docs-1:16.19.1-2.el9_2.noarch                                                                                                                                                      2/5 
  Verifying        : nodejs-full-i18n-1:16.19.1-2.el9_2.x86_64                                                                                                                                                 3/5 
  Verifying        : nodejs-libs-1:16.19.1-2.el9_2.x86_64                                                                                                                                                      4/5 
  Verifying        : npm-1:8.19.3-1.16.19.1.2.el9_2.x86_64                                                                                                                                                     5/5 

Removed:
  nodejs-1:16.19.1-2.el9_2.x86_64     nodejs-docs-1:16.19.1-2.el9_2.noarch     nodejs-full-i18n-1:16.19.1-2.el9_2.x86_64     nodejs-libs-1:16.19.1-2.el9_2.x86_64     npm-1:8.19.3-1.16.19.1.2.el9_2.x86_64    

Complete!

After fully remove your older Node.js packages, then install the new version of Node.js

Bash
[samm@node-js ~]$ sudo dnf install nodejs -y
Node.js Packages for Enterprise Linux 9 - x86_64                                                                                                                                   2.2 MB/s | 623 kB     00:00    
Dependencies resolved.
===================================================================================================================================================================================================================
 Package                                       Architecture                                  Version                                                       Repository                                         Size
===================================================================================================================================================================================================================
Installing:
 nodejs                                        x86_64                                        2:18.17.0-1nodesource                                         nodesource                                         34 M

Transaction Summary
===================================================================================================================================================================================================================
Install  1 Package

Total download size: 34 M
Installed size: 100 M
Downloading Packages:
nodejs-18.17.0-1nodesource.x86_64.rpm                                                                                                                                              4.4 MB/s |  34 MB     00:07    
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                                              4.4 MB/s |  34 MB     00:07     
Node.js Packages for Enterprise Linux 9 - x86_64                                                                                                                                   1.6 MB/s | 1.6 kB     00:00    
Importing GPG key 0x34FA74DD:
 Userid     : "NodeSource <[email protected]>"
 Fingerprint: 2E55 207A 95D9 944B 0CC9 3261 5DDB E8D4 34FA 74DD
 From       : /etc/pki/rpm-gpg/NODESOURCE-GPG-SIGNING-KEY-EL
Key imported successfully
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                                                                                           1/1 
  Running scriptlet: nodejs-2:18.17.0-1nodesource.x86_64                                                                                                                                                       1/1 
  Installing       : nodejs-2:18.17.0-1nodesource.x86_64                                                                                                                                                       1/1 
  Running scriptlet: nodejs-2:18.17.0-1nodesource.x86_64                                                                                                                                                       1/1 
  Verifying        : nodejs-2:18.17.0-1nodesource.x86_64                                                                                                                                                       1/1 

Installed:
  nodejs-2:18.17.0-1nodesource.x86_64                                                                                                                                                                              

Complete!

Verify Node.js Installation

After that verify that you’ve installed the new version. by running node with the -v version flag:

Bash
[samm@node-js ~]$ node -v

Output

Bash
v18.17.0

The NodeSource nodejs package contains both the node binary and npm, so you don’t need to install npm separately.

At this point you have successfully installed Node.js and npm using dnf and the NodeSource repository. Finally the next section will show how to use the Node Version Manager to install and manage multiple versions of Node.js.

Method 3: Install Node.js Using the Node Version Manager

Another way of installing Node.js that is particularly flexible is to use nvm, the Node Version Manager. This piece of software allows you to install and maintain many different independent versions of Node.js, and their associated Node packages, at the same time.

Install NVM

Before piping the command through to bash, it is always a good idea to audit the script to make sure it isn’t doing anything you don’t agree with. You can do that by removing the | bash segment at the end of the curl command:

Bash
[samm@node-js ~]$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh

With the result that, review the modifications it’s introducing and make sure you feel at ease with them.. When you are satisfied, run the command again with | bash added at the end. The URL you use will change depending on the latest version of nvm, but as of right now, the script can be downloaded and executed by typing:

Bash
[samm@node-js ~]$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash

After that this will install the nvm script to your user account.

Source NVM

In order that to use it. You must first source your .bashrc file:

Bash
[samm@node-js ~]$ source ~/.bashrc

Now, you can ask NVM which versions of Node are available by using following command:

Bash
Output
. . .
       v18.11.0
       v18.12.0   (LTS: Hydrogen)
       v18.12.1   (LTS: Hydrogen)
       v18.13.0   (LTS: Hydrogen)
       v18.14.0   (LTS: Hydrogen)
       v18.14.1   (LTS: Hydrogen)
       v18.14.2   (LTS: Hydrogen)
       v18.15.0   (LTS: Hydrogen)
       v18.16.0   (LTS: Hydrogen)
       v18.16.1   (LTS: Hydrogen)
       v18.17.0   (Latest LTS: Hydrogen)
       v19.0.0
       v19.0.1
. . .

As can be seen it’s a very long list! Afterwards you can install a version of Node by typing any of the release versions you see.

Install Node.js with NVM

For instance, to get version v18.17.0 (an LTS release), you can type:

Bash
[samm@node-js ~]$ nvm install v18.17.0

You should then see the output similar to the following:

Bash
Downloading and installing node v18.17.0...
Downloading https://nodejs.org/dist/v18.17.0/node-v18.17.0-linux-x64.tar.xz...
############################################################################################################################################################################################################ 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v18.17.0 (npm v9.6.7)

Verify Node.js Installation

You can see the different versions you have installed by typing following command:

Bash
[samm@node-js ~]$ nvm list

->     v18.17.0
         system
default -> v18.17.0
iojs -> N/A (default)
unstable -> N/A (default)
node -> stable (-> v18.17.0) (default)
stable -> 18.17 (-> v18.17.0) (default)
lts/* -> lts/hydrogen (-> v18.17.0)
lts/argon -> v4.9.1 (-> N/A)
lts/boron -> v6.17.1 (-> N/A)
lts/carbon -> v8.17.0 (-> N/A)
lts/dubnium -> v10.24.1 (-> N/A)
lts/erbium -> v12.22.12 (-> N/A)
lts/fermium -> v14.21.3 (-> N/A)
lts/gallium -> v16.20.1 (-> N/A)
lts/hydrogen -> v18.17.0

This shows the currently active version on the first line (-> v18.17.0), followed by some named aliases and the versions that those aliases point to.

Conclusion

Finally Congratulations! You’ve install Node.js with a few ways on your Rocky Linux 9. Thus you’re now ready to develop and deploy powerful web applications using Node.js. First thing to remember this installation provides a solid foundation for creating high-performance websites, and you’re well on your way to leveraging the capabilities of this powerful runtime. Happy coding!

Also Read Our Other Guides :

  • How To Install Node.js on Ubuntu 22.04 With 3 Different Ways
  • How To Install and Setup Node.js on Debian 11
  • How To Use Git Version Control on Linux: For Beginner
  • How To Install and Config Git on Ubuntu 22.04
  • How To Install Jenkins on Ubuntu 22.04
  • How To Install Python 3.11 from Source on Ubuntu 22.04

As I have shown, now you have learned how to install Node.js on Rocky Linux 9 With 3 Different Ways.

Tags: ApplicationJavaJavascriptNodeJSProgramming LanguageRocky Linux

If you got help by our tutorials, please buy me a coffee..!

Buy Me a Coffee

Thank you so much for your support!!

Previous Post

How To Use Git Version Control on Linux: For Beginner

Next Post

Initial Setup Rocky Linux 9 Server: Secure and Efficient

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

RECENT POST

Install and Secure phpMyAdmin on Ubuntu 22.04

How To Install and Secure phpMyAdmin on Ubuntu 22.04

by samm
July 22, 2024
0

Are you ready to take control of your MySQL databases on Ubuntu 22.04? In this step-by-step guide, we'll walk you...

Manage Groups on Linux

A Simple Guide: How To Manage Groups on Linux

by samm
November 12, 2023
0

Are you a Linux enthusiast looking to enhance your system administration skills? One fundamental aspect you should master is how...

Install phpMyAdmin on Rocky Linux 9

How To Install phpMyAdmin on Rocky Linux 9

by samm
November 11, 2023
0

If you're navigating the world of Rocky Linux 9 and looking to streamline your MariaDB or MySQL database management, installing...

Logrotate In Linux

How To Manage Log Files Using Logrotate In Linux

by samm
November 10, 2023
0

Log files are an essential part of any Linux system. They provide valuable insights into the system's activities, helping administrators...

Load More

RECOMMENDED.

Install Redis on Debian

How To Install Redis on Debian 11 Server

October 16, 2023
Secure SSH with Fail2Ban

How To Secure SSH with Fail2Ban on Rocky Linux 9

October 29, 2023
sammlinux sammlinux sammlinux

Related Posts

Install phpMyAdmin on Rocky Linux 9
Rocky Linux

How To Install phpMyAdmin on Rocky Linux 9

November 11, 2023
Secure SSH with Fail2Ban
Rocky Linux

How To Secure SSH with Fail2Ban on Rocky Linux 9

October 29, 2023
Install Rocky Linux 9.2 Server
Rocky Linux

How To Install Rocky Linux 9.2 Server with Screenshots

October 20, 2023
setup Firewall Using Firewalld Rocky Linux 9
Rocky Linux

How To Set Up a Firewall Using FirewallD on Rocky Linux 9

October 18, 2023
Load More
Next Post
Initial Setup Rocky Linux 9

Initial Setup Rocky Linux 9 Server: Secure and Efficient

  • About Us
  • Disclaimers
  • Privacy Policy
  • Sitemap

© 2023 sammlinux - Learn Today for Lead Tomorrow.

No Result
View All Result
  • Ubuntu
  • Debian
  • Rocky Linux
  • CentOS
  • Linux

© 2023 sammlinux - Learn Today for Lead Tomorrow.