Environment
RedHat Linux 6.1 + MySQL 5.1.7
Problem
RedHat Linux 6.1 Install MySQL
Prepare before installation
1. Download resources:
MYSQL-SERVER-5.1.7-0.I386.RPM, click here to download.
MYSQL-CLIENT-5.1.7-0.I386.RPM, click here to download.
2. Login system check if MySQL has been installed
3. Copy two installation files to your own directory.
Formal Installation
1. Installation service side, RPM-IVH mysql-server-5.1.7-0.i386.rpm
Displays the following information.
warning:mysql-server-5.1.7-0.i386.rpm
Signature:nokey, key ID 5072e1f5
preparing ... ###################### ##################### [100%]
1:mysql-server ########################################### [100%]
Check for Successful installation: Ps–aux | grep "MySQL"
2. Install client, RPM-IVH mysql-client-5.1.7-0.i386.rpm
Displays the following information.
Warning:mysql-client-5.1.7-0.i386.rpm:v3 DSA Signature:nokey, key ID 5072e1f5
preparing ... ##################### ###################### [100%]
1:mysql-client ########################################### [100%]
3. Login mysql,mysql–uroot–p, direct return,
Welcome to the MySQL Monitor. Commands End With; or \g.
Your MySQL Connection ID is 1 to server Version:5.1.7-standard
Type ' help; '/' \h ' for help. Type ' \c ' to clear the buffer.
Mysql>
4. Modify password, mysqladmin-u root password ' new-password '
Format: Mysqladmin-u username-P Old password password new password
such as Mysqladmin–u root–p root (because no initial password, so the old password is empty)
5. Start, stop, restart MySQL
Start: Service mysqld start
stop: Service mysqld stop restart
: service mysqld restart