I am having some trouble creating files in directory on my Ubuntu machine:

I added myself to the www-data group in order for me to easily edit stuff in my /var/www dir on my development machine.

stat /var/www shows the following:

  File: ‘/var/www’
  Size: 4096        Blocks: 8          IO Block: 4096   map
Device: 808h/2056d  Inode: 142853      Links: 3
Access: (0775/drwxrwxr-x)  Uid: (   33/www-data)   Gid: (   33/www-data)
Access: 2010-12-30 16:03:18.563998000 +0100
Modify: 2010-12-30 16:02:52.663998000 +0100
Change: 2010-12-30 16:03:13.111998001 +0100

Still, it is impossible for me to create anything below /var/www (the only way for it to work is to chmod it to 777. What am I missing?

  • post group file? or at least the relevant lines? – Ablue Dec 30 '10 at 15:27

Have you tried logging out? Or opening a new terminal window so that it picks up your new group information?

  • it might also work without logging out using the command: $id username – Daniel t. Dec 30 '10 at 16:55
  • Logging out and logging in solved the problem. Argh! :) – Aron Rotteveel Dec 31 '10 at 14:27

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.