Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I used

apt-get install phpmyadmin

to install phpmyadmin after installing apache2 php5 and mysql the same way, Then when I went to http://[ip]/phpMyAdmin/ it gave me a 404 error. So i went and looked for the files and found them in /usr/share/phpMyAdmin so I made an alias by doing this

sudo ln -s /usr/share/phpMyAdmin /var/www

and now when I go back to phpmyadmin it gives me a 403 forbidden error. What should I do?

Thank You :)

share|improve this question

This is most likely that the index.php (or whatever) inside /usr/share/phpMyAdmin isn't being opened by default. See what's inside that directory and then try specifying the file directly to see if that fixes it (we can fix the issue afterwards).

If not, it could be a permissions issue (it's unlikely): Find out which user is running apache:
sudo ps aux | grep "apache2" | cut -f1 -d" "
There will be a couple of roots in there, ignore those and pick the other username. Then try:
sudo -u whatever_user_that_was ls /usr/share/phpMyAdmin
If that gives permission denied, that's your problem.

share|improve this answer

Check out the instructions from the Debian wiki to include phpadmin in your apache instance. Read the wiki first, then let me know if you're still having issues. Good luck!


More specifically, you just need to add the following line to /etc/apache2/apache2.conf:

Include /etc/phpmyadmin/apache.conf
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.