RocketChat / Rocket.Chat

The communications platform that puts data protection first.
https://rocket.chat/
Other
40.4k stars 10.51k forks source link

Blank gray page showed after run RocketChat service #15462

Closed ali-zohrevand closed 4 years ago

ali-zohrevand commented 5 years ago

Description:

Hi, I Installed latest version of Rocket Chat on my ubuntu 18.04 server, after installed based on RocketChat Doc, a simple gray paged show whit white box centered. Capture

Steps to reproduce:

  1. Run RocketChat service
  2. open web site url in browser

Expected behavior:

Start or welcome page of Rocket Chat with some text box to register user.

Actual behavior:

Showing blank gray page!

Server Setup Information:

Additional context

Relevant logs:

sudo systemctl status rocketchat
● rocketchat.service - The Rocket.Chat server
   Loaded: loaded (/lib/systemd/system/rocketchat.service; enabled; vendor preset: enabled)
   Active: active (running) since Sun 2019-09-29 09:35:40 +0330; 24min ago
 Main PID: 1671 (node)
    Tasks: 10 (limit: 4632)
   CGroup: /system.slice/rocketchat.service
           └─1671 /usr/local/bin/node /opt/Rocket.Chat/main.js

Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |      MongoDB Version: 4.0.12                      |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |       MongoDB Engine: mmapv1                      |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |             Platform: linux                       |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |         Process Port: 3000                        |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |             Site URL: http://domain:3000/  |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |     ReplicaSet OpLog: Enabled                     |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |          Commit Hash: 92c00dc3c2                  |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |        Commit Branch: HEAD                        |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ |                                                   |
Sep 29 09:36:23 GITLAB-WEB rocketchat[1671]: ➔ +---------------------------------------------------+
reetp commented 5 years ago

Deployment Method: etc behind nginx proxy

What's 'etc' ?

From your logs it looks like Rocket has started and there don't seem to be any errors so this appears to be a setup/configuration problem rather than a bug.

I suggest you look at your proxy.

Please see here for how to get support.

https://rocket.chat/docs/getting-support/

ali-zohrevand commented 5 years ago

My nginx conf file is:

# Upstreams
upstream backend {
    server 127.0.0.1:3000;
}

# HTTPS Server
server {
    listen 443;
    server_name mydomain;

    # You can increase the limit if your need to.
    client_max_body_size 200M;

    error_log /var/log/nginx/rocketchat.access.log;

    ssl on;
    ssl_certificate /etc/nginx/certificate.crt;
    ssl_certificate_key /etc/nginx/certificate.key;
    ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # don’t use SSLv3 ref: POODLE

    location / {
        proxy_pass http://backend/;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;

        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forward-Proto http;
        proxy_set_header X-Nginx-Proxy true;
#       proxy_headers_hash_max_size 512;
#     proxy_headers_hash_bucket_size 128;
        proxy_redirect off;
    }
}

my mongo conf is:

# mongod.conf

# for documentation of all options, see:
#   http://docs.mongodb.org/manual/reference/configuration-options/

# Where and how to store data.
storage:
  dbPath:  /dbpath
  journal:
    enabled: true
  engine: mmapv1
#  mmapv1:
#  wiredTiger:

# where to write logging data.
systemLog:
  destination: file
  logAppend: true
  path: /var/log/mongodb/mongod.log

# network interfaces
net:
  port: 27017
  bindIp: 127.0.0.1

# how the process runs
processManagement:
  timeZoneInfo: /usr/share/zoneinfo

#security:

#operationProfiling:

replication:
  replSetName: rs01

#sharding:

## Enterprise-Only Options:

#auditLog:

#snmp:

is there any other conf file which must be set? I am using last version of firefox and chrome

sampaiodiego commented 5 years ago

I saw on the logs Site URL: http://domain:3000 .. is this information what you have set? this might be the cause, ROOT_URL needs to be set correctly in order to rocket.chat load the assets.

please take a look at https://rocket.chat/docs/administrator-guides/troubleshooting/

ali-zohrevand commented 5 years ago

I saw on the logs Site URL: http://domain:3000 .. is this information what you have set? this might be the cause, ROOT_URL needs to be set correctly in order to rocket.chat load the assets.

please take a look at https://rocket.chat/docs/administrator-guides/troubleshooting/

No, it is not, I set my domain address and it is hidden here because of security reason.

sampaiodiego commented 5 years ago

no problem. please check browser's console and network tab. are there any errors?

ali-zohrevand commented 5 years ago

no problem. please check browser's console and network tab. are there any errors?

thank you for helping. browser's console is empty and network tabis like this.

network

sampaiodiego commented 5 years ago

@ali-zohrevand everything seems to be ok (even though the login form doesn't show up).

have you changed any of the settings regarding the login form? image

or any of the Iframe settings under Accounts page? image

or have you changed any other setting at all? those settings I know can prevent the login form to show up, but might there others.

ali-zohrevand commented 5 years ago

This problem occurred right after installing the RocketChat and the dashboard was not running so I have not changed the settings. My server is behind a restricted firewall. Only ports 80 and 443 are open. Is there a need for port or network access?

ali-zohrevand commented 5 years ago

I used Lynx command too. there was nothing showd in resault.

sampaiodiego commented 5 years ago

I'm sure about lynx's javascript support.. so I'd not expect it to work there.

also, only port 80 or 443 are needed.. so it should be ok.

but I just saw there are multiple requests to same endpoints on the network image you shared: image

is it in loop? if so, are there any errors on nginx logs?

I have to say, this behavior is very weird.. have you tried installing it again? are there any code changes or is it the official release? have you tried different deploy methods (such as docker)?

Please try upgrading your NodeJS version to 8.15.1 as well as it is the recommended version for Rocket.Chat 2.1.0.. thanks

ali-zohrevand commented 5 years ago

Thank you so much for your time and for trying to help me. . I did not make any changes to the source code or packages of the software exactly as I followed the steps on the main site. I tried "snap" solution, but i think there was conflict with my pre-installed mongo

sudo journalctl -f -u snap.rocketchat-server.rocketchat-server
-- Logs begin at Wed 2019-08-14 13:35:27 +0430. --
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: error: process ID list syntax error
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Usage:
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]:  ps [options]
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]:  Try 'ps --help <simple|list|output|threads|misc|all>'
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]:   or 'ps --help <s|l|o|t|m|a>'
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]:  for additional help text.
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: For more details see ps(1).
Oct 09 08:27:38 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Mongo is not available, can't start. Waiting 10 seconds and trying again
Oct 09 08:27:48 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Mongo is not available, can't start. Waiting 15 seconds and trying again
Oct 09 08:28:03 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Mongo is not available, can't start. Waiting 20 seconds and trying again
Oct 09 08:28:23 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Mongo is not available, can't start. Waiting 25 seconds and trying again
Oct 09 08:28:48 GITLAB-WEB rocketchat-server.rocketchat-server[15231]: Mongo is not available, can't start. Waiting 30 seconds and trying again

There was not any loop, It happened just two time, i try access to RckectChat directly via Port:3000 and there was not any diffrent.

wstraszak commented 4 years ago

Check this guys: https://stackoverflow.com/questions/4390436/need-to-allow-encoded-slashes-on-apache/4443129#4443129 if it's help to resolve your issue. I faced the same problem and this one helped.

github-actions[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.