mysql 버전 : mysql-5.0.67.tar.gz [5.x대의 안정버전을 사용한다.]
http://downloads.mysql.com/archives/mysql-5.0/mysql-5.0.67.tar.gz
mysql 설치경로 : /usr/local/server/mysql
[root@sms ~]# yum install re2c
[root@sms ~]# useradd -M -s /bin/false mysql
[root@sms ~]# mkdir /usr/local/src/APM
[root@sms ~]# cd /usr/local/src/APM/
[root@sms APM]# wget http://downloads.mysql.com/archives/mysql-5.0/mysql-5.0.67.tar.gz
[root@sms APM]# tar xzf mysql-5.0.67.tar.gz
[root@sms APM]# cd mysql-5.0.67
[root@sms mysql-5.0.67]# pwd
/usr/local/src/APM/mysql-5.0.67
[root@sms mysql-5.0.67]# ./configure --prefix=/usr/local/server/mysql --with-charset=utf8 --with-extra-charsets=all --with-readline
...생략
config.status: creating ib_config.h
config.status: executing depfiles commands
config.status: executing libtool commands
MySQL has a Web site at http://www.mysql.com/ which carries details on the
latest release, upcoming features, and other information to make your
work or play with MySQL more productive. There you can also find
information about mailing lists for MySQL discussion.
Remember to check the platform specific part of the reference manual for
hints about installing MySQL on your platform. Also have a look at the
files in the Docs directory.
Thank you for choosing MySQL!
[root@sms mysql-5.0.67]# make
[root@sms mysql-5.0.67]# make install
[root@sms mysql-5.0.67]# cp support-files/my-huge.cnf /etc/my.cnf
[root@sms mysql-5.0.67]# cp support-files/mysql.server /etc/init.d/mysqld
[root@sms mysql-5.0.67]# chmod 755 /etc/init.d/mysqld
[root@sms mysql-5.0.67]# chkconfig --add mysqld
[root@sms mysql-5.0.67]# chkconfig --list mysqld
mysqld 0:해제 1:해제 2:활성 3:활성 4:활성 5:활성 6:해제
[root@sms mysql-5.0.67]# chkconfig --level 24 mysqld off
[root@sms mysql-5.0.67]# chkconfig --list mysqld
mysqld 0:해제 1:해제 2:해제 3:활성 4:해제 5:활성 6:해제
[root@sms mysql-5.0.67]#
mysql 데이터베이스 초기화 및 디렉토리 퍼미션 설정
[root@sms mysql-5.0.67]# cd /usr/local/server/mysql/
[root@sms mysql]# chown -R mysql .
[root@sms mysql]# chgrp -R mysql .
[root@sms mysql]# bin/mysql_install_db --user=mysql
[root@sms mysql]# chown -R root .
[root@sms mysql]# chown -R mysql var
[root@sms mysql]# /etc/init.d/mysqld start
Starting MySQL [ OK ]
[root@sms mysql]#
root@sms의 패스워드를 설정한다.
[root@sms mysql]# /usr/local/server/mysql/bin/mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.0.67-log Source distribution
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('newpwd');
Query OK, 0 rows affected (0.00 sec)
mysql> quit
Bye
[root@sms mysql]#
0 개의 댓글:
댓글 쓰기