database.sarang.net
UserID
Passwd
Database
DBMS
ㆍMySQL
PostgreSQL
Firebird
Oracle
Informix
Sybase
MS-SQL
DB2
Cache
CUBRID
LDAP
ALTIBASE
Tibero
DB 문서들
스터디
Community
공지사항
자유게시판
구인|구직
DSN 갤러리
도움주신분들
Admin
운영게시판
최근게시물
MySQL Q&A 30007 게시물 읽기
No. 30007
mysql 설치 후 디렉토리 변경해서 시작하면 에러가 발생 합니다.
작성자
김영범(bumworld)
작성일
2011-06-12 10:12ⓒ
2011-06-12 20:50ⓜ
조회수
8,828
centos에서 mysql을 yum으로 설치했습니다.
 
설치 후에 my.cnf 파일의 mysql 경로를 변경 했구요.
 
물론 설치후에
 
mysql_install_db && chown -R mysql:mysql /home/bumworld/program/mysql
 
이렇게 해줬습니다.
 
그리고 /etc/rc.d/init.d/mysqld start
 
위와같이 mysql을 시작했는데 실패를 해서 로그를 보니 아래와 같이 권한 문제가 있는듯 한데요.
 
분명히 디렉토리 권한을 제대로 주고 확인도 했습니다.
 
어떤 이유때문에 계속해서 발생하는지 모르겠습니다.
(여러번 지우고 새로 설치도 해봤습니다.)
 
도움부탁드려요..ㅠ.ㅠ
 
 
110612 09:37:54  mysqld started
InnoDB: The first specified data file ./ibdata1 did not exist:
InnoDB: a new database to be created!
110612  9:37:54  InnoDB: Setting file ./ibdata1 size to 10 MB
InnoDB: Database physically writes the file full: wait...
110612  9:37:54  InnoDB: Log file ./ib_logfile0 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile0 size to 5 MB
InnoDB: Database physically writes the file full: wait...
110612  9:37:54  InnoDB: Log file ./ib_logfile1 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile1 size to 5 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Doublewrite buffer not found: creating new
InnoDB: Doublewrite buffer created
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
110612  9:37:55  InnoDB: Started; log sequence number 0 0
110612  9:37:55 [ERROR] bdb:  /home/bumworld/program/mysql: Permission denied
110612  9:37:55 [ERROR] bdb:  /home/bumworld/program/mysql/log.0000000001: Permission denied
110612  9:37:55 [ERROR] bdb:  PANIC: Permission denied
110612  9:37:55 [ERROR] bdb:  PANIC: DB_RUNRECOVERY: Fatal error, run database recovery
110612  9:37:55 [ERROR] bdb:  fatal region error detected; run recovery
110612  9:37:55 [ERROR] bdb:  /home/bumworld/program/mysql: Permission denied
110612  9:37:55 [ERROR] Can't start server : Bind on unix socket: Permission denied
110612  9:37:55 [ERROR] Do you already have another mysqld server running on socket: /home/bumworld/program/mysql/mysql.sock ?
110612  9:37:55 [ERROR] Aborting
 
110612  9:37:55  InnoDB: Starting shutdown...
110612  9:37:56  InnoDB: Shutdown completed; log sequence number 0 43655
110612  9:37:56 [Note] /usr/libexec/mysqld: Shutdown complete
 
110612 09:37:56  mysqld ended
 
 
-----------------------------------------------------------------
/etc/my.cnf
[mysqld]
datadir=/home/bumworld/program/mysql
socket=/home/bumworld/program/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
 
# Disabling symbolic-links is recommended to prevent assorted security risks;
# to do so, uncomment this line:
# symbolic-links=0
 
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

 

 

이 글에 대한 댓글이 총 2건 있습니다.

권한 설정은 제대로 하셨을 것 같은데, 혹시 SELinux나 AppArmor가 활성화된 것은 아닌지 확인해보시길 바랍니다. centos니 AppArmor는 아니고 SELinux겠군요.

 

활성화된 경우 다음의 명령어로 해당 디렉터리에 추가 설정이 필요합니다.

chcon -Rv --type=system_o:subject_r:mysqld_db_t /home/bumworld/program/mysql

 

박현우(lqez)님이 2011-06-13 17:39에 작성한 댓글입니다.

 답변 감사합니다.

김영범(bumworld)님이 2011-06-14 17:40에 작성한 댓글입니다.
[Top]
No.
제목
작성자
작성일
조회
30011다중 테이블 select 구문 [1]
노인철
2011-06-15
8309
30010다중 row 를 하나의 row로 가져 오려면 [2]
다중열
2011-06-15
7923
30008db에서 뽑아온 자료의 정렬문제입니다. [1]
조근호
2011-06-12
8001
30007mysql 설치 후 디렉토리 변경해서 시작하면 에러가 발생 합니다. [2]
김영범
2011-06-12
8828
30006DBMS_ALERT 기능 문의 [1]
박세정
2011-06-09
8006
30005[질문] MySQL 조인 관련 질문 입니다. [1]
SoundChaser
2011-06-08
7725
30004mysql에서 오라클디비 가져오기 [1]
최봉수
2011-06-08
8724
Valid XHTML 1.0!
All about the DATABASE... Copyleft 1999-2023 DSN, All rights reserved.
작업시간: 0.048초, 이곳 서비스는
	PostgreSQL v16.1로 자료를 관리합니다