Check Limit on System
1 |
cat /proc/$(pgrep mysqld$)/limits |
1 |
nano /etc/systemd/system/multi-user.target.wants/mariadb.service |
Edit Limit on:
1 |
LimitNOFILE=65535 |
Change limit Check
1 |
mysql -v |
Enter command:
1 |
SHOW VARIABLES LIKE 'Open_files_limit'; |
Show example:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
root@b2bmails:~# mysql -v Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 5 Server version: 10.1.26-MariaDB-0+deb9u1 Debian 9.1 Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others. Reading history-file /root/.mysql_history Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. MariaDB [(none)]> SHOW VARIABLES LIKE 'Open_files_limit';. -------------- SHOW VARIABLES LIKE 'Open_files_limit' -------------- +------------------+-------+ | Variable_name | Value | +------------------+-------+ | open_files_limit | 65535 | +------------------+-------+ 1 row in set (0.00 sec) |
Sometimes you need to change another limit in the file.
1 |
nano /etc/pam.d/common-session |
ADD end line
1 |
session required pam_limits.so |
Иногда по ошибке или магии ищите лимит в файле
1 |
nano /etc/systemd/system/mysql.service.d/nofile.conf |