반응형
Laravel 5를 사용하는 데 문제가 있습니다. "php artisan migrate"를 실행하면이 오류가 발생합니다.
**************************************
* Application In Production! *
**************************************
Do you really wish to run this command? [y/N] y
[PDOException]
could not find driver
응용 프로그램을 실행할 수 있지만 데이터베이스 연결이 필요할 때이 오류가 발생했습니다.
PDOException in Connector.php line 55:
could not find driver
in Connector.php line 55
at PDO->__construct('mysql:host=localhost;dbname=mydb', 'root', '', array('0', '2', '0', false, false)) in Connector.php line 55
at Connector->createConnection('mysql:host=localhost;dbname=mydb', array('driver' => 'mysql', 'host' => 'localhost', 'database' => 'mydb', 'username' => 'root', 'password' => '', 'charset' => 'utf8', 'collation' => 'utf8_unicode_ci', 'prefix' => '', 'strict' => false, 'name' => 'mysql'), array('0', '2', '0', false, false)) in MySqlConnector.php line 22
그것을 고치는 방법?
해결 방법
서버에 PDO를 설치해야합니다.
Edit your php.ini (look at your phpinfo()
, "Loaded Configuration File" line, to find the php.ini file path).
다음 줄을 찾아 주석 처리를 제거합니다 (;
문자 제거).
;extension=pdo_mysql.so
그런 다음 Apache 서버를 다시 시작하십시오.
참조 페이지 https://stackoverflow.com/questions/35240414
반응형
'MySql' 카테고리의 다른 글
MySQL select에서 XPATH를 사용하는 방법은 무엇입니까? (0) | 2020.11.13 |
---|---|
MySQL In Django, how do I select 100 random records from the database? (0) | 2020.11.12 |
MySQL : 두 타임 스탬프의 차이를 초 단위로 얻는 방법 (0) | 2020.11.12 |
MySQL mysql에서 union 및 order by 절 사용 (0) | 2020.11.12 |
MySQL에서 null을 0으로 바꿉니다. (0) | 2020.11.12 |
댓글