Skip to content

NodeBB 1.19.3

Solved Performance
  • Hello 🙂

    I find that since version 1.19.3 of NodeBB, the refresh of the pages is much longer than usual.

    I did a test with the same config on my VM and in 1.19.2, the refresh was much faster.
    idem to connect to ACP.

    Am I the only one who noticed this?

  • @phenomlab

    I find the problem Mark 😉

    The error message indicated this path :

    http://localhost:4567/assets/plugins/nodebb-plugin-emoji/emoji/styles.css?v=6983dobg16u

    I change the path url on config.json

    47bacc80-f141-41e4-a261-3f8d650cc6f6-image.png

    And all it’s good 🙂

    Weird, I didn’t have to change that path before 1.19.3

    But this does not prevent the problem from a clean install with Emoji Plugin


    EDIT: After test, that resolv the problem installation for 1.18.x but not for 1.19.x (I have other error message when I run ./nodebb Setup

    For resume: NodeJS 16_x with 1.18.x is ok

  • @DownPW I’ve not upgraded yet but will do so at some point today.

    EDIT- just upgraded. Not seeing any slowness yet, but will continue to monitor 😕

  • Seems to be my VM virtual disk the problem.

    I try to reinstall Nodebb, very odd i have an internal server error

    here is what I do:

    #
    # Installing Node.js
    #
    
    apt install curl
    curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash -
    sudo apt-get install -y nodejs
    
    #
    # Database: # Installing MongoDB
    #
    
    V5
    curl -sSL https://www.mongodb.org/static/pgp/server-5.0.asc  -o mongoserver.asc
    gpg --no-default-keyring --keyring ./mongo_key_temp.gpg --import ./mongoserver.asc
    gpg --no-default-keyring --keyring ./mongo_key_temp.gpg --export > ./mongoserver_key.gpg
    sudo mv mongoserver_key.gpg /etc/apt/trusted.gpg.d/
    
    wget -qO - https://www.mongodb.org/static/pgp/server-5.0.asc | sudo apt-key add -
    
    echo "deb http://repo.mongodb.org/apt/debian buster/mongodb-org/5.0 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-5.0.list
    
    sudo apt update
    sudo apt-get install -y mongodb-org
    
    sudo systemctl start mongod
    sudo systemctl status mongod
    
    mongo
    use admin
    > db.createUser( { user: "admin", pwd: "nodebb", roles: [ { role: "root", db: "admin" } ] } )
    
    use nodebb
    > db.createUser( { user: "nodebb", pwd: "nodebb", roles: [ { role: "readWrite", db: "nodebb" }, { role: "clusterMonitor", db: "admin" } ] } )
    
    quit()
    
    sudo nano /etc/mongod.conf
    	security:
    		authorization: enabled
    
    sudo systemctl restart mongod
    
    
    #
    # Installing NodeBB
    #
    
    sudo apt install -y git
    
    cd /home/nodebb
    git clone -b v1.18.x https://github.com/NodeBB/NodeBB.git nodebb
    cd nodebb
    
    ./nodebb setup
    ./nodebb start
    

    very odd

  • @DownPW And did that work ?

  • nope, i have test the installation for 2 times

    this error when access:

    internal server error

    very odd, I’ve never had any problems when installing nodebb

  • @DownPW If you issue ./nodebb start does this work if you then issue ./nodebb log ? Sounds like a NGINX issue to me

  • No nginx conf

    ./nodebb sytart = no error

    ./nodebb log when i access

    2022-02-17T15:26:25.097Z [4567/1884] - error: /
    Error: Login sessions require session support. Did you forget to use `express-session` middleware?
        at SessionStrategy.authenticate (/home/nodebb/nodebb/node_modules/passport/lib/strategies/session.js:46:41)
        at attempt (/home/nodebb/nodebb/node_modules/passport/lib/middleware/authenticate.js:369:16)
        at authenticate (/home/nodebb/nodebb/node_modules/passport/lib/middleware/authenticate.js:370:7)
        at Layer.handle [as handle_request] (/home/nodebb/nodebb/node_modules/express/lib/router/layer.js:95:5)
        at trim_prefix (/home/nodebb/nodebb/node_modules/express/lib/router/index.js:323:13)
        at /home/nodebb/nodebb/node_modules/express/lib/router/index.js:284:7
        at Function.process_params (/home/nodebb/nodebb/node_modules/express/lib/router/index.js:341:12)
        at next (/home/nodebb/nodebb/node_modules/express/lib/router/index.js:275:10)
        at initialize (/home/nodebb/nodebb/node_modules/passport/lib/middleware/initialize.js:89:5)
        at Layer.handle [as handle_request] (/home/nodebb/nodebb/node_modules/express/lib/router/layer.js:95:5)
    TypeError: Cannot read property 'startsWith' of undefined
        at Object.getBaseUrl (/home/nodebb/nodebb/node_modules/nodebb-plugin-emoji/build/lib/base-url.js:7:25)
        at Object.addStylesheet [as method] (/home/nodebb/nodebb/node_modules/nodebb-plugin-emoji/build/lib/index.js:75:32)
        at fireMethod (/home/nodebb/nodebb/src/plugins/hooks.js:137:25)
        at Object.fireFilterHook [as filter] (/home/nodebb/nodebb/src/plugins/hooks.js:168:18)
        at processTicksAndRejections (internal/process/task_queues.js:95:5)
        at async Hooks.fire (/home/nodebb/nodebb/src/plugins/hooks.js:105:17)
        at async Promise.all (index 1)
        at async Tags.parse (/home/nodebb/nodebb/src/meta/tags.js:146:18)
        at async renderMethod (/home/nodebb/nodebb/src/middleware/render.js:49:12)
        at async ServerResponse.renderOverride [as render] (/home/nodebb/nodebb/src/middleware/render.js:92:5)
    
  • @DownPW Potentially dumb question, but why is the path /home/nodebb/nodebb ?

    Also, why are you trying to install the 18.x branch when you should be using 19.x ?

    I see

    cd /home/nodebb
    git clone -b v1.18.x https://github.com/NodeBB/NodeBB.git nodebb
    cd nodebb
    

    This should be

    cd /home/nodebb
    git clone -b v1.19.x https://github.com/NodeBB/NodeBB.git nodebb
    cd nodebb
    
  • I have test to install 1.19.x too and i have error too

  • @DownPW and you are executing ./nodebb setup from the correct directory ?

  • I think they really have a problem on the github and coincidentally it’s a plugin on which they had big problems that was in question. (emoji)

  • @DownPW Looking at the error message, I’d say you’re right.

  • @phenomlab

    here a gif for the problem of perf.
    On a clean install of nodeBB on a clean install server VM

    The problem is just when I refresh the page entierly or ACP access

    alt text

    No problem on 1.18.x or 1.19.2

    very odd

  • @DownPW Looks like that’s waiting for a response from something. Have you run this site through the F12 developer tools -> Network tab to see where the delay is ?

  • @phenomlab

    Thanks for the tip

    chance 😉

    335905d5-03e1-4f81-83a6-93e5f30d9bfa-image.png

  • @DownPW 8ms is nothing - less than one second… ?

  • @phenomlab

    you not see at the good place 🙂
    EDIT:

    dcba37d8-db4f-4b8d-93a9-ac883171bebc-image.png

    coincidence? Emoji CSS failed !
    I don’t believe

    I think we put the finger on something

  • @DownPW Yes, you’re right. For some strange reason, that CSS file is not being served - but should be on your server if you check the path.

  • yes it still here

    EDIT:

    I have remove the directory when I have the problem of install with 1.18.x

    But when I upgrade to 1.19.3, he have reinstalled by default


Did this solution help you?
Did you find the suggested solution useful? Why not buy me a coffee? It's a nice gesture, and a great way to show your appreciation 💗

  • Page control arrows for PWA

    Solved Customisation
    27
    25 Votes
    27 Posts
    427 Views

    @crazycells it is, yes - I think I’ll leave it as there is no specific PWA CSS classes I know of. Well, you could use something like the below, but this means multiple CSS files for different operating systems.

    /** * Determine the mobile operating system. * This function returns one of 'iOS', 'Android', 'Windows Phone', or 'unknown'. * * @returns {String} */ function getMobileOperatingSystem() { var userAgent = navigator.userAgent || navigator.vendor || window.opera; // Windows Phone must come first because its UA also contains "Android" if (/windows phone/i.test(userAgent)) { return "Windows Phone"; } if (/android/i.test(userAgent)) { return "Android"; } if (/iPad|iPhone|iPod/.test(userAgent) && !window.MSStream) { return "iOS"; } return "unknown"; // return “Android” - one should either handle the unknown or fallback to a specific platform, let’s say Android }

    Once you’re in that rabbit hole, it’s impossible to get out of it.

  • 1 Votes
    3 Posts
    148 Views

    @phenomlab yes, it is 🙂 thanks a lot…

  • 1 Votes
    26 Posts
    1k Views

    Yes ogproxy too is functionnal on dev

  • 17 Votes
    34 Posts
    2k Views

    @phenomlab thank you very much, this was helpful. Everything looks ok 🙂

  • Upgrade issues

    Solved Configure
    2
    2 Votes
    2 Posts
    136 Views

    Use this code

    git fetch # Grab the latest code from the NodeBB repository git checkout v3.x git reset --hard origin/v3.x

    And you will have the latest version without specifying it

    https://docs.nodebb.org/configuring/upgrade/

  • SEO and Nodebb

    Performance
    2
    2 Votes
    2 Posts
    146 Views

    @Panda It’s the best it’s ever been to be honest. I’ve used a myriad of systems in the past - most notably, WordPress, and then Flarum (which for SEO, was absolutely dire - they never even had SEO out of the box, and relied on a third party extension to do it), and NodeBB easily fares the best - see below example

    https://www.google.com/search?q=site%3Asudonix.org&oq=site%3Asudonix.org&aqs=chrome..69i57j69i60j69i58j69i60l2.9039j0j3&sourceid=chrome&ie=UTF-8#ip=1

    However, this was not without significant effort on my part once I’d migrated from COM to ORG - see below posts

    https://community.nodebb.org/topic/17286/google-crawl-error-after-site-migration/17?_=1688461250365

    And also

    https://support.google.com/webmasters/thread/221027803?hl=en&msgid=221464164

    It was painful to say the least - as it turns out, there was an issue in NodeBB core that prevented spiders from getting to content, which as far as I understand, is now fixed. SEO in itself is a dark art - a black box that nobody really fully understands, and it’s essentially going to boil down to one thing - “content”.

    Google’s algorithm for indexing has also changed dramatically over the years. They only now crawl content that has value, so if it believes that your site has nothing to offer, it will simply skip it.

  • 2 Votes
    4 Posts
    178 Views

    @Panda said in Sidebar Widget is no longer on the side!:

    Ah, so sidebar wont work on mobile?

    Correct. If you review the docs on bootstrap, you’ll notice that it is designed on a grid system

    https://getbootstrap.com/docs/5.0/layout/grid/

    What I mean by changing the category is moving it on here to general as you posted it in bugs, when it isn’t.

  • 1 Votes
    4 Posts
    477 Views

    @eeeee if you’re using the console, you could try

    node app.js > app.log 2>&1

    This would redirect stdout to a file named app.log and redirect stderr to stdout.

    I’m not sure about standard logging under NodeBB, but there is an error log located at logs/error.log.

    Failing that, you could always stop the NodeBB service then use ./nodebb dev from the console which would then provide debug output.