Friday, July 31, 2015

Configure FTP server
Server side configuration:

1. Check for service  and install packages
rpm -qa  | grep   -i  vsftpd*
install service
yum  install vsftpd
2. Configure files
 * **    all configure files are under  /etc/vsftpd   dir ***
create dir and folder to
vi  /etc/vsftpd/vsftpd.conf
                configure as per your requirement
                local_ebable =YES
                local_umask =022
                write_enable=YES
3.Restart  and stop all  necessary  services
·         check for selinux services
check the Boolean value of selinux for FTP
getsebool -a | grep ftp
----Grant full acess  on selinux----- 
 # setsebool change allow_ftpd_full_access=on
check the status of selinux
   getenforce
set status to permissive mode
setenforce  0

·         Check satus of iptables
service iptables status
stop iptables
service iptables stop


Client side :

make sure following configuration is done
·         vsftpds install
·         iptables is disable
·         in order to run ftp in command mode use # yum  install -y ftp
now  on browerer
ftp:// IP of server   can access the default path
/var/ftp/pub

local user login by using lftp
yum install lftp
  • create a local user
  • set up the permission for file (ie 755 or 777)
  • create dir and files user home account
  • set selinux in permissive mode.(setenforce 0)
  • ftp localhost
  • login: user name and passwd
  • ftp> ls
Stop user to login
·         vi   /etc/vsftp/ftpusers
·         add user
·         service vsftpd  reload
·         try to login vi ftp
·         login fail (530)
·          
                stop user to Rome different directory beside his.
·         vi /etc/vsftpd/vsftpd.cong
·         add following lines or enable.
                                chroot_local_user=YES
                chroot_list_enable=YES
                chroot_list_file=/etc/vsftpd/chroot_list
                Add user to allow to Rome in different dir or files
·         create a file name chroot_list inside  /etc/vsftpd
·         enter user name to allow for roaming.

Note: To check the port no of VSFTPD
netstat   -tulpn | grep vsftpd







No comments:

Post a Comment