ipsec安裝好后運行ipsec verify命令發現錯誤的解決方案


Checking your system to see if IPsec got installed and started correctly:
Version check and ipsec on-path [OK]
Linux Openswan U2.6.33/K3.0.18-x86_64-linode24 (netkey)
Checking for IPsec support in kernel [OK]
SAref kernel support [N/A]
NETKEY: Testing XFRM related proc values [OK]
[OK]
[OK]
Checking that pluto is running [OK]
Pluto listening for IKE on udp 500 [OK]
Pluto listening for NAT-T on udp 4500 [OK]
Two or more interfaces found, checking IP forwarding [OK]
Checking NAT and MASQUERADEing
Checking for 'ip' command [OK]
Checking /bin/sh is not /bin/dash [OK]
Checking for 'iptables' command [OK]
Opportunistic Encryption Support [DISABLED]

這樣的狀態就是正常的了、已經通過了驗證

 

==========================================

如果邇發現這行是WARNING的話

Checking /bin/sh is not /bin/dash                               [WARNING]

因為ubtuntu和debian系統已經使用dash來代替bash腳本執行器、雖然dash更快更方便、但在某些腳本兼容性上還是不太穩定、莪們可以將ubuntu默認的腳本執行方式改回bash來執行、執行以下命令

sudo dpkg-reconfigure dash

按英文提示、選擇no、就可以把dash切換成bash、再執行ipsec verify就不會出現WARNING的提示了

=========================================

Pluto listening for IKE on udp 500                              [FAILED]
Cannot execute command "lsof -i UDP:500": No such file or directory
Pluto listening for NAT-T on udp 4500 [FAILED]
Cannot execute command "lsof -i UDP:4500": No such file or directory

如果出現以上的問題、就是沒安裝lsof的命令啦、安裝就可以了

apt-get install lsof





免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM