Hello
I’m following several tutorials on setting up a lamp server en such. I now have a working lamp server with firewall enabled. I read that it is good practice to disable the root account and create a second user with sudo access.
Everything went well, I can connect with PuttY but when I wanted to connect with filezilla I can’t upload or modify files. With the root account everything works, but with the second account it does not.
I used following tutorial: https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-14-04
I’m not sure if I’m missing someting here. I’m using the same ssh key for root as for the second account.
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!
Instead of:
sudo chmod -R 775 /var/www/
You could use these two commands to set appropriate file and folder permissions:
sudo find /var/www/[new directory]/ -type f -exec chmod 664 {} ; sudo find /var/www/[new directory]/ -type d -exec chmod 775 {} ;
And then try on with more restrictive permissions until you’re satisfied.
Give the directories you want them to write in the right permissions using chown/chmod.
Thanks for the anwser, now I’ve been looking around and used this to achieve my goal. Is this a correct solution?
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.