FTP Server Client Configuration

FTP Server Client Configuration:

[root@rhel6server ~]# yum install vsftpd rpcbind xinetd -y
[root@rhel6server ~]# rpm -qa vsftpd*
[root@rhel6server ~]# rpm -qa rpcbind*
[root@rhel6server ~]# rpm -qa xinetd*

[root@rhel6server ~]# chkconfig vsftpd on
[root@rhel6server ~]# chkconfig rpcbind on
[root@rhel6server ~]# chkconfig xinetd on

[root@rhel6server ~]# service xinetd status
xinetd is stopped
[root@rhel6server ~]# service xinetd start
Starting xinetd: [ OK ]
[root@rhel6server ~]# service xinetd status
xinetd (pid 5187) is running…
[root@rhel6server ~]# service rpcbind status
rpcbind is stopped
[root@rhel6server ~]# service rpcbind start
Starting rpcbind: [ OK ]
[root@rhel6server ~]# service rpcbind status
rpcbind (pid 5234) is running…

[root@rhel6server ~]# useradd ftpuser
[root@rhel6server ~]# passwd ftpuser
[root@rhel6server ~]# su – ftpuser
[ftpuser@rhel6server ~]$ vim test1

C:\Users\hp>ftp 192.168.211.128
Connected to 192.168.211.128.
220 (vsFTPd 2.2.2)
User (192.168.211.128:(none)): root
530 Permission denied.
Login failed.
ftp> ftp 192.168.211.128
Invalid command.
ftp> bye

Remove or comment out the line for user “root” and add “ftpuser” instead. Users whose name are set in this file will not allowed to login from ftp.comment root user
[root@rhel6server ~]# vi /etc/vsftpd/ftpusers
#root
Open /etc/vsftpd/user_list file. Remove or comment out entry in /etc/vsftpd/user_list files. Remove or comment out the line for user “root” and add “ftpuser” instead. Users whose names are set in this file are also not allowed to login from ftp even they are not prompt for password.
# vi /etc/vsftpd/user_list

[root@rhel6server ~]# service vsftpd restart

C:\Users\hp>ftp 192.168.211.128
Connected to 192.168.211.128.
220 (vsFTPd 2.2.2)
User (192.168.211.128:(none)): ftpuser
331 Please specify the password.
Password:
230 Login successful.
ftp>

To enable FTP Banner:

[root@rhel6server ~]# vi /etc/vsftpd/vsftpd.conf
# You may fully customise the login banner string:
ftpd_banner=Welcome to RHEL 6 SERVER
C:\Users\hp>ftp 192.168.211.128
Connected to 192.168.211.128.
220 Welcome to RHEL 6 SERVER
User (192.168.211.128:(none)): ftpuser
331 Please specify the password.
Password:
230 Login successful.