“UbuntuHelp:PhpMyAdmin”的版本间的差异
来自Ubuntu中文
小 |
小 |
||
(未显示同一用户的5个中间版本) | |||
第2行: | 第2行: | ||
{{Languages|UbuntuHelp:phpMyAdmin}} | {{Languages|UbuntuHelp:phpMyAdmin}} | ||
== Introduction == | == Introduction == | ||
− | + | phpMyAdmin is a very famous MySQL mangement software package. To use it you should install and configure PHP, Apache and php mysql (or mysqli) extension see [[UbuntuHelp:ApacheMySQLPHP|ApacheMySQLPHP]] for instructions. | |
== Installing From Package == | == Installing From Package == | ||
− | Install ''' | + | Install '''phpMyAdmin''' from the Universe repository see [[UbuntuHelp:InstallingSoftware|InstallingSoftware]] for detailed instructions on using repositories and package managers. (Note, however, that installation from a package manager often does not work). |
From console: | From console: | ||
<pre><nowiki> | <pre><nowiki> | ||
sudo apt-get install phpmyadmin | sudo apt-get install phpmyadmin | ||
</nowiki></pre> | </nowiki></pre> | ||
− | * If you're using Ubuntu 7.10 (Gutsy) select '''Apache2''' from the ''"Configuring phpmyadmin"'' dialog box. | + | * If you're using Ubuntu 7.10 (Gutsy) or later select '''Apache2''' from the ''"Configuring phpmyadmin"'' dialog box. |
− | + | To set up under Apache all you need to do is include the following line in /etc/apache2/apache2.conf. | |
+ | <pre><nowiki> | ||
+ | Include /etc/phpmyadmin/apache.conf | ||
+ | </nowiki></pre> | ||
+ | * If you are using Ubuntu 9.04 (Jaunty), there is no need to modify /etc/apache2/apache2.conf as the package installer already copied the file phpmyadmin.conf into /etc/apache2/conf.d directory. You can also skip the set up step and go directly to http://<hostname>/phpmyadmin and login with the user and password you set up during install. | ||
+ | Once phpMyAdmin is installed point your browser to [http://localhost/phpmyadmin] to start using it. You should be able to login using any users you've setup in MySQL. If no users have been setup, use ''admin'' with no password to login. | ||
+ | Should you get a 404 "Not Found" error when you point your browser to the location of phpMyAdmin (such as: [http://localhost/phpmyadmin]) this is likely caused by not checking the 'Apache 2' selection during installation. To redo the installation run the following: | ||
+ | <pre><nowiki> | ||
+ | sudo dpkg-reconfigure -plow phpmyadmin | ||
+ | </nowiki></pre> | ||
+ | Then select Apache 2 for the webserver you wish to configure. | ||
+ | If this does not work, then you can do the following to include the phpMyadmin-shipped Apache configuration into Apache: | ||
+ | <pre><nowiki> | ||
+ | sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf.d/phpmyadmin.conf | ||
+ | sudo /etc/init.d/apache2 reload | ||
+ | </nowiki></pre> | ||
== Installing from source == | == Installing from source == | ||
You may install phpmyadmin from source. This method circumvents the package manager and you will need to install updates yourself. This is not recommended for a production web server. Also, you'll need to have [[UbuntuHelp:Subversion|Subversion]] installed to download the source. | You may install phpmyadmin from source. This method circumvents the package manager and you will need to install updates yourself. This is not recommended for a production web server. Also, you'll need to have [[UbuntuHelp:Subversion|Subversion]] installed to download the source. | ||
第21行: | 第36行: | ||
sudo svn checkout https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/tags/STABLE/phpMyAdmin phpMyAdmin | sudo svn checkout https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/tags/STABLE/phpMyAdmin phpMyAdmin | ||
</nowiki></pre> | </nowiki></pre> | ||
− | then cd to | + | then cd to phpMyAdmin |
<pre><nowiki> | <pre><nowiki> | ||
cd phpMyAdmin | cd phpMyAdmin | ||
第33行: | 第48行: | ||
sudo chmod o+rw config | sudo chmod o+rw config | ||
</nowiki></pre> | </nowiki></pre> | ||
− | then open http://localhost/ | + | then open http://localhost/phpmyadmin/scripts/setup.php and follow the instructions. |
− | '''Note:''' This guide has been tested on Ubuntu 6.06 (Dapper) | + | '''Note:''' This guide has been tested on Ubuntu 6.06 (Dapper), Ubuntu 7.10 (Gutsy), and Ubuntu 8.04 (Hardy). |
---- | ---- | ||
− | |||
[[category:CategorySoftware]] | [[category:CategorySoftware]] | ||
[[category:UbuntuHelp]] | [[category:UbuntuHelp]] |
2010年5月19日 (三) 23:52的最新版本
Introduction
phpMyAdmin is a very famous MySQL mangement software package. To use it you should install and configure PHP, Apache and php mysql (or mysqli) extension see ApacheMySQLPHP for instructions.
Installing From Package
Install phpMyAdmin from the Universe repository see InstallingSoftware for detailed instructions on using repositories and package managers. (Note, however, that installation from a package manager often does not work). From console:
sudo apt-get install phpmyadmin
- If you're using Ubuntu 7.10 (Gutsy) or later select Apache2 from the "Configuring phpmyadmin" dialog box.
To set up under Apache all you need to do is include the following line in /etc/apache2/apache2.conf.
Include /etc/phpmyadmin/apache.conf
- If you are using Ubuntu 9.04 (Jaunty), there is no need to modify /etc/apache2/apache2.conf as the package installer already copied the file phpmyadmin.conf into /etc/apache2/conf.d directory. You can also skip the set up step and go directly to http://<hostname>/phpmyadmin and login with the user and password you set up during install.
Once phpMyAdmin is installed point your browser to [1] to start using it. You should be able to login using any users you've setup in MySQL. If no users have been setup, use admin with no password to login. Should you get a 404 "Not Found" error when you point your browser to the location of phpMyAdmin (such as: [2]) this is likely caused by not checking the 'Apache 2' selection during installation. To redo the installation run the following:
sudo dpkg-reconfigure -plow phpmyadmin
Then select Apache 2 for the webserver you wish to configure. If this does not work, then you can do the following to include the phpMyadmin-shipped Apache configuration into Apache:
sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf.d/phpmyadmin.conf sudo /etc/init.d/apache2 reload
Installing from source
You may install phpmyadmin from source. This method circumvents the package manager and you will need to install updates yourself. This is not recommended for a production web server. Also, you'll need to have Subversion installed to download the source. To install it from source open the console and cd to the www directory using:
cd /var/www/
then download it using svn by writing:
sudo svn checkout https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/tags/STABLE/phpMyAdmin phpMyAdmin
then cd to phpMyAdmin
cd phpMyAdmin
and create the folder config
sudo mkdir config
after that chmod it
sudo chmod o+rw config
then open http://localhost/phpmyadmin/scripts/setup.php and follow the instructions. Note: This guide has been tested on Ubuntu 6.06 (Dapper), Ubuntu 7.10 (Gutsy), and Ubuntu 8.04 (Hardy).