Jump to content
  • разработка интернет магазинов на opencart
  • доработка интернет магазинов на opencart

Сила падать БД в одно и тоже время утром (ошибка в посте)


Recommended Posts

Всем доброго дня. Есть проект, который успешно рилииет несколько лет. Стоит на мощном отгдельно гдедике.

Но в последнее время именно утром в одно и тоже время сила появляться 500 ошибка пока не перезапустишь mariadb.

В кроне нет задач на это время.

Вот error лог:

 

 PHP Fatal error:  Uncaught exception 'Exception' with message 'Error: Out of resources when opening file 
'/var/tmp/MYmBLdhE' (Errcode: 24)<br />Error No: 23<br />SELECT LOWER(`keyword`) as 'keyword', `query` FROM oc_url_alias ORDER BY url_alias_id' in 
/home/admin/web/XXXXXXXX.com/public_html/system/library/db/mysqli.php:40\nStack trace:\n#0 
/home/admin/web/XXXXXXXX.com/public_html/system/library/db.php(16): DB\\MySQLi->query('SELECT LOWER(`k...', Array)\n#1 
/home/admin/web/XXXXXXXX.com/public_html/system/storage/modification/catalog/controller/startup/seo_pro.php(9): 
DB->query('SELECT LOWER(`k...')\n#2 /home/admin/web/XXXXXXX.com/public_html/system/storage/modification/system/engine/action.php(43): 
ControllerStartupSeoPro->__construct(Object(Registry))\n#3 /home/admin/web/XXXXXXX.com/public_html/system/engine/front.php(34): 
Action->execute(Object(Registry))\n#4 /home/admin/web/XXXXXXXX.com/public_html/system/engine/front.php(19): 
Front->execute(Object(Action))\n#5 /home/admin/web/XXXXXXX.com/public_html/system/framework.php(103): Front->d in 
/home/admin/web/XXXXXX.com/public_html/system/library/db/mysqli.php on line 40

 

Товаров примерно 70 тысяч, категорий тоже несколько тысяч.

Параметры my.cnf на сервере-

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
symbolic-links=0

skip-external-locking
key_buffer_size = 256M
max_allowed_packet = 320M
table_open_cache = 1024
sort_buffer_size = 1M
read_buffer_size = 1M
read_rnd_buffer_size = 4M
myisam_sort_buffer_size = 256M
thread_cache_size = 16
query_cache_size= 64M
thread_concurrency = 8
open_files_limit = 1000000
tmp_table_size = 128M
max_heap_table_size = 128M

#innodb_use_native_aio = 0
innodb_file_per_table

max_connections=1000
max_user_connections=1000
wait_timeout=640
interactive_timeout=640
long_query_time=5

#slow_query_log=1
#slow_query_log_file=/var/log/mysql-slow-queries.log


[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid

#
# include all files from the config directory
#
!includedir /etc/my.cnf.d

 

Куда копать? Есть мысли, друзья?
 

Link to comment
Share on other sites


17 minutes ago, AlexDW said:

проверьте какое фактически значение в open_files_limit

как вариант посмотрите згдесь

https://qastack.ru/unix/152186/mysql-max-open-files-more-than-1024

 

 

1024 фактическое.

Изменение через limits.conf  или my.cnf не спасают. ПЕрезапуски гдемона, сервера и сервера БД тоже. Лимиты по запросу show global variables like 'open%';   - 1024

Ситьи подобные уже лиил. Не понимаю в чем гдело.

Link to comment
Share on other sites


Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.