How to install nodeBB on Ubuntu LTS

nodeBB is such a powerful and colorful application, that I wanted it to use for an internet project of mine. The big problem was, that nodeBB gets its performance mainly from other components than php or mysql. So this makes the installation process a little bit harder, but not impossible to succeed. At first make sure that you have installed Ubuntu 64bit version on your Computer.

When you have done this please open a terminal and use the following commands. Feel free to use the superuser command "sudo" in front of each line. Read the complete instructions before you start to hack the code into command prompt.

At first you have to install the LTS version of node.js, you can do it with the command line:

curl -sL | sudo -E bash -

When it's done you have to install nodebb's dependencies with command line:

sudo apt-get install -y git nodejs mongodb build-essential

Now you have to clone the git repository of nodebb with the following command:

git clone -b v1.x.x nodebb

This clones the whole software to $ nodebb/ which makes it easy to access an backup. Attention: keep an eye to the latest version of nodeBB. Perhaps the instruction "v1.x.x" is outdated. You may replace it by "weekly" to get the latest non-stable version of nodeBB.

Now obtain all of the dependencies required by nodeBB using following commands:

cd nodebb

Type it into the terminal command line to get into the folder, then use:

npm install --production

to start the installation process.

Now you have to configure the mongoDB. You have to create a database and a user, that has read/write access to the database. Type:


to enter the database command-line, type:

use nodebb

to create a database called nodeBB, now create a user with a password with:

db.createUser( { user: "your user to mongodb access", pwd: "", roles: [ "readWrite" ] } )

Now your have to configure the MongoDB by editing the /etc/mongodb.conf file:

sudo nano /etc/mongodb.conf

Here you have to find the line #auth = true. Uncomment it by removing the #hashtag and save and exit the file (ctrl+o and ctrl+x).

Now restart the mongoDB service with:

service mongodb restart

to force mongoDB to use authorised users to obtain access to the database.

Now start the webinstaller of nodeBB:

npm start

type "" in your html browser adress bar. Now you have access to the setup of your forum software.

Normaly the server has started nodeBB after the setup has finished. If it doesn't you can type:

./nodebb start or node app

in your command line.

Disclaimer: These instructions have worked with node 4.5, Ubuntu 16.04 LTS Version and nodeBB v1.1.2. I don't give any guarantees. Backup your files before you do the installation!

Link to the german version of this instruction

Next Post Previous Post