In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "mysql backup tips too many open files Errornumber 24 how to solve", interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Next let the editor to take you to learn "mysql backup tips too many open files Errornumber 24 how to solve it"!
one。 Description of the problem
An error is reported when the backup program rolls forward.
InnoDB: Errornumber 24 means' Too many open files'.InnoDB: Some operatingsystem error numbers are described atInnoDB: http://dev.MySQL.com/doc/mysql/en/Operating_System_error_codes.htmlInnoDB: File name/home/nice/backup/mysql/var.20121211021656/user_db_20121123/tuser_like_core.ibdInnoDB: File operationcall: 'open'.InnoDB: Cannot continueoperation. Innobackup:Error:
two。 Analysis of problems
The openfiles is too small. The open_file_limit of mysql is subject to the configuration in the following parameters max_connections, table_open_cache, open_files_limit, and / etc/security/limits.conf. The relationship between max_connections and table_open_cache and open_files_limit: max_1 = 10 + max_connections + table_cache * 2; max_2 = max_connections * 5; max_3 = the maximum allowed file handle (file descriptor) for a single process in the max_os_open_files;// operating system. Open_files_limit= max (max_1, max_2) > max_3? Max_3: max (max_1, max_2); Comprehensive analysis shows that open_files_limit | 10240, but currently there are 10800 ibd tables.
three。 Solve the problem
1.my.cnf configuration open_files_limit = 20480
Restart mysql and there is no change. Open_files_limit | 10240.
2.ulimit-a
Core file size (blocks,-c) unlimiteddata seg size (kbytes,-d) unlimitedfile size (blocks,-f) unlimitedpending signals (- I) 1024max locked memory (kbytes,-l) 32max memory size (kbytes,-m) unlimitedopen files (- n) 1024pipe size (512 bytes,-p) 8POSIX message queues (bytes -Q) 819200stack size (kbytes,-s) 10240cpu time (seconds,-t) unlimitedmax user processes (- u) 137216virtual memory (kbytes,-v) unlimitedfile locks (- x) unlimited
3.vi / etc/security/limits.conf, add
Mysql soft nofile 8192mysql hard nofile 20480
4. Restart mysql after the first three steps.
Restart mysql discovery, open_files_limit | 20480.
5. Modify OS user profile
After the first four steps, although you see open_files_limit | 20480 in mysql, ibbackup is still rolling forward. It is reported that open_file is not enough. The suspicion still didn't work.
Ulimit-acore file size (blocks,-c) unlimiteddata seg size (kbytes,-d) unlimitedfile size (blocks,-f) unlimitedpending signals (- I) 1024max locked memory (kbytes,-l) 32max memory size (kbytes,-m) unlimitedopen files (- n) 1024pipe size (512bytes,-p) 8POSIX message queues (bytes -Q) 819200stack size (kbytes,-s) 10240cpu time (seconds,-t) unlimitedmax user processes (- u) 137216virtual memory (kbytes,-v) unlimitedfile locks (- x) unlimited
Therefore, modify the OS user profile
Check. Bash_profile,. Bashrc, / etc/bashrc
Found that. Bash_profile calls .bashrc, .bashrc calls / etc/bashrc
Found that / etc/bashrc has
Ulimit-S-c unlimited > / dev/null 2 > & 1
Add after this line
Ulimit-n 20480 > / dev/null 2 > & 1
6. Restart mysql, execute backup program, in-- apply-log, still report error, report, open_file is not enough
InnoDB: Errornumber 24 means' Too many open files'.InnoDB: Some operatingsystem error numbers are described atInnoDB: http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html
7. Modify innodb_open_files parameters
The previous parameter was set to 500. This time it has been revised to 1000.
Restart mysql to resolve the problem
At this point, I believe you have a deeper understanding of "mysql backup tips too many open files Errornumber 24 how to solve", might as well come to the actual operation of it! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.