admin管理员组文章数量:1124667
A script writes steadily data into MySQL 8x. From time to time the script fires error
Error: getaddrinfo ENOTFOUND localhost:10006
, what should mean, MySQL unavailable.
This error wasn't an issue as long as my script wrote data in a single thread. The error still fired, but the script didn't become unresponsive. After the script writes in multiple threads (10, 20, 100), it becomes on error unresponsive (in task manager red, status 'no response') and doesn't come alive anymore.
MySQL has nothing in logs, feeling healthy and fit.
Script is a typescript on Node, everything runs on Windows VM.There is no connection pool, the script just establishes a direct connection (host/name...).
What are ways to debug and fix this? Is there something special I should consider about threaded writing into MySQL, on the script level or in MySQL configuration?
Here is myf:
[mysqld]
secure_file_priv=C:/Users/me/Downloads
event_scheduler = ON
local_infile=1
{{#unless os.windows}}
skip-name-resolve
{{/unless}}
{{#if disableMysqlx}}
mysqlx = 0
{{/if}}
datadir = {{datadir}}
port = {{port}}
bind-address = {{bindAddress}}
socket = {{socket}}
{{#if os.windows}}
console
{{/if}}
# Older PHP/client compatibility
character-set-server = utf8mb3
default_authentication_plugin = mysql_native_password
# Fine Tuning
performance_schema = off
max_allowed_packet = 1024M
thread_stack = 192K
thread_cache_size = 8
# InnoDB
innodb_buffer_pool_size = 1024M
innodb_log_file_size = 96M
[client]
{{#unless os.windows}}
socket = {{socket}}
{{else}}
host = {{clientAddress}}
port = {{port}}
{{/unless}}
user = ****
password = ****
本文标签: nodejsMySQL becomes randomly unavailableStack Overflow
版权声明:本文标题:node.js - MySQL becomes randomly unavailable - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736643262a1946046.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论