As it is in the topic the problem is with vsftpd. For some time i used it normally and everything worked good. But once i started vsftpd and it gave out the message:
500 OOPS: config file not owned by correct user, or not a file
After some searching i tried:
to change the owner of the vsftpd.conf file by
sudo chown root vsftpd.conf
;to remove vsftpd and install again;
- to purge vsftpd and install again;
- to delete the content of the conf file and paste examples from internet.
Nothing helped, it did not work since. It is Ubuntu 16.04
Thank you in advance.
I don't know if you still need this, but I had the same problem recently I Google around and found This Page. The major difference I found was that I was trying to start the server by typing:
# vsftpd
Instead of:
# systemctl start vsftpd
in the terminal. I hope this helped.
The error is seen while running
vsftpd
as a background process.I could not resolve the error, but I successfully ran the service.
Running the following command's(In Ubuntu) worked out for me:
Note: After this status, the FTP was successfully running on port 21.
"Virtual" users
If you have, in your root:root-owned
/etc/vsftpd.conf
, something likeso that user
joe
uses further config in/etc/vsftpd/users/joe
, well, then that directory and that file must also be owned by root and not world readable.The difference is that in this case the 500 OOPS will only be shown after a successful login (i.e. once
vsftpd
has determined that you are userjoe
, and may then read the appropriate configuration file).This answer was a good indication to find the problem. In my case next commands were the cause:
#*** block access to shell in two steps ****
#1) assign the user's shell to false
usermod -s /bin/false
#2) add false to the shell list
echo /bin/false >> /etc/shells
after commenting them out the server started. So,first make sure that the server runs with your admin user then do things with other users as a ftp user.