Forum not working

Hi, When I click on Discussion tab inside course in LMS, I got error.
Screenshot of error is attached.

It looks like LMS is unable to connect with forum on port 4567.
Can any one assist me here how to resolve this issue?

Hi! How did you get the platform started? Are you running with tutor local or tutor dev? What is the output of docker ps | grep forum? And what is the output of tutor local logs --tail=100 forum?

Hi, @regis, thank you for your reply.

  1. I am running with tutor local
  2. Output of docker ps | grep forum

    3.Output of tutor local logs --tail=100 forum

It looks like Elasticsearch is not properly initialised. This issue was fixed in v3.12.6. What tutor version are you running?

Also, just to check that Elasticsearch is up, what is the output of:

  1. docker ps | grep elasticsearch
  2. tutor local logs --tail=100 elasticsearch

(Please copy-paste the output instead of inserting screen captures, it makes it much easier for other people to google the same issue)

Thank you for your reply. I am using version 3.11.12.

  1. output of docker ps | grep elasticsearch

  2. output of tutor local logs --tail=100 elasticsearch
    > elasticsearch_1 | [2020-06-04 16:19:39,527][INFO ][node ] [Karl Lykos] version[1.5.2], pid[1], build[62ff986/2015-04-27T09:21:06Z]

elasticsearch_1   | [2020-06-04 16:19:39,529][INFO ][node                     ] [Karl Lykos] initializing ...
elasticsearch_1   | [2020-06-04 16:19:39,548][INFO ][plugins                  ] [Karl Lykos] loaded [], sites []
elasticsearch_1   | [2020-06-04 16:19:53,199][INFO ][node                     ] [Karl Lykos] initialized
elasticsearch_1   | [2020-06-04 16:19:53,200][INFO ][node                     ] [Karl Lykos] starting ...
elasticsearch_1   | [2020-06-04 16:19:53,715][INFO ][transport                ] [Karl Lykos] bound_address {inet[/0.0.0.0:9300]}, publish_address {inet[/172.18.0.8:9300]}
elasticsearch_1   | [2020-06-04 16:19:53,819][INFO ][discovery                ] [Karl Lykos] openedx/byeIJ0MpQGeq_IR_H5b2bA
elasticsearch_1   | [2020-06-04 16:19:57,651][INFO ][cluster.service          ] [Karl Lykos] new_master [Karl Lykos][byeIJ0MpQGeq_IR_H5b2bA][7cd1d86c5270][inet[/172.18.0.8:9300]], reason: zen-disco-join (elected_as_master)
elasticsearch_1   | [2020-06-04 16:19:57,818][INFO ][http                     ] [Karl Lykos] bound_address {inet[/0.0.0.0:9200]}, publish_address {inet[/172.18.0.8:9200]}
elasticsearch_1   | [2020-06-04 16:19:57,824][INFO ][node                     ] [Karl Lykos] started
elasticsearch_1   | [2020-06-04 16:19:59,851][INFO ][gateway                  ] [Karl Lykos] recovered [1] indices into cluster_state

I suggest you upgrade. Of you could just run tutor local init, and that should fix the problem.

Thank you @regis. You are great!. It worked.
But can you shortly explain what this command did and why it was needed to initialize services again (after the platform was up and runnning) ?

Well, it all depends how you got the platform up and running. Did you run tutor local quickstart? If yes, then the elasticsearch index should have been created, as init is a command that is run as part of quickstart.

Thank you for your reply. I do not know how old developer started platform. But I uses tutor local stop/start after modifications.

When in doubt, you should always run tutor local quickstart @sajid. “quickstart” launches the various docker container, but also initialises them, which is necessary to run database migrations, update SSL certificates, etc. “start” is only a part of “quickstart”.