search
Homephp教程PHP开发How to enable FTP service under linux

How to enable FTP service under Linux


1. First, the server needs to install ftp software. Check whether the ftp software has been installed:
#which vsftpd
If you see a vsftpd directory, it means that the server has installed ftp software

2 . Check the ftp server status
#service vsftpd status

3. Start the ftp server
#service vsftpd start

4. Restart the ftp server
#service vsftpd restart

5. Check whether the service is started
#netstat -an | grep 21
tcp 0 0 0.0.0.0:21 0.0.0.0:* tcp LISTEN
If you see the above information, it proves that the ftp service has been started.

6. If you need to enable the root user's ftp permissions, you need to modify the following two files
#vi /etc/vsftpd.ftpusers and comment out root
#vi /etc/vsftpd.user_list also comment out root
Then restart ftp Serve.

7. vsftpd 500 OOPS: cannot change directory
Login error:
C:>ftp 192.168.0.101
Connected to 192.168.0.101.
220 (vsFTPd 2.0.5)
User (19 2.168.0.101:(none)) : frank
331 Please specify the password.
Password:
500 OOPS: cannot change directory:/home/frank
Login failed.
ftp> ls
500 OOPS: child died
Connection closed by remote host.
Solution:
setsebool ftpd_disable_trans 1
service vsftpd restart
and it’s OK!

This is the SELinux setting command. Before you are familiar with SELnux, you can also turn off SELinux.

8. Permanently enabled, that is, the ftp service is automatically turned on after the os is restarted
Method one:
cd /etc/xinetd.d, edit the configuration file gssftp of the ftp service:
vi /etc/xinetd.d/gssftp, change Modify two items:

(a) server_args = -l –a Remove -a and change to server_args = -l
(b) disable=yes to disable=no
(c) Save and exit.

Method 2:
(a) system-config-services, enter the System services of the graphical interface to see if there is a vsftpd item, if not go to 2., save and exit

(b) Use the third disk of redhat to install this Services (Start--Delete/Add Programs), about 200K

  (c) #setup
  You can see the vsftpd item at this time, select this services item at this time, save and exit.



More For related articles on how to enable FTP service under Linux, please pay attention to the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
1 months agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft