只需一步,快速开始
tar zxvf mysql-3.23.58.tar.gz cd mysql-3.23.58 ./configure --prefix=/usr/local/mysql --sysconfdir=/etc --localstatedir=/var/lib/mysql make make install #prefix=/usr/local/mysql mysql安装的目标目录 #sysconfdir=/etc my.ini配置文件的路径 #localstatedir=/var/lib/mysql 数据库存放的路径 安装完以后要初始化数据库,当然你是升级的话不用做这步; /usr/local/mysql/bin/mysql_install_db 如果系统没有mysql这个用户的话,最好做以下这步: useradd -M -o -r -d /var/lib/mysql -s /bin/bash -c "MySQL Server" -u 27 mysql 然后我启动mysql /usr/local/mysql/bin/safe_mysqld & ok,先看看mysql能否正常工作 mysql -uroot mysql
[root@rh73 var]# mysql -uroot mysql bash: mysql: command not found
使用道具 举报
cp support-files/mysql.server /etc/rc.d/init.d/mysqld chkconfig --add mysqld 用ntsysv设置使mysql每次启动都能自动运行。 好了,至此mysql安装完毕,你可以这样起动你的mysql服务 /etc/rc.d/init.d/mysqld start
[root@rh73 mysql-3.23.58]# /etc/rc.d/init.d/mysqld start bash: /etc/rc.d/init.d/mysqld: /bin/sh: bad interpreter: Permission denied
本版积分规则 发表回复 回帖并转播 回帖后跳转到最后一页
GMT+8, 2024-11-9 00:04 , Processed in 0.039381 second(s), 16 queries .
© 2021 Powered by Discuz! X3.5.