LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   ftp not work (https://www.linuxquestions.org/questions/linux-server-73/ftp-not-work-4175449248/)

!! hack-back !! 02-08-2013 08:24 PM

ftp not work
 
hello minds,
i try to install proftpd pure-ftpd vsftpd
but in all i have the same problem
"530 Login incorrect."
and i make useradd and put password for it!!
any help please
thank you

fortran 02-08-2013 11:53 PM

Please tell your distribution with version.

Have you disabled SElinux? use following command to disable it.
$ echo 0 > /selinux/enforce
or
$ setenforce 0

The following parameters should be in vsftpd.conf file

anonymous_enable=NO
local_enable=YES
write_enable=YES
connect_from_port_20=YES
chroot_local_user=YES
listen=YES
local_root=/var/www/html
pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES

If not, set these parameters and restart the vsftpd using
$ service vsftpd restart

!! hack-back !! 02-09-2013 05:35 AM

i set these parameters but the same problem
what is the correct way to add new user ? may be this is the problem ?
thank you

fortran 02-09-2013 05:59 AM

Add new ftp user using following command.
$ sudo adduser -c 'FTP USER hacker' -m hacker
where username is hacker, now set password for this new user.
$ sudo passwd hacker

Now try to login with these new details.

!! hack-back !! 02-09-2013 07:12 AM

with out adding group for the user ??

---------- Post added 02-09-13 at 08:12 AM ----------

and how the user will access for ftp only ?

!! hack-back !! 02-09-2013 07:16 AM

i mean i want it to just login with ftp not ssh also

fortran 02-09-2013 07:24 AM

If you are trying to login using root user, it is not possible. It will give following error.
Code:

Response:        530 Permission denied.
Error:        Could not connect to server

Root user can be connected using sftp.

But if you are trying to connect using normal user which you made during installation or adduser command. It should be logged in.
But if your SElinux is enabled, it does not give login incorrect error. Generally it gives following error.
Code:

"500 oops cannot change directory /home/user in ftp"
can you tell me your linux distribution and version like are you using centOS or ubuntu or fedora?

If you are trying to login using regular user and you have set above parameter. It should log in.
There should not be repeat parameter in the file. Linux will read above one.
Example - You have pasted these parameters at bottom of the page in conf file. It will not work.
You have to search the parameter in the conf file and set the according to above comment.

!! hack-back !! 02-09-2013 07:26 AM

thank you pavi_kanetkar
its all done :)


All times are GMT -5. The time now is 11:22 AM.