MySQL management tool-phpmyadmin management platform Setup

Source: Internet
Author: User
Tags mysql client phpmyadmin

4 MySQL Management tools 4.1 issues

This case requires the deployment of a set of phpMyAdmin applications based on the lamp platform to enable Web management of the MySQL server.

4.2 Solutions

Use 2 RHEL6 virtual machines + 1 windows 7 real machines, as shown in-2. Where 192.168.4.10 is the MySQL server, the authorization operation is performed on this server, and the other Linux server 192.168.4.6 is deployed on the phpMyAdmin management platform, which implements the Web management mode accessed from the browser.

650) this.width=650; "Src=" http://tts8.tmooc.cn/ttsPage/VIP/VIP_NSD01/MYSQL/DAY04/CASE/01/index.files/ Image002.png "alt=" Image002.png "/>

Figure-2

4.3 steps

The implementation of this case needs to follow the steps below.

Step One: Configure user access authorization on the MySQL server

For the sake of experimentation, the root user is directly allowed to access from the 192.168.4.0/24 network segment, with the password set to 1234567.

Copytextpop-up
    1. Mysql> GRANT all on *.* to [Email protected] ' 192.168.4.% ' identified by ' 1234567 '

    2. query ok, 0 rows affected ( 0.00 Sec)

Mysql> GRANT All on * * to [e-mail protected] ' 192.168.4.% ' identified by ' 1234567 '; Query OK, 0 rows Affected (0.00 sec)

Step Two: Build phpMyAdmin management Platform (192.168.4.6)

phpMyAdmin is a web-based program that is developed in PHP to manage MySQL databases, so a PHP-enabled Web server is required to use the phpMyAdmin platform properly.

1) Simple deployment of the lamp platform

Install httpd, MySQL, PHP, php-mysql packages directly in Yum, in this case only the MySQL client program, without the need to install the Mysql-server:

Copytextpop-up
    1. [[email protected] ~]# yum -y install httpd mysql php php-MySQL

    2. .. ..

[[email protected] ~]# yum-y install httpd mysql php php-mysql. ..

Since Rhel 6 does not provide the php-mbsring package, and the phpMyAdmin kit requires the relevant library files, additional download of the applicable RPM package (provided by the instructor) is required, and the dependencies can be ignored during installation:

Copytextpop-up
    1. [[email protected] ~]# rpm -ivh php-mbstring-5.3.3-26 . El6. x86_64. RPM -nodeps

    2. .. ..

[Email protected] ~]# RPM-IVH php-mbstring-5.3.3-26.el6.x86_64.rpm-nodeps. ..

After the installation is complete, the HTTPD service configuration is adjusted slightly to start the HTTPD website service:

Copytextpop-up
  1. [[email protected] ~]# vim /etc/httpd/conf/httpd. Conf

  2. ServerName localhost. Localdomain

  3. .. ..

  4. DirectoryIndex index. PHP index. Html

  5. .. ..

  6. [[email protected] ~]# service httpd restart

  7. .. ..

[Email protected] ~]# vim/etc/httpd/conf/httpd.confservername localhost.localdomain. .. DirectoryIndex index.php index.html. .. [Email protected] ~]# service httpd restart. ..

2) Download and deploy the phpMyAdmin suite

Visit http://www.phpmyadmin.net/to download the multi-lingual source code package Phpmyadmin-4.1.2-all-languages.zip.

Unzip the downloaded source package and deploy it to the site directory:

Copytextpop-up
    1. [ [email protected] ~] # unzip phpmyadmin< Span class= "Sh_number" >-4.1.2 - all- Languages Zip

    2. [ [email protected] ~] # Span class= "Sh_usertype" >mv phpmyadmin-4.1.2 - all- languages / var/ www/ html/ PMA

[Email protected] ~]# unzip Phpmyadmin-4.1.2-all-languages.zip[[email protected] ~]# MV Phpmyadmin-4.1.2-all-languages/var/www/html/pma

Switch to the post-deployment PMA program directory, copy the configuration file, and modify the configuration to correctly specify the IP address of the MySQL server.

Copytextpop-up
  1. [[email protected] ~]# cd /var/www/html/PMA/

  2. [[email protected]dbsvr PMA]# CP config. Sample. Inc. PHP config. Inc. Php

  3. [[email protected]dbsvr PMA]# vim config. Inc. Php

  4. <? Php

  5. .. ..

  6. $cfg[' Servers '] [$i] [' host '] = ' 192.168.4.10 ' ;

  7. .. ..

  8. ?>

[[email protected] ~]# Cd/var/www/html/pma/[[email protected] pma]# CP config.sample.inc.php Config.inc.php[[email Protected] pma]# vim config.inc.php<?php. .. $cfg [' Servers '] [$i] [' host '] = ' 192.168.4.10 '; ..? >

3) access to the phpMyAdmin system from the browser

On the Windows 7 client, open the IE Web browser and access the website http://192.168.4.6/pma/index.php where the phpMyAdmin system is deployed to open the phpMyAdmin management platform. 3, enter the correct database username (such as root) and password to log in.

650) this.width=650; "Src=" http://tts8.tmooc.cn/ttsPage/VIP/VIP_NSD01/MYSQL/DAY04/CASE/01/index.files/ Image003.png "alt=" Image003.png "/>

Figure-3

Once the login is successful, the MySQL database can be managed within the scope of authorization, as shown in 4.

650) this.width=650; "Src=" http://tts8.tmooc.cn/ttsPage/VIP/VIP_NSD01/MYSQL/DAY04/CASE/01/index.files/ Image004.png "alt=" Image004.png "/>

MySQL management tool-phpmyadmin management platform Setup

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.