phpMyAdmin on Fedora 10
Install phpMyAdmin on Fedora via Yum:
1. From the command line: # yum -y install phpMyAdmin
2. Setting up access (Security Defaults are a pain!)
# cd /etc/httpd/conf.d/
#vim /phpMyAdmin.conf
Inside this file you will find the following:
# phpMyAdmin – Web based MySQL browser written in php
#
# Allows only localhost by default
#
# But allowing phpMyAdmin to anyone other than localhost should be considered
# dangerous unless properly secured by SSLAlias /phpMyAdmin /usr/share/phpMyAdmin
Alias /phpmyadmin /usr/share/phpMyAdmin
<Directory /usr/share/phpMyAdmin/>
order deny,allow
deny from all
allow from 127.0.0.1
</Directory># This directory does not require access over HTTP – taken from the original
# phpMyAdmin upstream tarball
#
<Directory /usr/share/phpMyAdmin/libraries>
Order Deny,Allow
Deny from All
Allow from None
</Directory># This configuration prevents mod_security at phpMyAdmin directories from
# filtering SQL etc. This may break your mod_security implementation.
#
#<IfModule mod_security.c>
# <Directory /usr/share/phpMyAdmin>
# SecRuleInheritance Off
# </Directory>
#</IfModule>To gain access too it from another place or IP, which if you are on a network, and there are a series of workstations, you will add in the following ONE LINE if your IP Address is: 192.168.0.90
# phpMyAdmin – Web based MySQL browser written in php
#
# Allows only localhost by default
#
# But allowing phpMyAdmin to anyone other than localhost should be considered
# dangerous unless properly secured by SSLAlias /phpMyAdmin /usr/share/phpMyAdmin
Alias /phpmyadmin /usr/share/phpMyAdmin
<Directory /usr/share/phpMyAdmin/>
order deny,allow
deny from all
allow from 127.0.0.1
allow from 192.168.0.90
</Directory># This directory does not require access over HTTP – taken from the original
# phpMyAdmin upstream tarball
#
<Directory /usr/share/phpMyAdmin/libraries>
Order Deny,Allow
Deny from All
Allow from None
</Directory># This configuration prevents mod_security at phpMyAdmin directories from
# filtering SQL etc. This may break your mod_security implementation.
#
#<IfModule mod_security.c>
# <Directory /usr/share/phpMyAdmin>
# SecRuleInheritance Off
# </Directory>
#</IfModule>
3. Setting up Normal Authorization to phpMyAdmin:
Edit the following lines to ensure you can login to phpMyAdmin under /etc/phpMyAdmin/config.inc.php:
$cfg['Servers'][$i]['auth_type'] = ‘http’; // Authentication method (config, http or cookie based)?
$cfg['Servers'][$i]['user'] = ‘USERNAME’; // MySQL user
$cfg['Servers'][$i]['password'] = ‘PASSWORD’; // MySQL password (only neededReplace USERNAME and PASSWORD with your MySQL username and password respectively.
By default, PHPMyadmin connects to MySQL via localhost with default port and socket. If you wish to modify these settings, change the below similar lines
$cfg['Servers'][$i]['host'] = ‘localhost’; // MySQL hostname or IP address
$cfg['Servers'][$i]['port'] = ”; // MySQL port – leave blank for default port
$cfg['Servers'][$i]['socket'] = ”; // Path to the socket – leave blank for default socket
4. View it via any webbrowser by going to http://localhost/phpMyAdmin or via IP or Hostname
See any other settings need changing to fit your requirements? If so feel free on doing so, and make sure you check out their documentation.
WTF phpMyAdmin it up!