ubuntu下載安裝文件和依賴包


1、apt update  更新包信息

2、發現包的依賴並下載到當前目錄,以下載包iputils-ping 為例

apt download  `apt-cache depends iputils-ping | grep Depends | cut -d: -f2 | tr -d "<>"`

apt download iputils-ping

3、使用dpkg安裝,deb文件就是第二步下載的文件

dpkg --install libc6_2.31-0ubuntu9.2_amd64.deb libgcrypt20_1.8.5-5ubuntu1_amd64.deb libcap2_1%3a2.32-1_amd64.deb libcap2-bin_1%3a2.32-1_amd64.deb iputils-ping_3%3a20190709-3_amd64.deb

 


免責聲明!

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



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