index.php permission denied error

Discussion in 'Installation/Configuration' started by Leemur, May 20, 2009.

  1. Leemur

    Leemur New Member

    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?
     
    Last edited: May 20, 2009
  2. till

    till Super Moderator

    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.
     
  3. Leemur

    Leemur New Member

    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
     
    Last edited: May 21, 2009
  4. till

    till Super Moderator

    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
     
  5. Leemur

    Leemur New Member

    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
     
  6. Leemur

    Leemur New Member

    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:
     
  7. till

    till Super Moderator

  8. Leemur

    Leemur New Member

  9. falko

    falko Super Moderator

    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?
     
  10. Leemur

    Leemur New Member

    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:
     
  11. till

    till Super Moderator

    Which ISPConfig version do you use?
     
  12. Leemur

    Leemur New Member

    i use version 3.0.1.1
     
  13. Leemur

    Leemur New Member

    just did an update to 3.0.1.3 and recreated the site and now it works :)
     
  14. Leemur

    Leemur New Member

    this is getting strange, just did a reboot and now i got the same error again :mad:

    guess i just remove it completely and try again
     
  15. Leemur

    Leemur New Member

    when i try to reinstall ISPconfig apache comes with an error
    Code:
     Warning: DocumentRoot [/var/www/team-monkey.dk/web] does not exist
    i looked trough the apache files to see where it got it from and i think i found the reason to my trubles

    In the default vhost file i got a site configured as team-monkey.dk, the funny thing is i have never touched that file, there is no PHP configured in that file - i guess thats why i couldnt get permission to parse the php files
     

Share This Page