Installing NodeBB on Ubuntu

Technical Support
  • Hi,

    I was following the instructions on NodeBBDocs when after the very last steps, nothing happened. It stopped where the instructions below stop. This made me worried, so I restarted the connection and did npm start. It gave me errors :

    Last login: Wed Mar 23 14:17:27 2016 from xx2.1x5.xx0.1xx
    root@d191c985971e:~# npm start
    npm ERR! Linux 3.19.8-031908-generic
    npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "start"
    npm ERR! node v4.4.0
    npm ERR! npm  v2.14.20
    npm ERR! path /root/package.json
    npm ERR! code ENOENT
    npm ERR! errno -2
    npm ERR! syscall open
    
    npm ERR! enoent ENOENT: no such file or directory, open '/root/package.json'
    npm ERR! enoent This is most likely not a problem with npm itself
    npm ERR! enoent and is related to npm not being able to find a file.
    npm ERR! enoent
    
    npm ERR! Please include the following file with any support request:
    npm ERR!     /root/npm-debug.log
    root@d191c985971e:~#
    

    Installation Guide - Error occurred where the guide finishes.

    The following installation guide is optimised for Ubuntu LTS versions, and will install NodeBB with MongoDB as the data store. Currently at the time of writing, the latest available Ubuntu LTS version is 14.04.

    First, install the LTS version of Node.js (v4.2 Argon):

    $ curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash -
    Next, we’ll install the dependencies required by NodeBB

    $ sudo apt-get install -y git nodejs mongodb build-essential
    If you want to use Redis or another database instead of MongoDB please look at the Configuring Databases section.

    Next, clone NodeBB into your desired location. If you don’t know where, your home directory is acceptable:

    $ cd ~ # Optional $ git clone -b v1.0.0 https://github.com/NodeBB/NodeBB.git nodebb
    You’ll want to replace v1.0.0 with the (latest stable version), or v1.x.x if you’d like to set up the latest weekly build of NodeBB.

    Obtain all of the dependencies required by NodeBB:

    $ cd nodebb $ npm install --production
    Start the NodeBB Web Installer, and continue setup at http://127.0.0.1:4567, and select “MongoDB” as your database type.

    $ npm start

    ---Error Occurred here---

    Please assist me within 24 hours on how to fix.

    Thanks,
    Lewis

  • Please assist me within 24 hours on how to fix.

    This is a community forum not a paid tech support, regardless you seem to be not in the nodebb installation folder, go to the installation folder and then run npm start

  • @phit said:

    Please assist me within 24 hours on how to fix.

    This is a community forum not a paid tech support, regardless you seem to be not in the nodebb installation folder, go to the installation folder and then run npm start

    Hi,

    I was not saying this is a paid support. I was just saying that I needed help real quick, sorry if it was misunderstood.

    The main reason I am asking for help is that I am nowhere experienced in Linux commands. Although, I am experienced in other coding languages, Linux is not the one. Please give me commands to enter so I can go in the NodeBB Installation Folder.

    Thanks,
    Lewis

  • @YaBoiLewis you will need to use cd followed by your nodebb folder name

    example: cd nodebb

  • @charles said:

    @YaBoiLewis you will need to use cd followed by your nodebb folder name

    example: cd nodebb

    Hi,

    Thanks!

    Was this supposed to happen?

    Last login: Wed Mar 23 14:32:30 2016 from 1xx.1xx.xx0.18x
    root@d191c985971e:~# cd NodeBb
    -bash: cd: NodeBb: No such file or directory
    root@d191c985971e:~# cd nodebb
    root@d191c985971e:~/nodebb# npm start
    
    > [email protected] start /root/nodebb
    > node loader.js
    
    23/3 15:30 [1388] - info: Launching web installer on port 4567
    23/3 15:30 [1388] - info: Web installer listening on http://0.0.0.0:4567
    
  • @YaBoiLewis Yes you can now open a web browser and type the address shown to start the configuration.

  • @charles said:

    @YaBoiLewis Yes you can now open a web browser and type the address shown to start the configuration.

    Hi,

    Is it the address of the Ubuntu Server or 0.0.0.0:4567?

  • @YaBoiLewis You can try 0.0.0.0:4567 or localhost:4567. Both should work.

  • @charles said:

    @YaBoiLewis You can try 0.0.0.0:4567 or localhost:4567. Both should work.

    Hi,

    This is not running on my local machine. It's running on a server hosted by a company. How do I access then? As much as I know is that localhost is for your own machine (stated on your IP Address).

  • @YaBoiLewis you will need to replace it with the server ip or domain

    example: 8.8.8.8:4567 or www.example.com:4567

  • hello, there are a lot of painful things with installation from standart packets.
    I found easier way to install nodebb, but i don't know is it correct way or not, but nodebb works fine:

    1. install redis from official website & nodebb too
    2. install git / other important libraries from official documentation
    3. git clone nodebb repo to any folder to another user
    4. run nodejs & node app --setup
    5. enter all data correctly
    6. have fun
  • Hi,

    As much as I'd like to say this was helpful, it wasn't. The most help I got was from the guy who told me how to open the folder.

    With that being said, I am nowhere near. The main cause of this is probably me and I blame myself for that. I will be now hoping to get an Ubuntu Server from HostingItAll, and they will be helping me set up NodeBB!

    Thanks for all that you guys could do.

    Lewis


Suggested Topics


  • 0 Votes
    11 Posts
    623 Views

    @someoneyoulike We have set up instances where the db is not on the same machine as the server (mostly for horizontal scaling purposes, etc.)

    We don't notice any real-world degradation of performance. MongoDB is plenty fast, it's almost never the database (or network connections to the db) that are the bottleneck.

    Unless your app server is in Toronto and your database is in Singapore... but then you have other problems 😄

  • 0 Votes
    2 Posts
    712 Views

    Persona version is a little different from other plugins, it is fixed to your version of NodeBB. If you update your NodeBB, you should also get the newer Persona version.

  • 0 Votes
    4 Posts
    1k Views

    @duke said in How do I configure NodeBB setup for Google Cloud VM?:

    If you cannot answer these questions yourself then I suggest you install virtualbox on your local machine and get nodebb working locally but following the docs below. Once you are successful with this, you will have learned alot and can then try and deploy on Google infrastructure.

    I know you want to deploy straight to production but my way will be quicker in the long run. The next question you will have will be regarding NGINX and how to get it running on port 80. The answers to all your questions are in the docs. The docs are very easy to follow.

    Ubuntu (Recommended) - NodeBB Documentation

    favicon

    (docs.nodebb.org)

    <quote>
    I can create the website by using 127.0.0.1 IP but the connection is refused by google's internal IP
    (127 is a local ip, you need to provide your internet IP here)

    "url": "I typed here my domain which is connected to Google's external IP",
    "secret": "the key",
    "database": "mongo",
    "mongo": {
    "host": "Google's internal IP", (should be 127.0.0.1)
    "port": "I couldnt find this out?", (4567)
    "username": "Is this the nodebb user or the user I created for admin database?", (nodebb user)
    "password": "Password", (mongo password for Nodebb database)
    "database": "nodebb"
    </quote>

    Done 🙂

  • 0 Votes
    2 Posts
    2k Views

    For 1 I would be inclined to use clustering then reverse proxy the subdomains to categories. Rather than spooling individual instances for each. I've done this at my own site.

    dnb.35hz.co.uk will take you to the electronic category.

    You could then make a few changes to how your homepage/main website looks and do it that way.

    As an additional. Anything you're not sure exists, drop an email to sales [at]nodebb.org and they may be able to create what you need.

  • 0 Votes
    3 Posts
    2k Views

    I've found the issue. The problem was coming from the varnish's configuration, which was playing the set-cookie value.