Report this

What is the reason for this report?

How I edit index.html? My droplet is Ubuntu LAMP on 14.04

Posted on November 14, 2014

I just created a droplet Ubuntu LAMP on 14.04. I am trying to change index.html via filezilla in sftp://miusuario@mydomian.co/var/www/html/index.html Howevere, when I upload my index.hmtl I get the error Error: /var/www/html/index.html: open for write: permission denied. I am following this tutorial: https://www.digitalocean.com/community/tutorials/how-to-use-filezilla-to-transfer-and-manage-files-securely-on-your-vps and everything worked fine until this point. What should I do? I also granted the permissions to “miusuario” suggested in this Tutorial: https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-12-04 so I added the lines in visudo:

miusuario ALL=(ALL:ALL) ALL

Thanks in advance



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

If you want to be able to edit the file directly using Filezilla over SFTP, you’ll need to add your user to the www-data group and allow all members of that group to edit files. Run:

sudo usermod -a -G www-data foo
sudo chown -R www-data:www-data /var/www/html/
sudo chmod -R g+rw /var/www/html/

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.