Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Problems with Apache2
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
MaxMara
n00b
n00b


Joined: 31 Aug 2004
Posts: 35
Location: Vienna/Austria

PostPosted: Thu Nov 17, 2005 8:14 am    Post subject: Problems with Apache2 Reply with quote

Hi!

I have some strange problems with apache2 after doing an emerge -u.
When I try to browse to one of my websites (I only have virtualhosts ) a box opens and asks me what I want to do with this file: application/x-httpd-php....save it or open it with an associated program.
In the httpd.conf I have the entries:
DirectoryIndex index.php
AddType application/x-httpd-php .php
LoadModule php4_module extramodules/libphp4.so

and in each vhost-entry I also have: DirectoryIndex index.php (just to make sure... ;) )

He only opens this box when I use the normal url like http://www.website.com. But if I use http://www.website.com/index.php it works without any problems.

Does anyone of you know whats wrong with my config?

Thanks
Christian.
Back to top
View user's profile Send private message
Crimson Rider
Guru
Guru


Joined: 23 Jun 2003
Posts: 462
Location: Delft, the Netherlands

PostPosted: Thu Nov 17, 2005 10:23 am    Post subject: Reply with quote

Hey MaxMara,

I have been having the same problems some time ago. In my case it turned out to be a PHP4 vs. PHP5 problem. I take it you have PHP4 installed, can you check if you have a line that says something like

Code:
APACHE2_OPTS="-D DEFAULT_VHOST -D DAV -D PHP4 -D SSL -D DOC"


In your /etc/conf/apache2 file ?

Good luck
This answer brought to you by the Adopt an unaswered post initiative
_________________
Code, justify, code - Pitr Dubovich
Back to top
View user's profile Send private message
MaxMara
n00b
n00b


Joined: 31 Aug 2004
Posts: 35
Location: Vienna/Austria

PostPosted: Thu Nov 17, 2005 11:01 am    Post subject: Reply with quote

Thanks for your answer Crimson Rider,

but I have the same line in my /etc/conf.d/apache2 :cry:
Back to top
View user's profile Send private message
Crimson Rider
Guru
Guru


Joined: 23 Jun 2003
Posts: 462
Location: Delft, the Netherlands

PostPosted: Thu Nov 17, 2005 11:54 am    Post subject: Reply with quote

If you have that line, then you shouldn't need any extra lines in your virtual hosts directives.
You could try removing them and see if it works with that minimal config.

Altough the fact that you say that www.url.com/index.php works but www.url.com doesn't is weird to say the least.
_________________
Code, justify, code - Pitr Dubovich
Back to top
View user's profile Send private message
MaxMara
n00b
n00b


Joined: 31 Aug 2004
Posts: 35
Location: Vienna/Austria

PostPosted: Thu Nov 17, 2005 1:51 pm    Post subject: Reply with quote

The strangest thing I just found out is:
people who visit my website from outside (not from our LAN) don't have this problem. This happens only if someone in our LAN wants to open our website.
Hope this makes it easier to solve my problem...

Thanks again.
Back to top
View user's profile Send private message
Crimson Rider
Guru
Guru


Joined: 23 Jun 2003
Posts: 462
Location: Delft, the Netherlands

PostPosted: Fri Nov 18, 2005 8:45 am    Post subject: Reply with quote

Does your LAN run a proxy perhaps?
Does your Apache virt. host file depend on IP or DNS ?
Is the DNS your LAN get's any different then those outside.

You could change the virt. host entry to be your default entry, then look up the site with just the ip. Just to test.
_________________
Code, justify, code - Pitr Dubovich
Back to top
View user's profile Send private message
MaxMara
n00b
n00b


Joined: 31 Aug 2004
Posts: 35
Location: Vienna/Austria

PostPosted: Fri Nov 18, 2005 9:23 am    Post subject: Reply with quote

Hi again!

After purging squids cache everything worked out fine. Thank you very much. :)
Back to top
View user's profile Send private message
Crimson Rider
Guru
Guru


Joined: 23 Jun 2003
Posts: 462
Location: Delft, the Netherlands

PostPosted: Fri Nov 18, 2005 9:48 am    Post subject: Reply with quote

Wow, the proxy thing suggestion was a long shot :) Glad it worked out.
_________________
Code, justify, code - Pitr Dubovich
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum