Ubuntu出現“E: 無法定位軟件包問題”更新安裝yum源;無法安裝vim

Ubuntu出現“E: 無法定位軟件包問題”更新安裝yum源;無法安裝vim
在終端運行以下的命令:
sudo apt-get update
也無法更新軟件源
++++++++++++++++++++++++++++++
需要使用root用更改Ubuntu中的源
#進入root下
sudo -i
#修改添加
sudo gedit /etc/apt/sources.list
# 將文檔裏面所有的內容刪除(若有),然後替換爲清華鏡像提供的軟件源鏡像的地址。 
例如我用的 16.04 版, 替換爲:
# 默認註釋了源碼鏡像以提高 apt update 速度,如有需要可自行取消註釋
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse



然後點擊保存!
#再輸入
sudo apt update
執行獲取源完畢後如下圖:

再進行安裝yum源則沒問題:
# 安裝yum源
apt install vim
輸入大寫(繼續執行):Y

++++++++++++++++++
學習中借用到的鏈接推薦爲:https://zhuanlan.zhihu.com/p/27187622

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章