[SOLVED] After upgrade to 4.4 Mattermost doesn't start


I upgraded Mattermost from 4.3 to 4.4 but now I can’t start the server anymore. The log looks like the following:

Error starting server, err:accept tcp [::]:8065: use of closed network connection
There is no firewall active. Also I can’t see mattermost if I check the ports with netstat.

Observed behavior

root@node05:/opt/mattermost/bin# ./platform
[2017/12/08 20:58:44 CET] [INFO] Loaded system translations for ‘en’ from ‘/opt/mattermost/i18n/en.json’
[2017/12/08 20:58:44 CET] [INFO] Current version is 4.4.0 (4.4.3/Mon Dec 4 21:38:15 UTC 2017/753386c2b2b06233d8bd977e3db29a4fe18098cb/a7c7c47c878694ab372a1d754a82e888c214bff3)
[2017/12/08 20:58:44 CET] [INFO] Enterprise Enabled: true
[2017/12/08 20:58:44 CET] [INFO] Current working directory is /opt/mattermost/bin
[2017/12/08 20:58:44 CET] [INFO] Loaded config file from /opt/mattermost/config/config.json
[2017/12/08 20:58:44 CET] [INFO] Able to write files to local storage.
[2017/12/08 20:58:44 CET] [INFO] Loaded system translations for ‘en’ from ‘/opt/mattermost/i18n/en.json’
[2017/12/08 20:58:44 CET] [INFO] Server is initializing…
[2017/12/08 20:58:44 CET] [INFO] Pinging SQL master database
[2017/12/08 20:58:44 CET] [INFO] Initializing plugin: jira
[2017/12/08 20:58:44 CET] [INFO] Initializing plugin: ldapextras
[2017/12/08 20:58:44 CET] [INFO] License key from https://mattermost.com required to unlock enterprise features.
[2017/12/08 20:58:44 CET] [INFO] Starting Server…
[2017/12/08 20:58:44 CET] [INFO] Server is listening on [::]:8065
[2017/12/08 20:58:44 CET] [CRIT] Error starting server, err:accept tcp [::]:8065: use of closed network connection
[2017/12/08 20:58:44 CET] [EROR] Unable to setup forwarding
[2017/12/08 20:58:44 CET] [INFO] Initializing job API routes
[2017/12/08 20:58:45 CET] [INFO] API version 3 is scheduled for deprecation. Please see https://api.mattermost.com for details.
[2017/12/08 20:58:45 CET] [INFO] Starting 8 websocket hubs
[2017/12/08 20:58:45 CET] [INFO] Starting workers
[2017/12/08 20:58:45 CET] [INFO] Starting schedulers.

Hi @timscha, I’ve got exactly the same problem and error messages after upgrading from v4.3.0 to v4.4.3. Have you figured out how to solve it?

Hi @timscha @heartbleeded

Can you confirm you followed the upgrade guide?

@lindy65 Yes, I followed them (with exception, that I made no database backup :expressionless: ).
For further informations: I use Debian 9 with Maria DB 10.2.

I fixed it for me with a clean installation now, because luckily at the moment it’s only a test installation.

@timscha @heartbleeded can I ask you both to confirm the value of the setting "Forward80To443" in your Mattermost config.json files?

1 Like

This is really strange! Just wanted to update von 4.4.3 to 4.4.5 and got exactly the same issue again! :expressionless:

Forward80To443 is set to true.

Edit: I tried it to set it to false and et voilá, it’s working again. :thinking: If I enable it again and restarting mattermost I got the same problem again.
Just for the record: I use the provided configuration for nginx with Let’s Encrypt.

1 Like

Thanks @timscha - we’re receiving a number of reports like this related to that config setting. I’m not sure exactly what’s going on yet, but I thought this sounded like the same problem. Will update here when there’s a concrete answer about what’s wrong and what to do about it.

Thank you for your help! @grundleborg :slight_smile:

The problem was fixed by setting "Forward80To443": false. Thank you guys!

1 Like

Thanks @grundleborg :slight_smile:

I’ll leave this issue open for now until we can let @timscha and @heartbleeded know what’s wrong and how to solve it.

I was having the same issue too. But it’s fixed now after setting “Forward80To443”: false. Thanks team.

I have the full answer to this now. Prior to v4.4.0, Mattermost ignored any failure to bind to Port 80 when this setting was set to true. Since 4.4.0, it now fails on startup if the setting is true and it is unable to bind to Port 80. If you have some other web server already binding to Port 80 and acting as a proxy for Mattermost, e.g. Apache or nginx, then the correct solution is to set this config value to false.

Thank you for the clarification @grundleborg!