Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have problems giving my FTP user who does not have sudo rights, write permission to /var/www.


How can I give the FTP user write permission to /var/www & subfolders only?

ls -ld says:

1@1:/var/www$ ls -ld
drwxrwsr-x 2 root www-data 4096 Feb 17 13:44 .

Groups of ftpuser:

# groups ftpuser
ftpuser : ftpuser www-data
share|improve this question
Do you have write_enable=YES in your vsftpd.conf? You won't be able to write anywhere if that's disabled, which is the default configuration. –  hcsteve Feb 17 at 13:29
Thank you hcsteve, this solved it! –  user2167 Feb 17 at 13:31
What do you guys think about the permission settings on /var/www , is the drwxrwsr-x 2 root www-data 4096 Feb 17 13:44 . secure? I eventually messed a bit with chmod –  user2167 Feb 17 at 13:33
i just recognized, if i visit the webspace /var/www directory with the broser it says permission denied. –  user2167 Feb 17 at 13:38
I posted the bit about write_enable as an answer - please accept it if that solved your issue. For the browser errors, I'd suggest checking your web server logs and the web server documentation for more information. If you still need help with that issue you should post a new question. –  hcsteve Feb 17 at 13:54

1 Answer 1

up vote 3 down vote accepted

Your vsftpd.conf file should contain write_enable=YES if you want to enable write support. From man vsftpd.conf:


This controls whether any FTP commands which change the filesystem are allowed or not. These commands are: STOR, DELE, RNFR, RNTO, MKD, RMD, APPE and SITE.

Default: NO

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.