nodebb running, but inaccessible from browser (local install)


  • @baris no it doesn't like that either

  • GNU/Linux Admin

    @giorgio-chiodi When you go to /api/home, what shows up in the NodeBB log? (./nodebb log to view logs. Have it running while you try accessing /api/home)


  • weird not displaying anything


  • @julian

    info: NodeBB attempting to listen on: 0.0.0.0:4567
    info: NodeBB Ready
    
  • GNU/Linux Admin

    What happens if you do the above, and NodeBB is running in development mode? (./nodebb dev)


  • @julian Error: No category found!

    info: NodeBB Ready
    info: [socket] uid 1 (FaaX4q5o_Y_x59bv20lN) has successfully reconnected.
    info: [socket] uid 1 (v8qrk-v8GU4iyW8-20lO) has successfully reconnected.
    Error: No category found!
        at /home/super/nodeBB/nodebb/src/categories.js:290:14
        at /home/super/nodeBB/nodebb/src/database/redis.js:154:4
        at try_callback (/home/super/nodeBB/nodebb/node_modules/redis/index.js:532:9)
        at RedisClient.return_reply (/home/super/nodeBB/nodebb/node_modules/redis/index.js:614:13)
        at HiredisReplyParser.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:266:14)
        at HiredisReplyParser.EventEmitter.emit (events.js:95:17)
        at HiredisReplyParser.execute (/home/super/nodeBB/nodebb/node_modules/redis/lib/parser/hiredis.js:43:18)
        at RedisClient.on_data (/home/super/nodeBB/nodebb/node_modules/redis/index.js:488:27)
        at Socket.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:82:14)
        at Socket.EventEmitter.emit (events.js:95:17)
    Error: topic doesn't exist
        at /home/super/nodeBB/nodebb/src/topics.js:343:28
        at /home/super/nodeBB/nodebb/src/topics.js:336:4
        at try_callback (/home/super/nodeBB/nodebb/node_modules/redis/index.js:532:9)
        at RedisClient.return_reply (/home/super/nodeBB/nodebb/node_modules/redis/index.js:614:13)
        at HiredisReplyParser.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:266:14)
        at HiredisReplyParser.EventEmitter.emit (events.js:95:17)
        at HiredisReplyParser.execute (/home/super/nodeBB/nodebb/node_modules/redis/lib/parser/hiredis.js:43:18)
        at RedisClient.on_data (/home/super/nodeBB/nodebb/node_modules/redis/index.js:488:27)
        at Socket.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:82:14)
        at Socket.EventEmitter.emit (events.js:95:17)
    
  • NodeBB

    @Giorgio-Chiodi do you have access to redis-cli to run some commands?


  • @baris sorry, I haven't seen your post. Yes, I have access

  • NodeBB

    Can you the run the following command.

    redis-cli
    zrange categories:cid 0 -1
    

  • zrange categories:cid 0 -1

    @baris operation not permitted should i go sudo?

  • GNU/Linux Admin

    @giorgio-chiodi Does your redis have a password? If so, you'll need to type this command first:

    AUTH {password}


  • @julian ok now what 🙂

    redis 127.0.0.1:6379> zrange categories:cid 0 -1
     1) "1"
     2) "14"
     3) "29"
     4) "13"
     5) "2"
     6) "30"
     7) "15"
     8) "3"
     9) "31"
    10) "16"
    11) "20"
    12) "33"
    13) "4"
    14) "17"
    15) "18"
    16) "19"
    17) "34"
    18) "5"
    19) "22"
    20) "32"
    21) "6"
    22) "23"
    23) "7"
    24) "24"
    25) "8"
    26) "25"
    27) "9"
    28) "10"
    29) "26"
    30) "11"
    31) "27"
    32) "12"
    33) "28"
    34) "21"
    redis 127.0.0.1:6379> 
    
    
  • NodeBB

    Can you change this line https://github.com/designcreateplay/NodeBB/blob/master/src/categories.js#L290 to

    console.log(cid);
    throw new Error('category not found');
    

    And let us know the output.


  • console.log(cid);

    @baris

    (error) ERR unknown command 'console.log(cid);'

  • GNU/Linux Admin

    @giorgio-chiodi Please add those two lines into the code 🙂

    Follow this link, find that line, and replace it with the code in @baris' post.


  • @julian ahhh whoops sorry thought it was a command


  • @julian ok I've edited the file - now what?


  • @baris what output?

  • NodeBB

    Try running again to get that Error: No category found! error and see what the output is.


  • @baris

    info: NodeBB Ready
    17
    error: [app] Encountered Uncaught Exception: category not found
    Error: category not found
        at /home/super/nodeBB/nodebb/src/categories.js:291:12
        at /home/super/nodeBB/nodebb/src/database/redis.js:154:4
        at try_callback (/home/super/nodeBB/nodebb/node_modules/redis/index.js:532:9)
        at RedisClient.return_reply (/home/super/nodeBB/nodebb/node_modules/redis/index.js:614:13)
        at HiredisReplyParser.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:266:14)
        at HiredisReplyParser.EventEmitter.emit (events.js:95:17)
        at HiredisReplyParser.execute (/home/super/nodeBB/nodebb/node_modules/redis/lib/parser/hiredis.js:43:18)
        at RedisClient.on_data (/home/super/nodeBB/nodebb/node_modules/redis/index.js:488:27)
        at Socket.<anonymous> (/home/super/nodeBB/nodebb/node_modules/redis/index.js:82:14)
        at Socket.EventEmitter.emit (events.js:95:17)
    info: [app] Restarting...
    info: [app] Shutdown (SIGTERM/SIGINT) Initialised.
    info: [app] Database connection closed.
    info: [app] Shutdown complete.
    info: NodeBB v0.3.2 Copyright (C) 2013 DesignCreatePlay Inc.
    info: This program comes with ABSOLUTELY NO WARRANTY.
    info: This is free software, and you are welcome to redistribute it under certain conditions.
    info: 
    info: Time: Thu Mar 06 2014 19:10:32 GMT+0100 (CET)
    info: Initializing NodeBB v0.3.2
    info: * using configuration stored in: /home/super/nodeBB/nodebb/config.json
    info: * using redis store at 127.0.0.1:6379
    info: * using themes stored in: /home/super/nodeBB/nodebb/node_modules
    info: Base Configuration OK.
    info: [themes] Using theme nodebb-theme-lavender
    info: Static directory routed for theme: nodebb-theme-lavender
    info: Custom templates directory routed for theme: nodebb-theme-lavender
    info: Middlewares loaded.
    info: [plugins] Initializing plugins system
    info: [notifications.init] Registering jobs.
    warn: [plugins] Plugin 'nodebb-plugin-gallery' not found
    warn: [plugins] Plugin 'nodebb-plugin-youtube' not found
    warn: [plugins] Plugin 'nodebb-plugin-emailer-mailgun' not found
    warn: [plugins] Plugin 'nodebb-plugin-desktop-notifications' not found
    warn: [plugins] Plugin 'nodebb-plugin-imgbed' not found
    warn: [plugins/nodebb-widget-essentials] staticDir is deprecated, use staticDirs instead
    info: [plugins] Found 1 CSS file(s) for plugin nodebb-widget-essentials
    warn: [plugins/nodebb-widget-essentials] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-mentions] This plugin may not be compatible with your version of NodeBB. This may cause unintended behaviour or crashing.
    info: [plugins] Found 1 LESS file(s) for plugin nodebb-plugin-mentions
    info: [plugins] Found 2 js file(s) for plugin nodebb-plugin-mentions
    warn: [plugins/nodebb-plugin-markdown] This plugin may not be compatible with your version of NodeBB. This may cause unintended behaviour or crashing.
    info: [plugins] Found 1 LESS file(s) for plugin nodebb-plugin-markdown
    warn: [plugins/nodebb-theme-lavender] staticDir is deprecated, use staticDirs instead
    info: [plugins] Loaded plugin: nodebb-widget-essentials
    info: [plugins] Loaded plugin: nodebb-plugin-mentions
    info: [plugins] Loaded plugin: nodebb-plugin-markdown
    info: [plugins] Loaded plugin: nodebb-theme-lavender
    info: [plugins] Sorting hooks to fire in priority sequence
    info: [plugins] Plugins OK
    info: NodeBB attempting to listen on: 0.0.0.0:4567
    info: NodeBB Ready
    ^Cinfo: [app] Shutdown (SIGTERM/SIGINT) Initialised.
    info: [app] Database connection closed.
    info: [app] Shutdown complete.
    

Suggested Topics

  • 7
  • 2
  • 10
  • 3
  • 1
| |