LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 01-06-2013, 07:13 AM   #1
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Rep: Reputation: Disabled
Angry Apache/2.2.22 (Ubuntu) Server at localhost Port 80


LAMP is working well since localhost/info.php gives me a page but when I write localhost/phpmyapache/ I get an error shown above. I'm using linux 12.10, I have set all the permissions at /var/www to chmod 777!
Please help asap!
 
Old 01-06-2013, 07:18 AM   #2
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hello and welcome to LinuxQuestions,

What distro and version are you using? How did you install PhpMyAdmin, using package manager? And don't set your permissions to 777, that's a real bad idea from any point of view, not only security. Depending on what distro you are using you should have a /etc/httpd/conf.d or /etc/apache2/conf.d directory. Do you have a file phpmyadmin.conf in there? Looking forward to your participation in the forums.

Kind regards,

Eric
 
Old 01-06-2013, 07:33 AM   #3
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Is that error in the title the full error? The line you showed in the title is normally just the 'footer' of the error page and there usually is more info.

Quote:
localhost/phpmyapache/
I doubt that that exists Typo here in the forum or in your url on your machine.

Last edited by Wim Sturkenboom; 01-06-2013 at 07:34 AM.
 
Old 01-06-2013, 07:38 AM   #4
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Quote:
Originally Posted by Wim Sturkenboom View Post
Is that error in the title the full error? The line you showed in the title is normally just the 'footer' of the error page and there usually is more info.


I doubt that that exists Typo here in the forum or in your url on your machine.
Hi Wim,

Nice catch, didn't even see that one. I assume it's a typo on the user's end, hope he comes back with something.

Kind regards,

Eric
 
Old 01-06-2013, 07:47 AM   #5
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
localhost/phpmyadmin/ is the tite, thanks William

The error I get is:
The requested URL /phpmyadmin was not found on this server.

Apache/2.2.22 (Ubuntu) Server at localhost Port 80
 
Old 01-06-2013, 07:58 AM   #6
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
My distro version is:
Linux francis-PC 3.5.0-17-generic #28-Ubuntu SMP Tue Oct 9 19:32:08 UTC 2012 i686 i686 i686 GNU/Linux

When I typed both commands I saw an empty file, what is the full command that will help me see phpmyadmin.conf?
francis@francis-PC:~$ sudo nano /etc/apache2/conf.d
sudo: unable to resolve host francis-PC
francis@francis-PC:~$ sudo nano /etc/httpd/conf.d
sudo: unable to resolve host francis-PC
 
Old 01-06-2013, 08:01 AM   #7
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hi,

That happens because you tried to open a directory. Try:
Code:
ls /etc | egrep "apache2|httpd"
to see which it is. Since you're using Ubuntu it'll almost certainly be apache2, so if it is run this:
Code:
ls /etc/apache2/conf.d
and see if you have a file phpmyadmin.conf in there.

Kind regards,

Eric
 
Old 01-06-2013, 08:12 AM   #8
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
Hi Eric,
I entered the commands
francis@francis-PC:~$ ls /etc | egrep "apache2|httpd"
apache2

francis@francis-PC:~$ ls /etc/apache2/conf.d
charset localized-error-pages other-vhosts-access-log security

francis@francis-PC:~$ ls /etc/apache2/
apache2.conf envvars magic mods-enabled sites-available
conf.d httpd.conf mods-available ports.conf sites-enabled

I managed to see the apache2 file, viewed it and also saw conf.d, so what do I do next? As you can see, the underlined line of code gives an error!
 
Old 01-06-2013, 08:17 AM   #9
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hi,

Why do you think the underlined code gives an error? It's a listing of what's in the /etc/apache2/conf.d directory. Do you have a directory /etc/phpmyadmin? How did you install PhpMyAdmin?

Kind regards,

Eric
 
Old 01-06-2013, 08:27 AM   #10
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
Hi Eric,

I think phpmyadmin exists, since when I enter the command;

