以下是以5.4-RELEASE-p6+mysql-4.0.25为例
cd /usr/ports/databases/mysql40-server
make install clean;
/usr/local/bin/mysql_install_db
chown -R mysql /var/db/mysql
##这一步一定不能少,否则mysql将启动不起来
启动mysql
/usr/local/bin/mysqld_safe &
或者/usr/local/etc/rc.d/mysql-server.sh start
/usr/local/bin/mysqladmin -u root password ‘123456′
#一定要做这个,否则不安全的
---------------------
作者:AlexJia2046
来源:CSDN
原文:https://blog.csdn.net/alexdream/article/details/2314992
版权声明:本文为博主原创文章,转载请附上博文链接!

发表评论

邮箱地址不会被公开。 必填项已用*标注