HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=27)
-   -   index.php permission denied error (http://www.howtoforge.com/forums/showthread.php?t=35240)

Leemur 20th May 2009 16:10

index.php permission denied error
 
i followed the guide for ispconfig3 on ubuntu 9.04 server
i createt a site and enabled php, uploaded the php file with the ftp user createt for that site, but when i enter that site i get
Code:

Forbidden
You don't have permission to access /index.php on this server.


--------------------------------------------------------------------------------

Apache/2.2.11 (Ubuntu) PHP/5.2.6-3ubuntu4.1 with Suhosin-Patch mod_ssl/2.2.11 OpenSSL/0.9.8g Server at team-monkey.dk Port 80

phpmyadmin works fine, so my php is working.

so what am i missing?

till 20th May 2009 21:31

Please make sure that you accessed the website trogh the domain name of the site. If you did that already and not used e.g. the ip or so, then take a look in the error log and post the error message that is logged there.

Leemur 21st May 2009 09:21

I do access it through the domain.
I can't seem to find any errors in the logs, the only thing i can find is this

/var/log/apache2/other_vhost_acces.log
Code:

team-monkey.dk:80 192.168.0.10 - - [21/May/2009:09:08:48 +0200] "GET /index.php HTTP/1.1" 403 289 "-" "Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64;
Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0)"

is there a specific place i can look? maybe i just didn't see the error:confused:

to me it looks like the vhost don't got permission to run the PHP files, but the vhost file looks fine to me :confused:

Edit: i did overlook something
Code:

[Thu May 21 09:08:53 2009] [error] [client 192.168.0.10] client denied by server configuration: /var/www/team-monkey.dk/web/index.php

till 21st May 2009 09:28

1) Do you have any .htaccess files in this directory?
2) Post the output of:

ls -la /var/www/team-monkey.dk/web/index.php

Leemur 21st May 2009 09:50

ls -la /var/www/team-monkey.dk/web/index.php
Code:

-rw-r--r-- 1 web4 client1 20 2009-05-20 14:45 /var/www/team-monkey.dk/web/index.php
hmm that dosn't got the same permissions as the default index.html, that could be the problem.
but shouldn't it get the right permission when you upload it? else you would have to edit it for every site you upload :confused:

and i got no .htacces in that folder

Leemur 21st May 2009 09:52

Just chmod'ed it to 777 to see if it's the permission on the file and it didn't seem to do the trick :confused:

till 21st May 2009 09:57

Most likely you accessed the site by a wrong URL like http://yourip/team-monkey.dk/web/index.php. Just enter into your browser:

http://team-monkey.dk/

Leemur 21st May 2009 10:57

that's all i'm doing.

just typing http://team-monkey.dk/

falko 21st May 2009 18:48

What's the output of
Code:

ls -la /var/www/team-monkey.dk/web/
?

What PHP mode are you using? mod_php, fastCGI, CGI, suPHP?

Leemur 27th May 2009 08:45

Output of "ls -la /var/www/team-monkey.dk/web/"
Code:

drwxr-xr-x  9 web4 client1 4096 2009-05-22 11:40 .

drwxr-xr-x  6 root root    4096 2009-05-20 14:06 ..

drwxr-xr-x  2 web4 client1 4096 2009-05-20 14:06 error

-rwxr-xrwx  1 web4 client1  20 2009-05-20 14:45 index.php

drwxr-xr-x  2 root root    4096 2009-05-21 00:30 stats

i have tryed all php modes :confused:


All times are GMT +2. The time now is 01:05.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.