2016-07-06 1 views
0

root 권한이 없어도 myspace를 시작하려면/도구 영역에 대한 쓰기 권한은 어떻게 얻습니까? 나는 오류 다음root 권한이없는 mysql

host13:~/JS> mysqld start 
160706 18:06:31 [Warning] Can't create test file /tool/p64/.package/mysql-5.5.21/data/host13.lower-test 
160706 18:06:31 [Warning] Can't create test file /tool/p64/.package/mysql-5.5.21/data/host13.lower-test 
mysqld: Table 'mysql.plugin' doesn't exist 
160706 18:06:31 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it. 
160706 18:06:31 InnoDB: The InnoDB memory heap is disabled 
160706 18:06:31 InnoDB: Mutexes and rw_locks use GCC atomic builtins 
160706 18:06:31 InnoDB: Compressed tables use zlib 1.2.3 
160706 18:06:31 InnoDB: Initializing buffer pool, size = 128.0M 
160706 18:06:31 InnoDB: Completed initialization of buffer pool 
160706 18:06:31 InnoDB: Operating system error number 30 in a file operation. 
InnoDB: Error number 30 means 'Read-only file system'. 
InnoDB: Some operating system error numbers are described at 
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/operating-system-error-codes.html 
InnoDB: File name ./ibdata1 
InnoDB: File operation call: 'create'. 
InnoDB: Cannot continue operation. 
+0

읽기 전용 파일 시스템은 권한 문제가 아닙니다. 이것은 파일 시스템이'ro' 옵션으로 마운트되었으므로 아무도 그 파일 시스템에 쓸 수 없음을 의미합니다. – Barmar

답변

1

무엇입니까 당신은 당신이 쓸 수있는 곳으로 MySQL의 데이터 디렉토리를 이동 한 다음 /etc/my.cnf에 지정할 수 있습니다 (또는 아마도 시스템 기본 설정에 따라 다른 위치)는 매개 변수는 datadir입니다. 데이터 디렉토리가 아직 초기화되지 않은 경우

이처럼 그들을 만들 수 있습니다 (이 경우 mysqld는 권한 테이블 누락에 대해 불평 할 것이다) :

# Setup DB 
mysql_install_db --datadir=<FULL PATH TO STORE DB FILES> 

# Start server 
mysqld --datadir=<FULL PATH TO STORE DB FILES> 

# Shutdown server 
mysqladmin -u root shutdown 

:

mysql_install_db --datadir=$path_to_new_datadir 
+0

고마워. 나는이 제안으로 약간의 진전을 이룰 수 있었다. 하지만 성공했습니다 '[ERROR] mysql.plugin 테이블을 열 수 없습니다. 생성하려면 mysql_upgrade를 실행하십시오. [ERROR] 치명적 오류 : 권한 테이블을 열거 나 잠그지 못했습니다. 'mysql.host'테이블이 존재하지 않습니다. ' 여기에서 도와 줄 추천 도서가 있습니까? – Jean

+0

솔루션이 편집에 포함되었습니다. –

0

대답을 요약 참고 :
datadir 이후의 = - 명령이 실패하지 않는 경우
2. 전체 경로 shoul d 사용

관련 문제