Memory and SWAP 100%

Hi,

Memory and SWAP are full at everytime. I have done bench restart and mariadb restart.
After few times it will be okay, then again frappe scheduler will eat whole memory and swap.

ERPnext is too slow to process single transaction.

HTOP

2 Likes

Check your email queue and see if there are a lot of unsent emails. If yes, try suspending emails and check if the system speeds up. I had similar issue and it was a badly configured notification that generated huge amount of emails every day. Email send is a resource hungry process.

Faced similar situation. Its not ERPNext but MariaDB issue. On backup it takes the RAM but does not release it. There are many posts across the net with similar issue but no resolution.

@Muzzy
I think that was the same issue. Once we give the backup, mysql not releasing RAM after completing backup.

I tried to check the bottle neck, there no jobs pending and disabled emails and deleted emails queues.

Still the same issue.

Coming from Muzzy’s post do you also use ubuntu? I wonder if rhel derivatives face same issue. Thanks in advance :slight_smile:

Tested it on Ubuntu 18 and 20. Both facing similar issue. It happened yesterday on a Ubuntu 20 server which had original db. Hadn’t done db restoration on it.

@Muzzy it is really weird, I hope things turn around for you :wink:

Just to inform. I’m on version-12 and CentOS (now migrated to AlmaLinux). I also backed up and restored sites from old server to new server.
But I didn’t experience this memory issue.

@rahy
It was running perfectly fine with version 12 and Ubuntu 16.04. I have been doing db and file back / restore in that.

After upgrading ubuntu 18.04 with erp 13, I started noticing about memory.

Try this and let us know if works

@Muzzy
Its same. no difference.

@Muzzy
Any other solution to work out

No solution yet. It is an upstream pkg issue with mariadb.

Currently we have a temporary fix to restart sql every night which is not a good solution but it does the work.

1 Like

Sort out the issue by increasing Server RAM from 8GB to 16GB.

Actually, there is the same issue even 64GB in my VM. So, actually increasing RAM is not a solution. It is an upstream package of mariadb should be handled and solved.