当前位置: 技术问答>linux和unix
求助:linux下安装mysql解压后./configure -- prefix提示没有那个文件或目录
来源: 互联网 发布时间:2017-01-22
本文导语: 下面是我操作流程,请大家指点: 解压 1、[root@localhost home]# tar -zxvf mysql-5.5.18-linux2.6-i686.tar.gz 解压后得到 2、[root@localhost home]# ls mysql-5.5.18-linux2.6-i686 mysql-5.5.18-linux2.6-i686.tar.gz 3、[root@localhost home]# cd mysql-5.5.1...
下面是我操作流程,请大家指点:
解压
1、[root@localhost home]# tar -zxvf mysql-5.5.18-linux2.6-i686.tar.gz
解压后得到
2、[root@localhost home]# ls
mysql-5.5.18-linux2.6-i686 mysql-5.5.18-linux2.6-i686.tar.gz
3、[root@localhost home]# cd mysql-5.5.18-linux2.6-i686
4、[root@localhost mysql-5.5.18-linux2.6-i686]#ls
bin data include lib mysql-test scripts sql-bench
COPYING docs INSTALL-BINARY man README share support-files
5、提示错误:
[root@localhost mysql-5.5.18-linux2.6-i686]# ./configure --prefix=/home/mysql
-bash: ./configure: 没有那个文件或目录
查看里面Installing文件有提示:
Nnstall and use a MySQL binary distribution, the basic command
sequence looks like this:
shell> groupadd mysql
shell> useradd -r -g mysql mysql
shell> cd /usr/local
shell> tar zxvf /path/to/mysql-VERSION-OS.tar.gz
shell> ln -s full-path-to-mysql-VERSION-OS mysql
shell> cd mysql
shell> chown -R mysql .
shell> chgrp -R mysql .
shell> scripts/mysql_install_db --user=mysql
shell> chown -R root .
shell> chown -R mysql data
# Next command is optional
shell> cp support-files/my-medium.cnf /etc/my.cnf
shell> bin/mysqld_safe --user=mysql &
# Next command is optional
shell> cp support-files/mysql.server /etc/init.d/mysql.server
A more detailed version of the preceding description for
installing a binary distribution follows.
Note
看不太懂。
初学linux希望能得到大家的帮助,最好能详细每一步,谢谢!
解压
1、[root@localhost home]# tar -zxvf mysql-5.5.18-linux2.6-i686.tar.gz
解压后得到
2、[root@localhost home]# ls
mysql-5.5.18-linux2.6-i686 mysql-5.5.18-linux2.6-i686.tar.gz
3、[root@localhost home]# cd mysql-5.5.18-linux2.6-i686
4、[root@localhost mysql-5.5.18-linux2.6-i686]#ls
bin data include lib mysql-test scripts sql-bench
COPYING docs INSTALL-BINARY man README share support-files
5、提示错误:
[root@localhost mysql-5.5.18-linux2.6-i686]# ./configure --prefix=/home/mysql
-bash: ./configure: 没有那个文件或目录
查看里面Installing文件有提示:
Nnstall and use a MySQL binary distribution, the basic command
sequence looks like this:
shell> groupadd mysql
shell> useradd -r -g mysql mysql
shell> cd /usr/local
shell> tar zxvf /path/to/mysql-VERSION-OS.tar.gz
shell> ln -s full-path-to-mysql-VERSION-OS mysql
shell> cd mysql
shell> chown -R mysql .
shell> chgrp -R mysql .
shell> scripts/mysql_install_db --user=mysql
shell> chown -R root .
shell> chown -R mysql data
# Next command is optional
shell> cp support-files/my-medium.cnf /etc/my.cnf
shell> bin/mysqld_safe --user=mysql &
# Next command is optional
shell> cp support-files/mysql.server /etc/init.d/mysql.server
A more detailed version of the preceding description for
installing a binary distribution follows.
Note
看不太懂。
初学linux希望能得到大家的帮助,最好能详细每一步,谢谢!
|
shell> useradd -s /sbin/nologin mysql #建一个mysql用户、组
shell> cp support-files/my-medium.cnf /etc/my.cnf #先复制配置文件
shell> scripts/mysql_install_db --user=mysql #初始化数据库
shell> chown -R root .
shell> chown -R mysql data #更改权限
shell> bin/mysqld_safe --user=mysql & #后台运行服务
把mysql/bin目录添加到全局PATH变量去。
运行mysql -u root 就行了。
shell> cp support-files/mysql.server /etc/init.d/mysqld #将mysql添加为系统服务
shell> chmod +x /etc/init.d/mysqld #添加执行权限
你按照这样的步骤重新试一下呗。
shell> cp support-files/my-medium.cnf /etc/my.cnf #先复制配置文件
shell> scripts/mysql_install_db --user=mysql #初始化数据库
shell> chown -R root .
shell> chown -R mysql data #更改权限
shell> bin/mysqld_safe --user=mysql & #后台运行服务
把mysql/bin目录添加到全局PATH变量去。
运行mysql -u root 就行了。
shell> cp support-files/mysql.server /etc/init.d/mysqld #将mysql添加为系统服务
shell> chmod +x /etc/init.d/mysqld #添加执行权限
你按照这样的步骤重新试一下呗。
|
安装里面写的一步步操作吧。
不用编译了