mysql的rpm安装
来源:互联网 发布:金融建模需要会编程吗 编辑:程序博客网 时间:2024/05/16 06:51
MYSQL在centos6中的安装
- MYSQL在centos6中的安装
- 需要下载的包
- 需要下载三个rpm软件包
- 安装
- 修改配置文件位置
- 初始化MySQL及修改MySQL默认的root密码
- 设置MySQL服务开机自启动
- 需要下载的包
- 安装过程的错误的解决
- 远程连接
需要下载的包
需要下载三个rpm软件包:
MySQL-client-5.6.21-1.rhel5.x86_64.rpm
MySQL-devel-5.6.21-1.rhel5.x86_64.rpm
MySQL-server-5.6.21-1.rhel5.x86_64.rpm
下载地址下载地址引用处:
http://dev.mysql.com/Downloads/MySQL-5.6/MySQL-server-5.6.21-1.rhel5.x86_64.rpm
http://dev.mysql.com/Downloads/MySQL-5.6/MySQL-devel-5.6.21-1.rhel5.x86_64.rpm
http://dev.mysql.com/Downloads/MySQL-5.6/MySQL-client-5.6.21-1.rhel5.x86_64.rpm
安装
rpm -ivh MySQL-server-5.6.21-1.rhel5.x86_64.rpm
rpm -ivh MySQL-server-5.6.21-1.rhel5.x86_64.rpm
rpm -ivh MySQL-client-5.6.21-1.rhel5.x86_64.rpm
可能需要安装:libaio
yum install -y libaio
修改配置文件位置。
[root@linuxidc tools]# cp /usr/share/mysql/my-default.cnf /etc/my.cnf
初始化MySQL及修改MySQL默认的root密码。
/usr/bin/mysql_install_db
ps -ef | grep mysql
netstat -anpt | grep 3306
more /root/.mysql_secret
mysql -uroot -pF6K3v_xggFoLQeiN
mysql> SET PASSWORD = PASSWORD(‘mima’);
[root@linuxidc tools]# mysql -uroot -pmima
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 6
Server version: 5.6.21 MySQL Community Server (GPL)
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
mysql>
设置MySQL服务开机自启动。
[root@linuxidc tools]# chkconfig mysql on
[root@linuxidc tools]# chkconfig mysql –list
安装过程的错误的解决
1、重点在centos6中使用mysql管理他的服务而不是mysqld
2、错误描述:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)这个问题属于mysql的服务没有开启。
解决方法:
systemctl start mysql(centos7)service mysql start(centos6)
3、错误描述:
file /usr/share/mysql/charsets/swe7.xml from install of MySQL-server-5.6.21-1.rhel5.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
解决办法:
yum remove mysql-libs
远程连接
1、mysql中执行
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '密码' WITH GRANT OPTION;
这样在物理机的外面就可以访问vm中的linux了。
引用:http://www.linuxidc.com/Linux/2015-01/111413.htm
- mysql的rpm安装
- mysql的rpm安装
- Mysql的rpm的安装
- Mysql的rpm的安装
- Linux下Mysql的rpm的安装
- Mysql的rpm的安装(原)
- Linux下Mysql的rpm的安装
- 使用RPM包进行MYSQL的安装
- linux下mysql的rpm包安装
- linux的mysql安装(rpm)
- 使用rpm安装mysql的默认目录
- rpm安装的mysql 如何卸载干净
- suse安装rpm打包方式的MySQL
- centos下的MySQL安装(rpm方式)
- RPM包安装方式的MySQL卸载
- linux 下 安装 rpm 格式 的 mysql
- mysql RPM 安装的卸载方式
- 在centos安装mysql的rpm模式
- 【iOS】返回崩溃:nested pop animation can result in corrupted navigation bar nested pop animation can re
- App相关辅助工具类
- 控制符endl与换行符'\n'的区别
- c3p0参数解释
- 时间类型数据存储的效率问题
- mysql的rpm安装
- 图片的缓存机制
- Android开发中小技巧
- 数据库错误解决随笔
- fzu2218
- 软键盘相关辅助工具类
- 上传图片 带图片预览功能
- zoomeye批量页面抓取工具
- 初始安卓基本控件_button