How to make /var/www directory writeable in ubuntu.

How to make /var/www directory writeable in ubuntu.

If you install Linux Apache MySQL Php(LAMP), you might need to access the www directory(dir) to do some dirty work. Unfortunately, the directory permission won’t allow you to access them. To fix this, just edit the dir permission like below.

Add Your username to www-data group

change the ownership of www dir to www-data

add access to group member to read, write and execute to the dir

Done. You are now have access to the dir. Now go and do your dirty work! 🙂

p/s: you need to logout and login again to make sure the group membership to take effect.

Leave a Reply

Close Menu