I'm trying to solve a problem about write permission.
I have the user mamuth in the group www-data, i used the command:
adduser mamuth www-data
Running:
cat /etc/group | grep mamuth
Results with:
adm:x:4:syslog,mamuth
cdrom:x:24:mamuth
sudo:x:27:mamuth
dip:x:30:mamuth
www-data:x:33:mamuth
plugdev:x:46:mamuth
mamuth:x:1000:
lpadmin:x:114:mamuth
sambashare:x:115:mamuth
So now when i check the /var
right permission i have the following result:
drwxrwxr-x 5 www-data www-data 4096 Feb 20 15:20 www
I used the command to be sure to have right permission to write everything as mamuth (fed up to use sudo emacs to write in file):
sudo chown -R www-data:www-data /var/www/
sudo chmod -R g+w /var/www/
I don't know what's wrong while I still don't have permission as for example in /var/www/ i'm tryng to use as mamuth user the command:
emacs test
and typing some text
emacs display the message:
Buffer is read-only: #<buffer toto>
su - mamuth
orsu --login mamuth
or (with sudo)sudo -i -u mamuth
– steeldriver Feb 20 '18 at 16:05