Question

"error writing /usr/share/nginx/www/info.php: No such file or directory" when trying to save and exit

  • Posted January 16, 2015

Hi all,

New to this stuff and being really overwhelmed. I’m at step 7 in this tutorial and getting the error above.

I just created the file in the previous step so why is it giving me this error?

Thanks

Subscribe
Share

Is this the tutorial you are trying to follow: https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-debian-7

Please provide a link to the tutorial you are following, and this line of information you get when you click on your droplet information in your Digital Ocean control panel… Active 512MB Ram 20GB SSD Disk New York 3 Ubuntu LAMP on 14.04

Are you doing this on Ubuntu 12.04 or on 14.04. That tutorial includes this note:

UPDATE: Newer Ubuntu versions create a directory called 'html' instead of 'www' by default. If /usr/share/nginx/www does not exist, it's probably called html. Make sure you update your configuration appropriately.

This would likely explain the error you are encountering if the www directory does not exist. You will need to ensure you update that path you are using to html instead.


Submit an 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.

This question was answered by @ryanpq:

Are you doing this on Ubuntu 12.04 or on 14.04. That tutorial includes this note:

UPDATE: Newer Ubuntu versions create a directory called 'html' instead of 'www' by default. If /usr/share/nginx/www does not exist, it's probably called html. Make sure you update your configuration appropriately.

This would likely explain the error you are encountering if the www directory does not exist. You will need to ensure you update that path you are using to html instead.

View the original comment