Extreme initial loading times when opening websites with an SQL connection #752
Replies: 4 comments 1 reply
-
I am also facing a similar problem. |
Beta Was this translation helpful? Give feedback.
-
Not with all sites, but yes I faced/facing this problem too |
Beta Was this translation helpful? Give feedback.
-
This isn't an issue directly with laragon. If you run a mysql/mariadb seperately from laragon, shut it down completely and start it back up same issue occurs. I believe its an issue with mysql loading specific tables into memory and setting up cache for the first load. The larger the database gets the longer it seems to take - it is more apparent when the application pulls a lot of data from seperate tables (wordpress is a good example that does this). If anyone might happen to know how to some how save caching or have some sort of resume function of mysql/mariadb that would be amazing. As this issue for my dev machine can be quite annoying. Longest time is about 4 minutes I have experienced before (this is on quite beefy machine specs as well) |
Beta Was this translation helpful? Give feedback.
-
@hotpixelsdesign : You should try optimizing tables: https://www.singlestore.com/blog/mysql-optimize-table/ |
Beta Was this translation helpful? Give feedback.
-
Laragon is currently used with Apache 2.4.58 (win64-VS17) together with MySQL 8.0.36 (win64) and PHP 8.1.9 (Win32-vs16-x64).
When I initially open a website, the loading time for a normal HTML or PHP page is a few milliseconds.
As soon as a database connection needs to be established (e.g. WordPress website), the first access to the website takes an incredibly long time (dev tools shows: waiting time between 20 and 35 seconds). Once the page has been accessed in the browser, the waiting time is around 1 second and the page loads quickly.
I would like to know why this is or how I can change this. Do you have any ideas about which (database) settings I might need to adjust for this?
Beta Was this translation helpful? Give feedback.
All reactions