1

We are experiencing high load on our dedicated servers lately. Users see the error message

"can not connect right now. can not assign requested address"

popping up randomly.

We have 2 Linux application servers, running the lightspeed web server and 1 mysql/mariadb database server.

We are not sure, if this error is coming from the web server or mysql.

Is there anything we can change in our config, to stop this error coming up?

peterh
  • 4,953
  • 13
  • 30
  • 44

1 Answers1

1

I think we will need more information in order to help you (what kind of server, cpu, memory etc). But here are some basic items to check:

  1. Run top to see which processes are taking up the highest memory and cpu. You can also run free -m to see memory usage.
  2. Based on the above output check lsof|grep <app_name> to see what files are open. This will tell you which application to focus on.
  3. netstat -vatnl |grep TIME_WAIT or netstat -tulpen |grep <PORT>. This is to check TCP connections and status. The "cannot assign" message seems to be related with networking binding or TCP sockets. So you should also check your tcp settings such as net.core.somaxconn or net.ipv4.tcp_max_syn_backlog. There are tons of guides out there to tune these values for web and database servers.
  4. For mysql load and performance, you can run SHOW PROCESSLIST from the mysql prompt. This will provide a list of all current queries. For example, here you can identify a query that has a long runtime.

Hope this helps. Good luck!

Tux_DEV_NULL
  • 1,093
  • 7
  • 11