0

I set up a new Ubuntu server with one user to whom I granted full permissions by adding jsmith ALL=(ALL) ALLto the /etc/sudoersfile. The idea being that I would be able to never log in as root and use jsmith all the time for the day-to-day administration of the server.

I want to use Coda to upload files to the server, logging in as jsmith rather than root.

Unfortunately, when I log in to the server under SFTP using root, I can upload files without issues. If I log in as jsmith, I can connect to the server and navigate all the way up to its root, but if I try to upload a file I get an error [screenshot here: http://i.via.dj/CRvH]

I suspect I've overlooked something in the configuration, but despite googling the issue I haven't been able to find a solution.

Any suggestions welcome.

1 Answer 1

1

The /etc/sudoers file gives you permissions when you are logged on to the server. When you use FTP you should have permissions for the user to allow to write to the directory or files that you are attempting to write to such as:

drwxr-xr-x  18 jsmith jsmith 4096 Dec  9 12:44 .

This directory is owned by jsmith and jsmith will be able to dump files into it.

if you have this however:

drwxr-xr-x  18 root root 4096 Dec  9 12:44 .

jsmith will not be permitted to write the files there

And BTW, the screenshot link doesn't seem to work.

2
  • Thanks! I solved it like this: chown -R jsmith /var/www/ Dec 10, 2011 at 8:25
  • 1
    Unless jSmith is the only user that will be working with the web directory. I'd strongly recommend against doing what you did.
    – Karlson
    Dec 12, 2011 at 14:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .