Welcome 微信登录

首页 / 数据库 / MySQL / CentOS 5.5下RPM方式安装MySQL 5.5 详解

#rpm –qa|grep –i mysql查看已安装的mysql版本如果有已存在的mysql版本则删除安装服务端和客户端,去Oracle官网下载:# rpm -ivh MySQL-server-5.5.28-1.linux2.6.i386.rpm# rpm -ivh MySQL-client-5.5.28-1.linux2.6.i386.rpm安装后会出现以下信息,提示不要忘记设计root用户的密码以及其他信息。之后查看mysql的服务是否启动#netstat -nat如看到有3306的端口号,就说明服务启动了,默认的端口是3306 ,如果没有启动的话 ,就打开服务 #service mysql start  启动mysql服务。然后再输入mysql,若出现以下提示信息,说明成功。Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 1
Server version: 5.5.16 MySQL Community Server (GPL)Copyright (c) 2000, 2011, 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>use mysql;然后查看一下root的情况select user,password form user;修改密码update user set password=password(‘newpassword’)where user=’root’ and host=’root’ or host=’localhost’;至此mysql是安装成功了的。但是远程访问还是不行的,还有两个地方,第一是数据库设置,第二是防火墙。一般数据库已经是可以直接连接成功的了。只是没有ROOT权限,如果连不上,像我这样的,肯定是被防火墙挡住了。数据库的MYSQL表中控制的可来访的权限,因此我们要改一下它,这样我们就有ROOT权限了。
  • 1
  • 2
  • 下一页
使用crs_profile管理RAC资源配置文件ORA-01033: ORACLE initialization or shutdown in progress相关资讯      CentOS 5.5安装MySQL  CentOS MySQL5.5  MySQ安装  本文评论 查看全部评论 (0)
表情: 姓名: 字数