Hi everyone, I installed Discourse and everything works, but unfortunately the site is extremely slow when opening for the first time. I installed Discourse on aaPanel and configured nginx, although nginx is down, the site works. Unfortunately, it’s very slow when opening for the first time and then reloads quickly. How can I fix this? It’s quite a serious problem because I can’t index it.
My Discourse site is hosted on the Namecheap Pulsar VPS:
2 CPU cores
2 GB RAM
40 GB SSD RAID 10
1000 GB bandwidth
Ideally you shouldn’t be using any “panel” on the server you use to host discourse.
Your VPS provider is likely over provisioning their resources and that is the likely reason for the slow load, another contributor could be slow or congested network at your provider’s end or ISP’s end.
Subsequent loads are fast because the resources have already been downloaded, the app only needs small payloads to refresh the latest data. This is the beauty of discourse.
The 342kb font file is served at a mere 83 kB/s, taking over 4 seconds. For comparison, downloading that same file from here on meta takes 0.01 second.
Pages do serve quickly so my guess is that it’s your disk that is slow.
Quick fix: put Cloudflare in front
Better fix: get another VPS provider