LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   phpmyadmin? (https://www.linuxquestions.org/questions/linux-newbie-8/phpmyadmin-130742/)

gruessle 01-02-2004 01:54 AM

phpmyadmin?
 
I got Apache, php, mysql working on a Debian :Pengy: installation
and I have phpmyadmin installed
The only thing which is not working is
h t t p : / / localhost / phpmyadmin

Someone told me that I need to create a symlink to it in /var/www
I tried that and received an error saying that phpmyadmin already exists.
Can someone show me what the command needs to look like or how I can get this to work?

Here is a link on how to setup Debian which was very helpful
projektfarm.com/en/support/debian_setup/

nephilim 01-02-2004 02:14 AM

What do you see when you go to http://localhost? Isn't there a link to phpmyadmin?

Technoslave 01-02-2004 03:31 AM

Sounds to me like you need to setup an alias in your httpd.conf

Yes, you can possibly link it from your home directory, but that's not recommended. Nor should you just have phpmyadmin open for everyone to see.

So, you'll want to edit your httpd.conf file, you'll want to search for Alias ( just like that ) that will take you to your aliases section, where you'll want to create something like:

Alias /myadmin "/place/where/phpmyadmin/lives"

Then you'll want to look in to restricting access to there. Once you get the Alias stuff taken care of...if you want to lock it down some more...then reply, I'll go in to doing that with you.

gruessle 01-05-2004 03:44 AM

Quote:

Originally posted by Technoslave
Sounds to me like you need to setup an alias in your httpd.conf

Yes, you can possibly link it from your home directory, but that's not recommended. Nor should you just have phpmyadmin open for everyone to see.

So, you'll want to edit your httpd.conf file, you'll want to search for Alias ( just like that ) that will take you to your aliases section, where you'll want to create something like:

Alias /myadmin "/place/where/phpmyadmin/lives"

Then you'll want to look in to restricting access to there. Once you get the Alias stuff taken care of...if you want to lock it down some more...then reply, I'll go in to doing that with you.



I got it working - it took so long because I made a misstake and had to reinstall everything.

Thank you for your help and if your offer still stands I would like to 'look it down some more'

This is what it look like right now:
Code:

Alias /myadmin/ /usr/share/phpmyadmin/

<Directory /usr/share/phpmyadmin>
    Options Indexes MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>


Technoslave 01-09-2004 12:09 AM

Ok, to lock down, what you'll want to to look at your httpd.conf file a little bit.

Under your Alias section and your ScriptAlias ( that's under Alias ), you'll see something along the lines of:

<Directory "/usr/local/apache2/cgi-bin">

Well, under the </Directory> of the above line, I have something like this:

<Directory "/place/where/phpMyAdmin">
AuthType Basic
AuthUserFile /place/where/phpMyAdmin/.htpasswd
AuthName "MyAdmin Stuff"
Require valid-user
</Directory>

Then, in your phpMyAdmin directory, you'll have two files. The first one I believe you have to create yourself.

.htaccess

And it will have something like this:

AuthName "MyAdmin Stuff"
AuthType Basic
AuthUserFile /place/where/phpMyAdmin/.htpasswd

require valid-user

Then what you'll want to do is execute the command htpasswd ( usually located inside the bin dir in your apache dir )

And you'll want to type it out like:

htpasswd -c /place/where/phpMyAdmin/.htpasswd username

That will create the .htpasswd file for you. Restart apache and give it a try...remember, if something comes up, look in your error logs to see if you can figure it out.


All times are GMT -5. The time now is 12:56 PM.