francis@francis-PC:~$ ls /etc/phpmyadmin/
apache.conf config.header.inc.php lighttpd.conf
config-db.php config.inc.php phpmyadmin.desktop
config.footer.inc.php htpasswd.setup phpmyadmin.service

I can see some content.
I installed using sudo/tasksel
first I installed lamp, then I installed phpmyadmin using the command ....sudo apt-get install phpmyadmin and choose apache2. was using a tutorial found in http://www.allaboutlinux.eu/joomla-2-5-3-on-ubuntu/3/
 
Old 01-06-2013, 08:33 AM   #11
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hi,

Thanks for the info. Can you check if you have in /etc/apache2/apache2.conf the following line:
Code:
Include /etc/phpmyadmin/apache.conf
and reply.

Kind regards,

Eric
 
Old 01-06-2013, 08:59 AM   #12
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
Hi Eric,

I've typed the command but what I get is:

francis@francis-PC:~$ ls /etc/apache2/apache2.conf
/etc/apache2/apache2.conf
francis@francis-PC:~$ /etc/apache2/apache2.conf
bash: /etc/apache2/apache2.conf: Permission denied
francis@francis-PC:~$ sudo /etc/apache2/apache2.conf
sudo: unable to resolve host francis-PC
sudo: /etc/apache2/apache2.conf: command not found

What might be the problem?
 
Old 01-06-2013, 09:03 AM   #13
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hello Francis,

That happens because you're not trying to open the file, you're just listing it (ls). Try with this:
Code:
grep phpmyadmin /etc/apache2/apache2.conf
and see if it outputs the line I told you about (Include /etc/phpmyadmin/apache.conf).

Kind regards,

Eric
 
Old 01-06-2013, 09:14 AM   #14
Francis Musyoki
LQ Newbie
 
Registered: Jan 2013
Posts: 10

Original Poster
Rep: Reputation: Disabled
Hi Eric;
When I typed the command it seems their is no matching eord in the file. what is wrong?

francis@francis-PC:~$ grep phpmyadmin /etc/apache2/apache2.conf
francis@francis-PC:~$ grep phpmyadmin /etc/apache2/apache2.conf
francis@francis-PC:~$

kind regards, Francis.
 
Old 01-06-2013, 09:22 AM   #15
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290Reputation: 1290
Hi,

Problem is that the necessary line to include the configuration file for PhpMyAdmin in the Apache configuration, so that Apache can serve your webpages for PhpMyAdmin, is not included. There are a couple of ways to try to fix this, let's take it one by one, starting by the easiest.

Run the following in the terminal:
Code:
sudo dpkg-reconfigure -plow phpmyadmin
That will reconfigure the installation of phpmyadmin and should either include the line in apache.conf or copy the file for PhpMyAdmin to the correct path /etc/apache2/conf.d (or create a symlink. After you did that, if it finishes correctly without throwing an error, check again with the grep command:
Code:
grep phpmyadmin /etc/apache2/apache2.conf
If the line exists, reload apache with the following command:
Code:
sudo /etc/init.d/apache2 reload
and see if you can connect to the PhpMyAdmin page (http://localhost/phpmyadmin. If this is unsuccessful, then run the following:
Code:
sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf.d/phpmyadmin.conf
sudo /etc/init.d/apache2 reload
and try again to connect.

Kind regards,

Eric
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ubuntu 12.04 server - localhost installation - user validation problem. GraceBT Linux - Newbie 2 08-27-2012 03:33 AM
Problem accessing localhost mysql in Ubuntu 11.10 Apache Locally thrash44 Linux - Newbie 1 11-09-2011 11:29 AM
Configuring Automatic Redirects from port 80 to port 443 with bundled Apache server kaplan71 Fedora 1 12-28-2007 08:30 AM
apache : localhost/ works localhost/index.html does not PhilA Linux - Server 4 05-27-2007 07:32 PM
route locally generated traffic to ip:port to localhost:port maenho Linux - Software 2 03-11-2005 04:08 AM


All times are GMT -5. The time now is 10:02 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration