Question

vsftpd: refusing to run with writable root inside chroot()

Posted July 27, 2013 26.5k views
I have installed vsftpd on my Ubuntu 12.04 x32 I have set up vsftpd.conf and uncommented local_enable=YES and write_enable=YES and chroot_local_user=YES (both of them). I had already installed apache server in /home/var/www/ so I did a chown root:root /var/www/ When I try to login with the root username and password to the ftp server. I get the error vsftpd: refusing to run with writable root inside chroot()

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.

×
Submit an Answer
22 answers
Try a another user then root
what other user? The installation did not ask me to assign or create a new user for vsftpd.
I don't know what else to try.
I just created another username and gave it root access. I'm getting the same error.
You have to chmod 755 /var/www as well, it's a vsftpd restriction.
Now I'm getting [7/27/2013 7:57:27 AM] 530 Login incorrect.
I have no idea what's going on.
I did chmod 755 /var/www
no good
Do you see any errors in vsftpd's logs?
How can I check them?
I'm not very experienced with this, sorry.
Run "tail /var/log/vsftpd.log"
I got this

root@maghnatis:~# tail /var/log/vsftpd.log
Sat Jul 27 18:57:50 2013 [pid 2] CONNECT: Client "41.159.129.15"
Sat Jul 27 18:57:52 2013 [pid 1] [root] FAIL LOGIN: Client "41.159.129.15"
Sat Jul 27 18:59:34 2013 [pid 2] CONNECT: Client "41.159.129.15"
Sat Jul 27 18:59:37 2013 [pid 1] [root] FAIL LOGIN: Client "41.159.129.15"
Sat Jul 27 19:01:10 2013 [pid 2] CONNECT: Client "41.159.129.15"
Sat Jul 27 19:01:12 2013 [pid 1] [root] FAIL LOGIN: Client "41.159.129.15"
Sat Jul 27 19:01:29 2013 [pid 2] CONNECT: Client "41.159.129.15"
Sat Jul 27 19:01:32 2013 [pid 1] [root] FAIL LOGIN: Client "41.159.129.15"
Sat Jul 27 19:01:46 2013 [pid 2] CONNECT: Client "41.159.129.15"
Sat Jul 27 19:01:46 2013 [pid 1] [snitz] OK LOGIN: Client "41.159.129.15"
Previous 1 2 3 Next