I'm running an Ubuntu server with apache2/mod_mono

Ive got:


The only way I've been able to get this all working is by:

chown -R www-data:www-data /home/user/www

I'd like to be able to connect as 'user' using WinSCP and edit the contents of /home/user/www but I've tried all sorts of user and group permissions and cant get it working. I'm sure there are some basics of permissions that I'm not understanding. How should I be doing this?


Add user to the www-data group:

$ useradd -G www-data user

Set proper permissions on the target folder:

$ chown -R user.www-data /home/user/www
$ chmod -R g+w /home/user/www

The two above commands set the file/directory ownership properly and then grant the group owner write permissions.

  • I'd already somehow managed to add the user to www-data group! Thanks – Tim Oct 14 '10 at 13:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.