1. 程式人生 > >python之Linux基礎(十)

python之Linux基礎(十)

常⽤伺服器ftp、ssh 1. Linux常⽤伺服器構建-ftp伺服器
ftp伺服器
FTP 是File Transfer Protocol(⽂件傳輸協議)的英⽂簡稱,⽽中⽂簡稱為“⽂傳協議”。
⽤於Internet上的控制⽂件的雙向傳輸。
同時,它也是⼀個應⽤程式(Application)。基於不同的作業系統有不同的FTP應⽤程 序,⽽所有這些應⽤程式都遵守同⼀種協議以傳輸⽂件。
在FTP的使⽤當中,⽤戶經常遇到兩個概念:"下載"(Download)和"上傳"(Upload)。
"下載"⽂件就是從遠端主機拷⻉⽂件⾄⾃⼰的計算機上;
"上傳"⽂件就是將⽂件從⾃⼰的計算機中拷⻉⾄遠端主機上。⽤Internet語⾔來說,⽤戶可 通過客戶機程式向(從)遠端主機上傳(下載)⽂件。
python之Linux基礎(十)


安裝vsftpd伺服器
sudo apt-get install vsftpd
python之Linux基礎(十)
配置vsftpd.conf⽂件
sudo vi /etc/vsftpd.conf

python之Linux基礎(十)
python之Linux基礎(十)

python之Linux基礎(十)

python之Linux基礎(十)
python之Linux基礎(十)

python之Linux基礎(十)

python之Linux基礎(十)
python之Linux基礎(十)
python之Linux基礎(十)
python之Linux基礎(十)
python之Linux基礎(十)

3.測試上傳功能,登陸ftp伺服器

ftp IP
python之Linux基礎(十)

上傳命令,可以把⽂件上傳到ftp伺服器

put somefile
5.下載命令,可以把ftp伺服器上的⽂件下載到本地
get somefile
圖形界⾯的ftp客戶端(filezilla)

python之Linux基礎(十)