I am accessing a few Rest API end points to create sales invoices through the Rest API. My server is at Google Cloud. When I keep creating some sales invoices through the API in a row the server becomes unavailable and becomes available after a while.
Could someone help me fixing this issue? Is there any configuation I should do to allow external connections?
Is there anyone from ERPNext team at least to get an answer for this? At least a little guidance for this would be really appreciated.
You have not provided any information about your setup. How can someone help you?
Thanks @kevingee! I was expecting a general guidance. In terms the setup, I am using following.
App server - 1 vCPU, 2.25 GB memory (Only Frappe/ERPNext is installed on this server)
DB server - 2 vCPUs, 4 GB memory (MariaDB is installed on this server)
The servers are communicating through internal IP’s
Application is configured to DNS based multi-tenancy. Total of 12 users are using ERPNext and but about 1 user at a particular time. The Maria DB server was upgraded recently from a micro instance (0.6 GB of RAM) to the above configuration.
The setup was there for more than a year now without any issues. The issue came only when I was creating sales invoices through a mobile application accessing ‘Sales Invoice’ Rest endpoint.
I was creating about 10 sales invoices in a go through the Rest endpoint and suddenly receiving no response from the server. No error though.
Done the following checks while the issue was there.
- Can ping to the application server through both domain name and the public IP
- Checked the service status by running the command ‘sudo supervisorctl status’ and it shows all the services are running.
- Restarting all the services doesn’t bring the service back.
- Rebooted the application server and the ERPNext is working.
Hope this information is helpful.
i also experienced the same with my test server at times. i use a single 2vCPU with 8GB memory on ubuntu 18 with AWS for app and db. when api calls are made consecutively by multiple users, the server goes out. Then ERPNext is accessible only after a server restart.
Yeah, I have the same issue. Hoping someone will help us.
I believe this is because of the fail2ban service running.
Either you can stop your fail2ban service using this command /etc/init.d/fail2ban stop or you can add your IP address in ignore list.
Thanks a lot @Maheshwari_Bhavesh! This could be the culprit as it doesn’t give any error. I don’ want to disable it, instead will see how I can allow a certain type of traffic so my server is protected too.
Will update the thread after my testing.