Home >Backend Development >PHP Tutorial >mysql problem: solution to Too many connections

mysql problem: solution to Too many connections

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-07-25 08:58:371429browse
  1. [mysqld]
  2. port = 3306
  3. socket = /tmp/mysql.sock
  4. skip-locking
  5. key_buffer = 160M
  6. max_allowed_packet = 1M
  7. table_cache = 64
  8. sort_buffer_size = 512K
  9. net_buffer_length = 8K
  10. read_buffer_size = 256K
  11. read_rnd_buffer_size = 512K
  12. myisam_sort_buffer_size = 8M
  13. max_connections=1000
Copy code

Of course, you also need to develop good programming habits and achieve reasonable use and recycling of resources, so that your PHP program will be more efficient. This will reduce the occurrence of errors like too many connections.



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn