기본적으로 config.inc.php 파일에 문제가 있습니다. 그러나 나는 내가 알지 못하는 다른 것을 엉망으로 만든 경우에 대비하여 사건의 순서를 설명 할 것이다.phpMyAdmin을 통해 데이터베이스에 액세스 할 수 없습니다.
저는 localhost에서 몇 달 동안 사용해온 phpMyAdmin에 데이터베이스를 만들었습니다. 그것은 XAMPP와 함께 설치되었습니다. XAMPP/xamppfiles/phpMyAdmin/README
파일에 따라 phpMyAdmin Version 3.5.7
입니다.
잠시 동안 나는 ['controluser'] = 'pma' and ['controluserpass'] = 'pmapass'
으로 남았습니다. phpMyAdmin을가
"Connection for controluser as defined in your configuration failed"
경고를 나에게 모든 시간을 보여주는 시작한 이후, 몇 주 전, 나는 그 값을 변경, 그러나 그것은 분명히 문제를 만들었습니다. 그럼에도 불구하고, 나는 내가해야 할 모든 것을 여전히 할 수 있었다. 그래서 나는 내 데이터베이스를 계속 사용했다.
어제 8 시간 이상 계속 된 쿼리를 삭제해야했습니다. 그 후, phpMyAdmin이 조금 느린 다른 데이터베이스와 테이블을로드하는 것 같았습니다. 그래서 XAMPP를 열고 MySQL 용 중지 버튼을 눌렀습니다. 분명히,이 버튼은 더 이상 MySQL을 멈추지 않습니다. 아이콘은 단순히 생각처럼 회전하고 회전합니다. 그래서, 오늘부터는 MySQL을 XAMPP Control 인터페이스가 아닌 터미널에서 직접 중지하고 시작했습니다.
나는 controluser에 대한 경고를보고 있었기 때문에 config.inc.php 파일을 다시 작성하여 문제가 있었는지 치료할 것을 결정했습니다. 불행히도, 나는 상황을 더욱 악화 시켰습니다. 이제 데이터베이스에 전혀 액세스 할 수 없습니다.
오늘 config.inc.php 파일을 설정하는 방법을 연구하는 데 5 시간을 소비했지만 데이터베이스에 계속 액세스 할 수 없습니다. 과거에는 'config'옵션을 설정하고 비밀번호를 입력하지 않아도되었습니다. 이상적으로는 암호 보안을 선호합니다. 그러나이 단계에서 나는 내 데이터베이스에 다시 액세스 할 수있어서 행복 할 것입니다.
지금은 localhost/phpmyadmin
이 로그인 페이지로 이동합니다. 로그인 페이지에서는 기본적으로 "사용자 이름"에 "root"가 입력됩니다. 하지만 로그인 할 수 없습니다. config.inc.php에 대한 조정에 따라 때로는 "사용자 이름"이 횡설수설하는 경우가 있습니다. 다른 경우에는 로그인 대신 오류 메시지가 나타납니다.아무리 암호를 입력 한 내용, phpMyAdmin에 그것을 받아 들일 수 없습니다 :
2002 - Can't connect to local MySQL server through socket '/Applications/XAMPP/xamppfiles/var/mysql/mysql.sock' (2) The server is not responding (or the local server's socket is not correctly configured).
나는 시도했다 :
2002 Cannot log in to the MySQL server
다른 시간을,이 오류가 발생합니다
$cfg['Servers'][$i]['auth_type'] = 'cookie'
및
$cfg['Servers'][$i]['auth_type'] = 'config'
및
$cfg['Servers'][$i]['connect_type'] = 'tcp'
및
$cfg['Servers'][$i]['connect_type'] = 'socket'
및
$cfg['Servers'][$i]['AllowNoPassword'] = false
및
$cfg['Servers'][$i]['AllowNoPassword'] = true
및 사이
사이
,
$cfg['Servers'][$i]['host'] = 'localhost'
및
$cfg['Servers'][$i]['host'] = '127.0.0.1'
아무것도 내 데이터베이스에 액세스 할 수 있도록 보인다.
2002 Cannot log in to the MySQL server
내가 무엇을 변경해야합니다 : 순간
, 내가 로그인 화면이 오류를 받고 있어요?그것은 단지 하나의 PHP : 당신은 당신의 데이터베이스에 대한 액세스 권한이 필요하고 당신이 당신의 로그인 자격 증명을 알고있는 경우
<?php
$cfg['blowfish_secret'] = '89x7a3f';
$i = 0;
$i++;
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['AllowRoot'] = true;
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = true;
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = false;
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = 'pass';
// $cfg['Servers'][$i]['controlhost'] = '';
$cfg['Servers'][$i]['controluser'] = 'pma';
$cfg['Servers'][$i]['controlpass'] = 'pmapass';
$cfg['Servers'][$i]['pmadb'] = 'phpmyadmin';
$cfg['Servers'][$i]['bookmarktable'] = 'pma_bookmark';
$cfg['Servers'][$i]['relation'] = 'pma_relation';
$cfg['Servers'][$i]['table_info'] = 'pma_table_info';
$cfg['Servers'][$i]['table_coords'] = 'pma_table_coords';
$cfg['Servers'][$i]['pdf_pages'] = 'pma_pdf_pages';
$cfg['Servers'][$i]['column_info'] = 'pma_column_info';
$cfg['Servers'][$i]['history'] = 'pma_history';
//$cfg['DefaultConnectionCollation'] = 'utf8_general_ci';
$cfg['Servers'][$i]['table_uiprefs'] = 'pma_table_uiprefs';
$cfg['Servers'][$i]['tracking'] = 'pma_tracking';
$cfg['Servers'][$i]['designer_coords'] = 'pma_designer_coords';
$cfg['Servers'][$i]['userconfig'] = 'pma_userconfig';
$cfg['Servers'][$i]['recent'] = 'pma_recent';
// $cfg['Servers'][$i]['auth_swekey_config'] = '/etc/swekey-pma.conf';
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';
$cfg['DefaultLang'] = 'en';
?>
config.inc.php의 다양한 설정을 계속 변경했습니다. 그러나 "# 2002 - 소켓을 통해 로컬 MySQL 서버에 연결할 수 없습니다 '/ Applications/XAMPP/xamppfiles/var/mysql/mysql이 오류 메시지에 표시된 디렉토리에 mysql.sock 파일이 없음을 알았습니다. sock '(2) 서버가 응답하지 않거나 로컬 서버의 소켓이 올바르게 구성되지 않았습니다. " StackOverflow.com에 다른 사람이 비슷한 문제를보고했지만 아무도 대답을 내놓지 못했습니다 : http://stackoverflow.com/questions/5530215/mysql-problem-no-mysql-sock – user2647547
XAMPP를 통해 MySQL을 종료하려고하면 제어하고 충분히 오래 기다리면이 오류 메시지가 나타납니다 : "MySQL 종료 중 .................................. ............ 오류! " – user2647547
터미널/applications/xampp/xamppfiles/bin/mysqladmin 버전 오류가 발생합니다 : '소켓을 통해 로컬 MySQL 서버에 연결할 수 없습니다'/ 응용 프로그램/XAMPP/xamppfiles/var/mysql/mysql.sock '(2) mysqld가 실행 중이고'/Applications/XAMPP/xamppfiles/var/mysql/mysql.sock '소켓이 있는지 확인하십시오! 한편 localhost/phpmyadmin은 모든 데이터베이스와 테이블이있는 화면으로 이동합니다. 컴퓨터를 다시 시작하기 전에 로그인 화면이 나타납니다. 이제는 아무 것도 변경하지 않았더라도 건너 뜁니다. 하지만 phpMyAdmin은 데이터베이스 나 테이블 자체에 연결하지 않습니다. – user2647547