Skip to content

2010.05.03 01:10

mySQL 설치

조회 수 12903 추천 수 0 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄

make 중 libmysql 에러 나는 경우

#rpm -Uvh libstdc++-devel-3.2.2-5.i386.rpm

#rpm -Uvh gcc-c++-3.2.2-5.i386.rpm

두개의 컴파일러 설치

 

mysql-4.0.26.tar.gz 다운

#tar xvzf mysql-4.0.26.tar.gz -C /usr/local/src (폴더에 압축 해제)

#groupadd mysql

#useradd -g mysql mysql

 

#cd /usr/local

#mkdir mysql

#cd mysql

#mkdir data

 

#cd /usr/local/src/mysql-4.0.26

# ./configure --prefix=/usr/local/mysql --localstatedir=/usr/local/mysql/data --with-charset=euc_kr

#make

#make install

#scripts/mysql_install_db (사용을 위한 기초 DB 생성)

# chown -R mysql:mysql /usr/local/mysql/data (데이터 폴더 권한을 mysql로 변경)

# cp support-files/my-medium.cnf /etc/my.cn (환경 설정 파일을 /etc/my.cnf 로 복사)

 

mysql 의 데몬스크립트인 mysql.server 파일에 mysql_safe가 실행되는 라인에 language 옵션을 추가해 준다.

# vi /usr/local/mysql/share/mysql/mysql.server

$bindir/mysqld_safe --datadir=$datadir --pid-file=$server_pid_file >/dev/null 2>&1 &

=>$bindir/mysqld_safe --datadir=$datadir --language=korean --pid-file=$server_pid_file >/dev/null 2>&1 &

 

mysql 경로 추가

# vi /root/.bash_profile

PATH=$PATH:$HOME/bin:/usr/local/mysql/bin

 

 

부팅시 자동 실행이 되도록 만들어 준다

# cp -p /usr/local/mysql/share/mysql/mysql.server /etc/rc.d/init.d/mysqld

# ln -s /etc/rc.d/init.d/mysqld /etc/rc.d/rc3.d/S90mysqld

# ln -s /etc/rc.d/init.d/mysqld /etc/rc.d/rc5.d/S90mysqld

 

mysql을 구동

# /etc/rc.d/init.d/mysqld start

 

구동 확인

# ps -ef|grep mysqld

root     29017     1  0 12:54 pts/1    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/data --language=korean --pid-file=/usr/local/mysql/data/서버명.pid

mysql    29047 29017  0 12:54 pts/1    00:00:00 /usr/local/mysql/libexec/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=mysql --pid-file=/usr/local/mysql/data/서버명.pid --skip-locking --port=3306 --socket=/tmp/mysql.sock --language=korean

root     29067 11175  0 12:55 pts/1    00:00:00 grep mysqld

 

초기 구동후 패스워드를 설정해 준다.

# ./mysqladmin -u root password 원하는패스워드

mysql로 들어가기

# ./mysql -u root -p

TAG •

  1. [데이터베이스] [DBMS-MYSQL] "SHOW PROCESSLIST"시 state 종류 및 설명

    Date2012.01.16 ByADMINPLAY Views15928
    Read More
  2. MySQL에서 Query Cache 사용하기

    Date2011.03.18 ByADMINPLAY Views15860
    Read More
  3. Redmine database를 복구 하고자 할 때

    Date2010.03.06 Byl2zeo Views15597
    Read More
  4. [우분투] mysql, data 디렉토리 변경

    Date2013.09.24 ByADMINPLAY Views15193
    Read More
  5. MySQL 외부접속

    Date2009.06.11 ByADMINPLAY Views14744
    Read More
  6. [mysql] Manager of pid-file quit without updating fi[실패]

    Date2009.06.29 ByADMINPLAY Views13639
    Read More
  7. mysql 쿼리문 모음

    Date2009.06.02 ByADMINPLAY Views13406
    Read More
  8. mySQL 설치

    Date2010.05.03 ByADMINPLAY Views12903
    Read More
  9. 서버에서 mysql euckr과 utf8 같이 사용하기

    Date2010.05.03 ByADMINPLAY Views12799
    Read More
  10. MySQL Error 2006 : MySQL server has gone away 해결하기

    Date2010.03.08 Byl2zeo Views12599
    Read More
  11. PHP5와 MySQL5 연동시 한글 인코딩 문제 해결방법 (UTF-8으로의 변환)

    Date2010.03.08 Byl2zeo Views12581
    Read More
  12. phpMyAdmin 에서 icon 과 text 중 icon 만 보이게 하기

    Date2013.01.21 Byl2zeo Views11855
    Read More
  13. Mysql InnoDB 관리하기

    Date2009.07.31 ByADMINPLAY Views11461
    Read More
  14. 초기 mysql root 패스워드 설정 및 비번 변경과 root 비번 잃어 버렸을 경우 변경하는 방법

    Date2008.10.30 ByADMINPLAY Views11290
    Read More
  15. innodb recovery

    Date2013.01.21 Byl2zeo Views11130
    Read More
  16. MySQL 테이블명 대소문자 구분안하기

    Date2013.01.21 Byl2zeo Views10916
    Read More
  17. SSL을 이용한 MySQL 연결

    Date2009.03.03 ByADMINPLAY Views10807
    Read More
  18. 리눅스를 이용한 클러스터링 구축법

    Date2009.11.19 ByADMINPLAY Views10754
    Read More
  19. 리눅스 환경에서 mySql JDBC

    Date2009.07.12 ByADMINPLAY Views10356
    Read More
  20. HeartBeat를 이용한 MySQL HA 구성

    Date2009.11.19 ByADMINPLAY Views10348
    Read More
Board Pagination Prev 1 2 3 4 5 Next
/ 5

Copyright ADMINPLAY corp. All rights reserved.

abcXYZ, 세종대왕,1234

abcXYZ, 세종대왕,1234