当前位置:首页 > 操作系统 > MacOs

mac mysql

启动

$ mysql.server start
Starting MariaDB
.190106 15:41:13 mysqld_safe Logging to '/usr/local/var/mysql/mbp.err'.
190106 15:41:13 mysqld_safe Starting mysqld daemon with databases from /usr/local/var/mysql
 SUCCESS!

测试

$ lsof -i tcp:3306
COMMAND   PID  USER   FD   TYPE             DEVICE SIZE/OFF NODE NAME
mysqld  13227 gavin   23u  IPv6 0x1e91d7e2467e6349      0t0  TCP *:mysql (LISTEN)

连接

$ mysql -u root
Welcome to the MariaDB monitor.  Commands end with ; or g.
Your MariaDB connection id is 9
Server version: 10.3.11-MariaDB Homebrew

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.

MariaDB [(none)]>

【说明】本文章由站长整理发布,文章内容不代表本站观点,如文中有侵权行为,请与本站客服联系(QQ:254677821)!

相关教程推荐

其他课程推荐