ERPNext running slow

try innodb_buffer_pool_size = 70% of your ram = 5gb

Woah! Its too dangerous to set any values without knowing impact, never follow values from internet articles and guides as most of the times those are for reference only and it is expected you know what you are doing while using it.

Instead use simplest and easiest way to get correct values according to your live environment to optimize your database.
Try MySQLTuner > https://github.com/major/MySQLTuner-perl (it works with MySQL/MariaDB)

1 Like

I followed all the recommendation from mysql tuner
but nothing works…still my system is slow, even alloted 5gb of total 8gb ram to innodb_buffer_pool_size

check slow query log

@hereabdulla Share output of MySQL Tuner in text format (no screenshot)

Increase memory in redis_cache.conf

It is showing 50mb Idont know maximum how much I can give

Dear @rmehta, @Jay, @anand , @yashodhan
Thank u all for the reply…
Now My system is fast enough But I have a strange problem whatever may be the system,when I am login through Administrator account it working fast enough but when I login through any other user account then it become dead slow…today only I found this problem…is there any different approach for this…

Dear Frndz…
is there any solution for the above

@hereabdulla checking the slow query log will show you the bottleneck

@anand thanx for ur reply…
There is no slow query log registered in my system.

and the system is fast when I login through admin account in any system…but any other user account except admin, it is slow…that is strange…

@hereabdulla

Please check documentation for MariaDB (it is 3rd party thing)

The slow query log is disabled by default. To enable it, set the slow_query_log system variable to 1.

@hereabdulla maybe some of the permission configuration is slowing down the system. Slow query logs will help to investigate the issue.

Slow query log shows nothing but stills system get slow loading (mostly in list loading)

here slow query output,as I mentioned earlier whatever may be the system when I login through Administrator account it loads faster but logging through other account become slow…

/usr/sbin/mysqld, Version: 10.0.24-MariaDB-1~trusty (mariadb.org binary distribution). started with:
    Tcp port: 3306  Unix socket: /var/run/mysqld/mysqld.sock
    Time                 Id Command    Argument

It seems you have GUI loaded on server, does it serve any other purpose?

If you are in local environment, its not just MySQL, but you will also need to optimize Nginx, SocketIO, Redis workers to manage the load, plus you will also need to checkout Network level slow downs, are you used Managed switch or simple/unmanaged switch because that also makes big difference in terms of serviceability and QOS.

You should use newrelic.com APM and Server Monitoring to actually findout root cause, or simply change the server… :wink:

where can i find " redis cache " so i can change the value for it.

@Ajay_Kakde

This https://redis.io/docs/management/config/ refers to maxmemory.

frappe@erpnext:~/frappe-bench$ find . -name *.conf | xargs grep 'maxmemory'
./config/redis_cache.conf:maxmemory 50mb
./config/redis_cache.conf:maxmemory-policy allkeys-lru

Thanks for reply clarkej

May refer to this link : ERPNext setup on Antix Linux - #6 by NeisSenni. It does minor changes in Redis configuration file.

@hereabdulla Did you find any solution ?

1 Like