Ylianst / MeshCentral

A complete web-based remote monitoring and management web site. Once setup you can install agents and perform remote desktop session to devices on the local network or over the Internet.
https://meshcentral.com
Apache License 2.0
3.99k stars 536 forks source link

Error after updating to 0.4.5-b #694

Closed openmoto closed 4 years ago

openmoto commented 4 years ago

Server: OS: Ubuntu 18.04 x64 meshcentral : 0.4.5-b

After upgrading server version from the web interface, I'm able to log back in and get past the 2FA but get the message "Unable to connect web socket, click to reconnect." It refreshes the screen and back to same page when I click on the link to reconnect.

I've manually tried to update from CLI by doing the commands below

sudo systemctl stop meshcentral.service
npm update
sudo systemctl start meshcentral.service
systemctl daemon-reload

Didn't seem to help.

Ylianst commented 4 years ago

First, let me know what version of Node you are running by doing "node -v". Next, look in "meshcentral-data" for the "mesherrors.txt". If there is one, put the last few errors in this issue so we can have a look at it. Then, stop the MeshCentral server and run MeshCentral manually using:

sudo systemctl stop meshcentral.service
node node_modules/meshcentral

Running it manually should help show what is going on.

Thanks, Ylian

openmoto commented 4 years ago

Node version is v8.10.0 I logged in from my phone to check and noticed I'm able to log back in but no device is connected. Then a few minutes later I was able to get back on a computer and most of the devices are back online.

Seems node needs updating.

WARNING: Let's Encrypt support requires Node v10.12 or higher.
MeshCentral HTTP redirection server running on port 80.
MeshCentral v0.4.5-b, WAN mode.
MeshCentral Intel(R) AMT server running on xxxxxxxxxca:4433.
Server _customer1 has no users, next new account will be site administrator.
Server _info has no users, next new account will be site administrator.
MeshCentral HTTPS server running on xxxxxxxca:443.
SMTP mail server aspmx.l.google.com working as expected.

I'll be updating node later tonight. Thanks

Ylianst commented 4 years ago

First, you should right away go in config.json and remove the entire _customer1 and _info sections from the domain section. As you see above, they could be used by people because there is no accounts for these domains.

Yes, NodeJS needs updating now in order to use Let's Encrypt.

Finally, make sure ports 80 and 443 are accessible from the internet.

Ylianst commented 4 years ago

I did also want to mention that when updating MeshCentral using NPM, I don't use "npm update". Instead, I go on level above the "node_modules" folder and type "npm install meshcentral" again. This will update all modules.

openmoto commented 4 years ago

Thanks. Cleaned up the config.json and upgraded node to v12.13.1 Been working without any errors when running manually.