mysql5.6.4m7 linux安装_mysql-5.6.4-m7installinlinux

安装的mysql数据库是:mysql-5.6.4-m7,这个版本的数据库要用cmake工具安装。CMake是一个跨平台的安装(编译)工具,可以用简单的语

安装的mysql数据库是:mysql-5.6.4-m7,这个版本的数据库要用cmake工具安装。

CMake是一个跨平台的安装(编译)工具,可以用简单的语句来描述所有平台的安装(编译过程)。他能够输出各种各样的makefile或者project文件,能测试编译器所支持的C++特性,类似UNIX下的automake

cmake下载地址:

1、安装cmake

[root@localhost tmp]# cd cmake-2.8.9/

[root@localhost cmake-2.8.9]# ./bootstrap

[root@localhost cmake-2.8.9]#make

[root@localhost cmake-2.8.9]#make install

如果要更新cmake 只需进入相关目录,,执行

cmake.

make

make install

2、安装mysql

[root@localhost mnt]# cd mysql-5.6.4-m7/

[root@localhost mnt]# cmake .

可能回出现下面问题:

-- Could NOT find Curses (missing: CURSES_LIBRARY CURSES_INCLUDE_PATH)

CMake Error at cmake/readline.cmake:83 (MESSAGE):

Curses library not found. Please install appropriate package,

remove CMakeCache.txt and rerun cmake.On Debian/Ubuntu, package name is libncurses5-dev, on RedHat and derivates it is ncurses-devel.

Call Stack (most recent call first):

cmake/readline.cmake:136 (FIND_CURSES)

cmake/readline.cmake:226 (MYSQL_USE_BUNDLED_LIBEDIT)

CMakeLists.txt:262 (MYSQL_CHECK_READLINE)

按照上面内容提示的方法进行修改:

若是redhat 安装ncurses-devel这个包即可。

[root@localhost mysql-5.6.4-m7]# yum install ncurses-devel*

[root@localhost mysql-5.6.4-m7]# rm CMakeCache.txt (注意这里是删除CMakeCache.txt ,有一个跟他很相似的文件,别删错了!)

[root@localhost mysql-5.6.4-m7]#make

[root@localhost mysql-5.6.4-m7]#make install

3、安装默认的数据库

[mysql@localhost mysql]$ cd scripts/

[mysql@localhost scripts]$ ls

[mysql@localhost scripts]$ sudo ./mysql_install_db --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data/ --user=mysql

安装完后有这么一段提示,可以仔细看看:

To start mysqld at boot time you have to copy

support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !

To do so, start the server, then issue the following commands:

/usr/local/mysql//bin/mysqladmin -u root password 'new-password'

/usr/local/mysql//bin/mysqladmin -u root -h localhost.localdomain password 'new-password'

Alternatively you can run:

/usr/local/mysql//bin/mysql_secure_installation

which will also give you the option of removing the test

databases and anonymous user created by default. This is

strongly recommended for production servers.

See the manual for more instructions.

You can start the MySQL daemon with:

cd /usr/local/mysql/ ; /usr/local/mysql//bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl

cd /usr/local/mysql//mysql-test ; perl mysql-test-run.pl

logo.gif

本条技术文章来源于互联网,如果无意侵犯您的权益请点击此处反馈版权投诉

本文系统来源:php中文网

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值