• Ubuntu MariaDB PhpMyAdmin


    root@www:~# apt-get -y install phpmyadmin php-mbstring php-gettext
    # select which one you using (this example selects apache2)
     +------------------------+ Configuring phpmyadmin +-------------------------+
     | Please choose the web server that should be automatically configured to   |
     | run phpMyAdmin.                                                           |
     |                                                                           |
     | Web server to reconfigure automatically:                                  |
     |                                                                           |
     |    [*] apache2                                                            |
     |    [ ] lighttpd                                                           |
     |                                                                           |
     |                                                                           |
     |                                  <Ok>                                     |
     |                                                                           |
     +---------------------------------------------------------------------------+
    
    # answer "No" to proceed on this example
     +------------------------+ Configuring phpmyadmin +-------------------------+
     |                                                                           |
     | The phpmyadmin package must have a database installed and configured      |
     | before it can be used.  This can be optionally handled with               |
     | dbconfig-common.                                                          |
     |                                                                           |
     | If you are an advanced database administrator and know that you want to   |
     | perform this configuration manually, or if your database has already      |
     | been installed and configured, you should refuse this option.  Details    |
     | on what needs to be done should most likely be provided in                |
     | /usr/share/doc/phpmyadmin.                                                |
     |                                                                           |
     | Otherwise, you should probably choose this option.                        |
     |                                                                           |
     | Configure database for phpmyadmin with dbconfig-common?                   |
     |                                                                           |
     |                    <Yes>                       <No>                       |
     |                                                                           |
     +---------------------------------------------------------------------------+
    
    # change some settings to enable login to phpMyAdmin with root
    root@www:~# mysql -u root -p mysql 
    Enter password:
    Reading table information for completion of table and column names
    You can turn off this feature to get a quicker startup with -A
    
    Welcome to the MariaDB monitor.  Commands end with ; or g.
    Your MariaDB connection id is 50
    Server version: 10.0.24-MariaDB-7 Ubuntu 16.04
    
    Copyright (c) 2000, 2016, Oracle, MariaDB Corporation Ab and others.
    
    Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
    
    MariaDB [mysql]> update user set plugin='' where user='root'; 
    Query OK, 1 row affected (0.00 sec)
    Rows matched: 1  Changed: 1  Warnings: 0
    
    MariaDB [mysql]> flush privileges; 
    Query OK, 0 rows affected (0.00 sec)
    
    MariaDB [mysql]> exit 
    Bye
    
    root@www:~# vi /etc/phpmyadmin/apache.conf
    # line 8: add IP you allow to access
    Require ip 127.0.0.1 10.0.0.0/24
    root@www:~# systemctl restart apache2 

    网上复制来的,记个备忘

  • 相关阅读:
    获得每天的日期流水 函数
    sql调用web服务
    Sql 查询当天、本周、本月记录
    从首页问答标题到问答详情页
    首页列表显示全部问答,完成问答详情页布局
    制作首页的显示列表。
    发布功能完成
    登录之后更新导航
    完成登录功能,用session记住用户名
    完成注册功能
  • 原文地址:https://www.cnblogs.com/Robbery/p/Ubuntu-MariaDB-PhpMyAdmin.html
Copyright © 2020-2023  润新知