Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Forum Archive > Main Support Categories > General Help
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Hello, Unregistered You are browsing a READ only archive of the main support categories pre 4/21/2008. You will not be able to post or reply any threads in this section.

General Help
All your general support questions for Ubuntu, Kubuntu, Edubuntu and Xubuntu.

 
Thread Tools Display Modes
Old October 25th, 2007   #1
acambre
First Cup of Ubuntu
 
Join Date: Oct 2007
Beans: 11
Ubuntu 9.10 Karmic Koala
phpmyadmin package does not install under /var/www

When I install phpmyadmin using apt-get install phpmyadmin, it appears to put it everywhere except /var/www according to find. The package wasn't even nice enough to give me a symbolic link.

Where do I find instructions on the "proper" way of using phpmyadmin through the apt package? Do I just need to forget about using the apt package and install from source? (Yeah, I know, it's not hard, but I like brainless installs. )
acambre is offline   Reply With Quote
Old October 26th, 2007   #2
mannih2001
Just Give Me the Beans!
 
Join Date: Dec 2006
Location: Berlin, Germany
Beans: 62
Ubuntu 7.10 Gutsy Gibbon
Re: phpmyadmin package does not install under /var/www

The phpmyadmin package install the files to /usr/share/phpmyadmin.

But it also creates a symlink in /etc/apache2/conf.d and restarts apache so that you should be able to go to localhost/phpyadmin immediately.

At least that all happens on my system when I install the package with Synaptic and with the default /etc/apache2/apache2.conf.

So either you changed your apache2.conf so that it no longer includes files in conf.d or apt-get install does something a little different than synaptic.
mannih2001 is offline   Reply With Quote
Old October 26th, 2007   #3
mannih2001
Just Give Me the Beans!
 
Join Date: Dec 2006
Location: Berlin, Germany
Beans: 62
Ubuntu 7.10 Gutsy Gibbon
Re: phpmyadmin package does not install under /var/www

Quote:
Originally Posted by mannih2001 View Post
... or apt-get install does something a little different than synaptic.
Indeed. I just tried it and although "apt-get intall phpmyadmin" asks which server it should configure, it does not create that symlink.

All you need to do is create a symlink in /etc/apache2/conf.d/ to /etc/phpmyadmin/apache.conf.
mannih2001 is offline   Reply With Quote
Old October 26th, 2007   #4
acambre
First Cup of Ubuntu
 
Join Date: Oct 2007
Beans: 11
Ubuntu 9.10 Karmic Koala
Re: phpmyadmin package does not install under /var/www

Quote:
Originally Posted by mannih2001 View Post
Indeed. I just tried it and although "apt-get intall phpmyadmin" asks which server it should configure, it does not create that symlink.

All you need to do is create a symlink in /etc/apache2/conf.d/ to /etc/phpmyadmin/apache.conf.
Thanks. Shouldn't that have been set up automatically? Is that a package bug? If so, where is it reported?
acambre is offline   Reply With Quote
Old October 29th, 2007   #5
mistervino
First Cup of Ubuntu
 
Join Date: May 2007
Beans: 3
Re: phpmyadmin package does not install under /var/www

I've been experiencing the same problem. I got it fixed, though!

The only thing that's missing is the symbolic link to the phpMyAdmin directory.

Run the following command and you'll have a folder called "phpmyadmin" in your localhost.

Code:
sudo ln -s /usr/share/phpmyadmin /var/www/phpmyadmin
Now you can access phpMyAdmin at http://localhost/phpmyadmin/

Hope that helps!
mistervino is offline   Reply With Quote
Old October 29th, 2007   #6
acambre
First Cup of Ubuntu
 
Join Date: Oct 2007
Beans: 11
Ubuntu 9.10 Karmic Koala
Re: phpmyadmin package does not install under /var/www

Quote:
Originally Posted by mistervino View Post
I've been experiencing the same problem. I got it fixed, though!

The only thing that's missing is the symbolic link to the phpMyAdmin directory.

Run the following command and you'll have a folder called "phpmyadmin" in your localhost.

Code:
sudo ln -s /usr/share/phpmyadmin /var/www/phpmyadmin
Now you can access phpMyAdmin at http://localhost/phpmyadmin/

Hope that helps!
Yup, that's basically what I did. Where can we report this apparent bug in the package?
acambre is offline   Reply With Quote
Old November 1st, 2007   #7
mannih2001
Just Give Me the Beans!
 
Join Date: Dec 2006
Location: Berlin, Germany
Beans: 62
Ubuntu 7.10 Gutsy Gibbon
Re: phpmyadmin package does not install under /var/www

I just tried this again (using aptitude) and it seems that the user (i.e. me) was the problem. The text-interface asked me which web server I wanted to configure and I guess that I simply hit return when the apache2 entry was highlighted the last time I tried this. However, that's not enough. You have to explicitly select apache2 by hitting space before hitting return. Duh.

The same goes for apt-get.
mannih2001 is offline   Reply With Quote
Old November 1st, 2007   #8
epimeteo
Dipped in Ubuntu
 
epimeteo's Avatar
 
Join Date: Nov 2005
Location: Portugal
Beans: 636
Ubuntu 7.10 Gutsy Gibbon
Send a message via MSN to epimeteo
Re: phpmyadmin package does not install under /var/www

You don't need any link to /var/www/. You can remove that link try:

http://localhost/phpmyadmin

It will work.

The phpmyadmin alias in apache is set in /etc/phpmyadmin/apache.conf and this one is linked to /etc/apache2/conf.d/phpmyadmin.conf, so there is no need to add a link to /var/www/, unless you want it to be clearly visible to others.
epimeteo is offline   Reply With Quote
Old November 2nd, 2007   #9
mahousaru
Gee! These Aren't Roasted!
 
mahousaru's Avatar
 
Join Date: Aug 2007
Beans: 200
Ubuntu Karmic Koala (testing)
Re: phpmyadmin package does not install under /var/www

Quote:
Originally Posted by epimeteo View Post
You don't need any link to /var/www/. You can remove that link try:

http://localhost/phpmyadmin

It will work.

The phpmyadmin alias in apache is set in /etc/phpmyadmin/apache.conf and this one is linked to /etc/apache2/conf.d/phpmyadmin.conf, so there is no need to add a link to /var/www/, unless you want it to be clearly visible to others.
Also if you have multiple users on your system you should avoid allowing following links. Using the alias statement as epimeteo has stated followed up by a directory one is the standard course of actions.

If you want to be really secure and access the site via https and restrict it to only specific addresses then something on the lines of:

Remove the symlink to the php file that I believe exists in /etc/apache2/conf.d it should point to a file that looks like:

Code:
    <Directory /usr/share/phpmyadmin>                                                                                        
            Options Indexes FollowSymLinks                                                                                   
            DirectoryIndex index.php                                                                                         
                                                                                      
                                                                                                                             
            # Authorize for setup                                                                                            
            <Files setup.php>                                                                                                
                # For Apache 1.3 and 2.0                                                                                     
                <IfModule mod_auth.c>                                                                                        
                    AuthType Basic                                                                                           
                    AuthName "phpMyAdmin Setup"                                                                              
                    AuthUserFile /etc/phpmyadmin/htpasswd.setup                                                              
                </IfModule>                                                                                                  
                # For Apache 2.2
Copy the contents of the file and add to your ssl definitions that with the added alias and the following lines marked in red

Code:
    
    Alias /phpmyadmin /usr/share/phpmyadmin

     <Directory /usr/share/phpmyadmin>                                                                                        
            Options Indexes FollowSymLinks                                                                                   
            DirectoryIndex index.php                                                                                         
            Order deny,allow                                                                                                 
            Deny from all                                                                                                    
            Allow from 127.0.0.1                                                                                             
            Allow from 10.0.0.0/24                                                                                           
                                                                                                                             
            # Authorize for setup                                                                                            
            <Files setup.php>                                                                                                
                # For Apache 1.3 and 2.0                                                                                     
                <IfModule mod_auth.c>                                                                                        
                    AuthType Basic                                                                                           
                    AuthName "phpMyAdmin Setup"                                                                              
                    AuthUserFile /etc/phpmyadmin/htpasswd.setup                                                              
                </IfModule>                                                                                                  
                # For Apache 2.2
mahousaru is offline   Reply With Quote
Old December 20th, 2007   #10
enixon
5 Cups of Ubuntu
 
Join Date: Jan 2007
Beans: 18
Re: phpmyadmin package does not install under /var/www

After Installing phpmyadmin through synaptic an through the terminal, it still wasn't linked to my www folder. mistervino 's fix took care of it completely. Thanks for the info.
enixon is offline   Reply With Quote

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:52 PM.


vBulletin ©2000 - 2010, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. lingonberry