Go语言操作MySQL数据库
//重置密码
ALTER USER 'root'@'localhost' IDENTIFIED BY '111';
//安装插件
go get -u -v github.com/go-sql-driver/mysql
//开机启动
systemctl enable mariadb #自启动
systemctl disable mariadb #关闭自启动
//数据库的开启和关闭
systemctl status mariadb.service 服务状态
启动状体 右上的点 是绿 色
systemctl start mariadb.service 开启服务
systemctl stop mariadb.service 关闭服务
systemctl restart mariadb.service 重启服务