[英]Invalid packet type error using php_mysql_xdevapi
I am trying to connect to mysql 8.0.15 using php_mysql_xdevapi but getting following errror. 我正在尝试使用php_mysql_xdevapi连接到mysql 8.0.15,但出现以下错误。
Notice: mysql_xdevapi\\getSession(): send of 5 bytes failed with errno=10053 An established connection was aborted by the software in your host machine.
注意:mysql_xdevapi \\ getSession():5个字节的发送失败,错误码为errno = 10053主机中的软件中止了已建立的连接。
Fatal error: Uncaught mysql_xdevapi\\Exception: [2000][HY000] The server sent invalid packet type I am using
致命错误:未捕获的mysql_xdevapi \\ Exception:[2000] [HY000]服务器发送了我正在使用的无效数据包类型
Windows 10 Windows 10
Finally after 2 days of searching, I make php_mysql_xdevapi work on windows using wampserver. 最终,经过2天的搜索,我使用wampserver使php_mysql_xdevapi在Windows上工作。
Steps to make php_mysql_xdevapi work on windows 10, using wamp. 使用wamp使php_mysql_xdevapi在Windows 10上运行的步骤。
extension=php_mysql_xdevapi
extension=php_mysql_xdevapi
Be default in wamp the XPlugin is disable enable it in my.ini 在Wamp中默认将XPlugin禁用,然后在my.ini中启用它
;Disabling X Plugin ;mysqlx=0
use this to connect to mysql using php_mysql_xdevapi 使用它使用php_mysql_xdevapi连接到mysql
$session = mysql_xdevapi\\getSession('mysqlx://root:123@localhost:33060?connect-timeout=5000&ssl-mode=disabled');
Now you can use this to further query in mysql document store. 现在您可以使用它在mysql文档存储中进一步查询。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.