SHARE
TWEET

Untitled

a guest Feb 5th, 2018 75 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $ sudo -u www-data touch test
  2. touch: cannot touch 'test': Permission denied
  3. $ mkdir test
  4. $ sudo chown $USER:www-data test/
  5. $ sudo -u www-data touch test/test
  6. touch: cannot touch 'test/test': Permission denied
  7. $ chmod g+rw test/
  8. $ sudo -u www-data touch test/test
  9. $ ls -la test/test
  10. -rw-r--r-- 1 www-data www-data 0 Feb  5 17:16 test/test
  11. $ sudo adduser www-data $USER
  12. Adding user `www-data' to group xxx
  13. Done.
  14. $ sudo service apache2 restart
  15. $ mkdir test2
  16. $ sudo -u www-data touch test2/test
  17. touch: cannot touch 'test2/test': Permission denied
  18. $ chmod g+rw test2
  19. $ sudo -u www-data touch test2/test
  20. $ ls -la test2/test
  21. -rw-r--r-- 1 www-data www-data 0 Feb  5 17:23 test2/test
  22. $ groups www-data
  23. www-data : www-data xxx
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top