Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

dailysleaze's avatar

Ubuntu 50% slower than Debian?

I've moved a greenfield project from Debian 9 to Ubuntu 20.04 so we can use php 7.4 on an LTS distro. The system isn't live yet, but the Laravel http response times on Debian are about 80-110ms whereas Ubuntu it's 140-160ms.

The only thing different is the OS and php 7.3 on Debian, 7.4 on Ubuntu. Could PHP have lost that much performance between versions, or is Ubuntu that much slower?

  • Server specs, Debian is worse on paper!
    • Debian = 1vCPU, 1.7gb, 10gb HDD
    • Ubuntu = 1vCPU, 3.5gb, 15gb SSD
  • Connecting directly to the server's public IP with no SSL
  • Not a live system so no load other than healthcheck pings running in the background every minute
  • The databases are the same, Postgres 12, and they are light on data and identical.
  • The server setup is the same, nothing fancy, just Apache and supervisor and base PHP installs with a few extensions.
  • Both in the same data centre on Google Cloud
  • PHP packages are the same
  • The page measured on is the homepage, which basically does nothing other than render a blade view
  • Laravel versions are the same, 6.18.26 and the code is identical

Any other thoughts?

0 likes
2 replies
dailysleaze's avatar

Thanks for the link. I'm generally impressed with the response times and the Google cloud stack is pretty good, it's just I don't want to be installing php packages into Linux, which is what it would take to get php 7.4 even on Debian 10 https://wiki.debian.org/PHP

Its's basically that those response times are for the simple pages, but the more meaty pages may get even slower, i'd prefer not to lose 40-50% just for the hell of it. Many of the site's users will be far from cloud-based datacenters (Africa) or on flaky internet connections, so keeping the speed as good as possible is paramount.

Maybe then it's a choice between best performance and most recent php version (which is counter intuitive 😂)

Please or to participate in this conversation.