40 lines
772 B
INI
40 lines
772 B
INI
[mysqld]
|
||
# 基础配置
|
||
port=3306
|
||
# 使用相对路径,避免路径空格问题
|
||
basedir=.
|
||
datadir=.\data
|
||
|
||
# 字符集配置
|
||
character-set-server=utf8mb4
|
||
collation-server=utf8mb4_unicode_ci
|
||
|
||
# 存储引擎
|
||
default-storage-engine=INNODB
|
||
|
||
# 连接配置
|
||
max_connections=200
|
||
# 绑定到所有地址(允许127.0.0.1访问)
|
||
bind-address=0.0.0.0
|
||
# 允许TCP/IP连接
|
||
skip-networking=0
|
||
# 启用命名管道(Windows)
|
||
enable-named-pipe
|
||
|
||
# 跳过DNS反向解析(提升连接速度)
|
||
skip-name-resolve
|
||
|
||
# 禁用性能模式(节省内存)
|
||
performance_schema=OFF
|
||
|
||
# 注意:MySQL 8.0 已移除 query cache 功能
|
||
# query_cache_size 和 query_cache_type 配置项已不再支持
|
||
|
||
[mysql]
|
||
default-character-set=utf8mb4
|
||
|
||
[client]
|
||
default-character-set=utf8mb4
|
||
port=3306
|
||
|