Close Menu

    Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.

    What's Hot

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    October 6, 2024

    How to Install Python3 on Centos 7

    December 26, 2021

    Is your VPN safe ? – Part1

    April 15, 2021
    Facebook X (Twitter) Instagram
    • Technology
    • Gaming
    Facebook X (Twitter) Instagram Pinterest Vimeo
    Unix ZoneUnix Zone
    • Home
    • Categories
      • Featured
      • Inspiration
      • Article
    • Business
    Subscribe
    Unix ZoneUnix Zone
    Home»Breaking»How to install NodeJs on Centos 7
    Breaking

    How to install NodeJs on Centos 7

    adminBy adminMarch 31, 2021Updated:April 1, 2021No Comments2 Mins Read
    Share Facebook Twitter Pinterest LinkedIn Tumblr Reddit Telegram Email
    Share
    Facebook Twitter LinkedIn Pinterest Email

    Nodejs is considered a well-known programming language. And many developers use this language for developing their projects for its benefits. Nodejs, most of the time, are not installed on centos distributions, or an old version is installed, which is not enough or cannot satisfy the requirements of a project.

    In this tutorial, we will show how to install the latest version of Nodejs in two ways that can satisfy any circumstances.

    as the stable and long term support of Nodejs is 12 version, in this article, we will support version 12 for both methods.

    1.Installing from repository :

    1-1. Download the repository from Nodejs website with curl command and install it.

    curl -sL https://rpm.nodesource.com/setup_12.x | sudo bash -

    1-2. Install Nodejs package with below command.

    sudo yum install nodejs

    1-3. Verify and check is Nodejs installed or not.

    please note that, when you install Nodejs, a dependency package ( npm ) which is package manager of Nodejs will be installed. run below command to see the result.

    # node --version

    v12.22.0

    # npm --version

    6.14.11

     2.Installing from source code and binary :

    Node website allows to anyone to have an option for compling or using compiled version of Nodejs. when a person wants to install Nodejs and there is not internet access especially in some local datacenters around the world. Nodejs can be downloaded and installed on specific user and locally not globally on OS.

    2-1. Download and unzip with related tools. In this case we use tar command.

    cd ~; wget -c https://nodejs.org/dist/latest-v12.x/node-v12.22.0-linux-x64.tar.gz

    tar -zxf node-v12.22.0-linux-x64.tar.gz

    2-2. Run below commands to add node to your local profile.

    mv node-v12.22.0-linux-x64 node

    echo "PATH=$PATH:$HOME/node/bin" >> .bash_profile

    echo "export PATH" >> .bash_profile

    2-3. Verify Nodejs and npm version :

    $ node -v

    v12.22.0

    $ npm -v

    6.14.11

    As you can node is installed and can be used anytime. The second method is globally on Linux distro and not dedicated to any distributions.

    Regards,

    Farhad.

    Advertising
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email
    Previous ArticleNew Start
    Next Article Is your VPN safe ? – Part1
    admin
    • Website

    Related Posts

    Breaking

    New Start

    January 22, 2021
    Add A Comment
    Leave A Reply Cancel Reply

    Subscription Box

    Subscribe to our mailing list and get interesting stuff and updates to your email inbox.

    Thank you for subscribing.

    Something went wrong.

    Demo
    Top Posts

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    October 6, 2024208 Views

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    September 20, 2020204 Views

    How to Install Python3 on Centos 7

    December 26, 202113 Views
    Stay In Touch
    • Facebook
    • YouTube
    • TikTok
    • WhatsApp
    • Twitter
    • Instagram
    Latest Reviews

    Subscribe to Updates

    Get the latest tech news from FooBar about tech, design and biz.

    Demo
    Most Popular

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    October 6, 2024208 Views

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    September 20, 2020204 Views

    How to Install Python3 on Centos 7

    December 26, 202113 Views
    Our Picks

    Mikrotik SSTP VPN, Installing, Scripts, Advantages, and Disadvantages

    October 6, 2024

    How to Install Python3 on Centos 7

    December 26, 2021

    Is your VPN safe ? – Part1

    April 15, 2021

    Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.

    Facebook X (Twitter) Instagram YouTube LinkedIn WhatsApp Telegram
    • Home
    • Technology
    • Gaming
    • Phones
    • Buy Now
    © 2025 All Right Reserved By Gulf Digital Portal ThemeSphere.

    Type above and press Enter to search. Press Esc to cancel.