mysql_mcp_server icon indicating copy to clipboard operation
mysql_mcp_server copied to clipboard

cursor 使用mysql_mcp_server 链接mysql5.7版本异常终止

Open GithubCao opened this issue 10 months ago • 1 comments

用cursor 链接mysql_mcp_server 的mysql 5.7 版本 会在connect.connect(**config) 时候异常终止,没有返回信息; 需要增加以下配置保证正常运行 'auth_plugin': 'mysql_native_password', 'connect_timeout': 30, # 增加连接超时时间 'use_pure': True, # 使用纯Python实现 'raise_on_warnings': True 完整配置如下 config = { "host": os.getenv("MYSQL_HOST", "localhost"), "port": int(os.getenv("MYSQL_PORT", 3306)), "user": os.getenv("MYSQL_USER","root"), "password": os.getenv("MYSQL_PASSWORD"), "database": os.getenv("MYSQL_DATABASE"), 'auth_plugin': 'mysql_native_password', 'connect_timeout': 30, # 增加连接超时时间 'use_pure': True, # 使用纯Python实现 'raise_on_warnings': True }

GithubCao avatar Apr 11 '25 00:04 GithubCao

Thank you, @GithubCao, for the tip! I'm not currently using cursor, but I'm sure others will appreciate the information.

designcomputer avatar Apr 18 '25 20:04 designcomputer