-   Debian (
-   -   Configuring website permissions on Debian (

takeit 07-05-2012 06:46 AM

Configuring website permissions on Debian
I'm owning dedicated server with Debian 6 Squeeze 6 LAMP installed.
I pointed my domain (where is my domain name) to my dedicated server, and now I have some privilages problems and dont know how to solve it.

1. User that runs apache2 is www-data,
2. My domain folder is located in: /var/www/
3. In /etc/apache2/sites-available/ I have created file which content is:

<VirtualHost *:80>
# Indexes + Directory Root.
DirectoryIndex index.php
DocumentRoot /var/www/

<Directory "/">
Options FollowSymLinks
AllowOverride None
<Directory /var/www/>
AllowOverride All
Options -Indexes MultiViews
Order Allow,Deny
Allow from all
4. I executed a2ensite command with success and restarted apache
5. I gave files permissions in /var/www/:

chmod -R 755
  chmod -R 655
  chown -R www-data

6. In /var/www/ I have folder: test, which has another index.php file. Like /var/www/

When I open the content of index.php is displayed
but when I want to go to or it displays me white (blank) page..

How to make whole website content to be accessible by users visiting my website?

Thank you

bathory 07-05-2012 12:05 PM


A blank php page means some php problem. Check apache error_log to see if you can find what it is.
Regarding permissions, apache is happy using 755 for directories and 644 for files (regardless the owner, unless you're running a SELinux enabled distro that is not the case here).


takeit 07-05-2012 01:29 PM

thank you there was an error in file, its working now

All times are GMT -5. The time now is 11:01 AM.