TFTP 在Linux的安裝與使用
前言:
TFTP 是 FTP 的簡化版本。TFTP 沒有身份驗證功能,它在 UDP 端口 69 上運行。
由於它非常輕量級,到現在厰商都會預設選用TFTP 協議,如: BOOTP、PXE 網絡引導協議,網絡裝置存儲配置文件和固件的備份與還原等等。
目錄內容:
TFTP 伺服器的安裝與設定
在範例中會在Linux Deepin 20.3 上安裝tftpd-hpa TFTP 服務器包。可以在官方軟件倉庫(APT Repository)輕鬆安裝。
sudo apt update
sudo apt install tftpd-hpa -y
TFTP 伺服器文件配置
sudo vim /etc/default/tftpd-hap
只修TFTP目錄和參數
TFTP_DIRECTORY="~/ftfp" #為家目錄的tftp文件夾TFTP_OPTIONS="--ipv4 --secure --create" #允許IPV4地址及可寫入目錄
創建家目錄的tftp文件夾及屬性
mkdir -p ~/tftp && chown tftp:tftp ~/tftp
重新啟動tftpd-hpa服務,使設定生效
sudo systemctl restart tftpd-hpa
檢查tftpd-hpa服務是否正在運行:
sudo systemctl status tftpd-hpa
可見active (running) 代表配置正確及可正常啟動。
TFTP 客戶端的安裝與使用
在範例中會在Ubuntu 20.04.3上安裝tftp-hpa TFTP 客戶端。
sudo apt update
sudo apt install tftp-hpa
TFTP 服務器的IP地址是: 192.168.192.56
在TFTP 客戶端使用以下指命連入伺服器:
put .bashrc
get dde-introduction.mp4
範例:
透過建立的TFTP伺服器保存交換機配置文件。
備份H3C Switch 的備份設定
tftp 10.10.10.23 put startup.cfg
在TFTP伺服器可查看到已經上載的startup.cfg
配置文件
備份Cisco Switch 的備份設定
enable
copy running-config tftp
輸入TFTP伺服器IP地址: 10.10.10.23
-> Enter
在TFTP伺服器可查看到已經上載的core-switch-config
配置文件
結語:
這是最基本的設定與使用,希望往後還有時間學習及折騰一下PXE的網絡啟動。
Simplifez votre choix avec Inventonslemondedapres, le comparateur qui analyse les moindres détails des
casinos en ligne pour vous !
Great delivery. Outstanding arguments. Keep up the great work.
site
Hmm it seems like your website ate my first comment (it was extremely long) so I
guess I'll just sum it up what I submitted and say, I'm
thoroughly enjoying your blog. I too am an aspiring blog writer but I'm still new to everything.
Do you have any suggestions for first-time blog writers?
I'd certainly appreciate it.
casino en ligne France
excellent points altogether, you just gained a new reader.
What could you suggest in regards to your put up that you simply made some days in the past?
Any sure?
web site
hi!,I like your writing so much! percentage we
keep in touch more approximately your article on AOL?
I require a specialist in this area to unravel my problem.
Maybe that's you! Taking a look ahead to peer you.
site
This is a topic which is near to my heart... Take care! Where are your contact details though?
casino en ligne
What's up, I want to subscribe for this webpage to get most recent updates, thus where can i do it please
help.
casino en ligne fiable
A person necessarily assist to make critically posts I would state.
That is the very first time I frequented your web page and up to now?
I amazed with the analysis you made to make this particular publish extraordinary.
Magnificent process!
casino en ligne
Thanks very interesting blog!
web page
We're a bunch of volunteers and opening a brand new scheme in our community.
Your website provided us with valuable information to work on. You've done an impressive task and our entire community will
be thankful to you.
web site
This is very interesting, You're a very skilled blogger.
I have joined your rss feed and look forward to seeking more of your wonderful post.
Also, I have shared your web site in my social networks!
casino en ligne
Simplifiez votre recherche avec Inventonslemondedapres, le comparateur qui analyse minutieusement chaque casino
en ligne !