본문 바로가기

Linux

Install RPM of MySQL 5.5.27 on CentOS 5.8

1. Download for MySQL5.5.27 RPM version

2. unzip

3. rpm -Uvh MySQL*

4. service mysql start

5. /usr/bin/mysqladmin -u root password 'PASSWORD'

6. mysql -u root -p mysql


============================================

[root@localhost doc]# cd /tmp/


[root@localhost tmp]# ls
MySQL5.5.27.RedHatEL4.x86.zip  keyring-QrASWV     scim-bridge-0.3.0.lockfile-0@localhost:0.0 


[root@localhost tmp]# unzip MySQL5.5.27.RedHatEL4.x86.zip
Archive:  MySQL5.5.27.RedHatEL4.x86.zip
 extracting: MySQL-test-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-shared-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-embedded-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-devel-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-client-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-shared-compat-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: MySQL-server-advanced-5.5.27-1.rhel4.i386.rpm 
 extracting: README.txt             


[root@localhost tmp]# ll
합계 552752
-rw-r--r-- 1 root root      2169  9월 27 14:16 650d5882.txt
-rw-r--r-- 1 root root  16900151  7월 23 11:36 MySQL-client-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root   6265191  7월 23 11:36 MySQL-devel-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root  61839237  7월 23 11:37 MySQL-embedded-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root  51974343  7월 23 11:37 MySQL-server-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root   1921484  7월 23 11:38 MySQL-shared-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root   4965294  7월 23 11:38 MySQL-shared-compat-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root  39647687  7월 23 11:38 MySQL-test-advanced-5.5.27-1.rhel4.i386.rpm
-rw-r--r-- 1 root root 191337776  9월 27 14:50 MySQL5.5.27.EL5.x86.zip
-rw-r--r-- 1 root root 183522795  9월 27 14:51 MySQL5.5.27.RedHatEL4.x86.zip
-rw-r--r-- 1 root root      8116  8월  2 17:55 README.txt


[root@localhost tmp]# rpm -Uvh MySQL*.rpm
준비 중...               ########################################### [100%]
   1:MySQL-shared-compat-adv########################################### [ 14%]
   2:MySQL-client-advanced  ########################################### [ 29%]
   3:MySQL-devel-advanced   ########################################### [ 43%]
   4:MySQL-embedded-advanced########################################### [ 57%]
   5:MySQL-server-advanced  ########################################### [ 71%]

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:

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

Alternatively you can run:
/usr/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.

Please report any problems with the /usr/bin/mysqlbug script!

   6:MySQL-shared-advanced  ########################################### [ 86%]
   7:MySQL-test-advanced    ########################################### [100%]


[root@localhost tmp]# service mysql start
Starting MySQL..                                           [  OK  ]


[root@localhost tmp]# /usr/bin/mysqladmin -u root password centos


[root@localhost tmp]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.5.27-enterprise-commercial-advanced MySQL Enterprise Server - Advanced Edition (Commercial)

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> show tables;
+---------------------------+
| Tables_in_mysql           |
+---------------------------+
| columns_priv              |
| db                        |
| event                     |
| func                      |
| general_log               |
| help_category             |
| help_keyword              |
| help_relation             |
| help_topic                |
| host                      |
| ndb_binlog_index          |
| plugin                    |
| proc                      |
| procs_priv                |
| proxies_priv              |
| servers                   |
| slow_log                  |
| tables_priv               |
| time_zone                 |
| time_zone_leap_second     |
| time_zone_name            |
| time_zone_transition      |
| time_zone_transition_type |
| user                      |
+---------------------------+
24 rows in set (0.00 sec)

mysql> create database itbank;
Query OK, 1 row affected (0.00 sec)

mysql>
mysql> use itbank
Database changed
mysql>