在Mac OS X 10.9.4本地主机MySQL安装5.6.20和phpMyAdmin的4.2.7.1的,我用了phpmyadmin/examples/create_tables.sql,编辑,从而激活需要GRANT SELECT, INSERT, DELETE, UPDATE在phpmyadmin我的控制用户.
使用下面显示的config.inc.php,当我启动phpMyAdmin时,无论是root用户还是控件用户,我都会收到错误消息:
The phpMyAdmin configuration storage is not completely configured, some extended features have been deactivated. To find out why click here.
该链接显示一长串配置设置,但不包括:
$cfg['Servers'][$i]['relation'] ...
$cfg['Servers'][$i]['table_info'] ..
$cfg['Servers'][$i]['table_coords'] ...
$cfg['Servers'][$i]['userconfig'] ...
Run Code Online (Sandbox Code Playgroud)
但我确实设置了这些config.inc.php.
在phpMyadmin主窗口中,在执行查询的显示中,我看到:
[error] => Table 'phpmyadmin.pma_recent' doesn't exist
[count] => 1
[query] => SELECT `tables` FROM `phpmyadmin`.`pma_recent` WHERE `username` = 'root'
Run Code Online (Sandbox Code Playgroud)
然而,当我运行mysql -u root -p命令行,然后use phpmyadmin;,和show tables;我获得列表:
+-----------------------+
| Tables_in_phpmyadmin |
+-----------------------+
| pma__bookmark |
| pma__column_info |
| pma__designer_coords |
| pma__history |
| pma__navigationhiding |
| pma__pdf_pages |
| pma__recent |
| pma__relation |
| pma__savedsearches |
| pma__table_coords |
| pma__table_info |
| pma__table_uiprefs |
| pma__tracking |
| pma__userconfig |
| pma__usergroups |
| pma__users |
+-----------------------+
Run Code Online (Sandbox Code Playgroud)
怎么了?
(我确实在phpMyAdmin - config.inc.php配置中看到了"答案" ,但它没有任何帮助.)
这是一个开始config.inc.php,一些评论被删除,敏感信息被遮挡.
<?php
$cfg['blowfish_secret'] = 'my secret';
/* Servers configuration */
$i = 0;
/* Server: localhost [1] */
$i++;
$cfg['Servers'][$i]['verbose'] = 'my localhost';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['port'] = '';
$cfg['Servers'][$i]['socket'] = '/tmp/mysql.sock';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysqli';
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = '';
/*
* phpMyAdmin configuration storage settings.
*/
/* User used to manipulate with storage */
$cfg['Servers'][$i]['controluser'] = 'mypmacontroluser';
$cfg['Servers'][$i]['controlpass'] = 'mypassword';
/* Storage database and tables */
$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['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]['users'] = 'pma__users';
$cfg['Servers'][$i]['usergroups'] = 'pma__usergroups';
$cfg['Servers'][$i]['navigationhiding'] = 'pma__navigationhiding';
/* End of servers configuration */
Run Code Online (Sandbox Code Playgroud)
我不知道phpMyAdmin,所以我不知道设置应该是怎样的,但无论如何,仅仅看一下这个问题,这里的表并不一致:
$cfg['Servers'][$i]['recent'] = 'pma_recent';
Run Code Online (Sandbox Code Playgroud)
拼写为一(1)个下划线.
根据SHOW TABLES,表本身拼写有两(2)个下划线.
+-----------------------+
| Tables_in_phpmyadmin |
+-----------------------+
...
| pma__recent |
Run Code Online (Sandbox Code Playgroud)
所以是的,MySQL会抱怨:
Table 'phpmyadmin.pma_recent' doesn't exist
Run Code Online (Sandbox Code Playgroud)
因为表确实不存在.
| 归档时间: |
|
| 查看次数: |
4022 次 |
| 最近记录: |