# Web interface crashes when behind load balancer and VPN server is started

**URL:** <https://forum.pritunl.com/t/web-interface-crashes-when-behind-load-balancer-and-vpn-server-is-started/1605>\
**Category:** Pritunl VPN\
**Tags:** pritunl\
**Created:** [December 4, 2023, 4:26pm UTC](https://forum.pritunl.com/t/web-interface-crashes-when-behind-load-balancer-and-vpn-server-is-started/1605 "2023-12-04T16:26:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tmetcalfe](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/t/779978/32.png) [@tmetcalfe](https://forum.pritunl.com/u/tmetcalfe)\
**Post date:** [December 4, 2023, 4:26pm UTC](https://forum.pritunl.com/t/web-interface-crashes-when-behind-load-balancer-and-vpn-server-is-started/1605/1 "2023-12-04T16:26:54Z")

</div>

I’m attempting to run Pritunl in an EKS cluster. I followed the docs for adding Pritunl (web) behind a load balancer and it works as expected.

I run the following as documented:

```bash
sudo pritunl set app.reverse_proxy true
sudo pritunl set app.redirect_server false
sudo pritunl set app.server_ssl false
sudo pritunl set app.server_port 80

```

However, when I create [VPN] Server in the web console and attempt to start it, the web console crashes. It appears that the VPN server continues to run until I recover it is to run

```bash
pritunl repair-database

```

at which point the VPN server stops and the web console returns. The error logs point to something which I think is unlikely to be an issue:

Application Logs (from clicking the logs button in the top right hand corner):

```auto
[evening-stars-3730][2023-12-04 11:59:55,721][ERROR] Instance doc lost, stopping server. Check datetime settings

```

I’ve checked this error, the date/time is as expected.

System logs:

```auto
   result = sock_info.command(
  File "/usr/lib/pritunl/usr/lib/python3.9/site-packages/pymongo/pool.py", line 769, in command
    self._raise_connection_failure(error)
  File "/usr/lib/pritunl/usr/lib/python3.9/site-packages/pymongo/pool.py", line 969, in _raise_connection_failure
    _raise_connection_failure(self.address, error)
  File "/usr/lib/pritunl/usr/lib/python3.9/site-packages/pymongo/pool.py", line 257, in _raise_connection_failure
    raise NetworkTimeout(msg)
pymongo.errors.NetworkTimeout: pritunl-mongodb:27017: timed out

```

MongoDB also appears to be behaving as expected despite this error message.

Is this a bug in the software? Or am I misconfiguring something?

---

<div class="post-metadata">

**Author:** ![zach](https://forum.pritunl.com/user_avatar/forum.pritunl.com/zach/32/1105_2.png) [@zach](https://forum.pritunl.com/u/zach)\
**Post date:** [December 6, 2023, 6:33pm UTC](https://forum.pritunl.com/t/web-interface-crashes-when-behind-load-balancer-and-vpn-server-is-started/1605/2 "2023-12-06T18:33:53Z")

</div>

The instance doc lost is being caused by losing connectivity to the database. If the server can’t reach the database to update the timestamp the document will expire and cause that error.

The reference to the date/time is from a more common cause when another host in the cluster has an incorrect time and incorrectly removes a document that didn’t expire.
