初始化数据库
注:
启动数据库
/usr/local/mysql/bin/mysqld --initialize-insecure --user=mysql --basedir=/usr/local/mysql --datadir=/data/mysql
设置数据库密码
dbrootpwd=oneinstack #数据库root密码 /usr/local/mysql/bin/mysql -e "grant all privileges on *.* to root@'127.0.0.1' identified by "$dbrootpwd" with grant option;" /usr/local/mysql/bin/mysql -e "grant all privileges on *.* to root@'localhost' identified by "$dbrootpwd" with grant option;"
感谢阅读,希望能帮助到大家,谢谢大家对本站的支持!








