更新 apt-get 在 debian 中使用的 url 列表

更新 apt-get 在 debian 中使用的 url 列表

當我在 VPS 上執行“apt-get update”時,我收到很多錯誤訊息:

Err http://ftp.debian.org lenny/volatile/main Packages
  404 Not Found [IP: 130.89.149.226 80]
Err http://ftp.debian.org lenny/volatile/contrib Packages
  404 Not Found [IP: 130.89.149.226 80]
Err http://ftp.debian.org lenny/volatile/non-free Packages
  404 Not Found [IP: 130.89.149.226 80]
Err http://ftp.debian.org lenny/updates/main Packages
  404 Not Found [IP: 130.89.149.226 80]
Err http://ftp.debian.org lenny/updates/contrib Packages
  404 Not Found [IP: 130.89.149.226 80]
Err http://ftp.debian.org lenny/updates/non-free Packages
  404 Not Found [IP: 130.89.149.226 80]
W: Failed to fetch http://ftp.debian.org/debian-volatile/dists/lenny/volatile/main/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

W: Failed to fetch http://ftp.debian.org/debian-volatile/dists/lenny/volatile/contrib/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

W: Failed to fetch http://ftp.debian.org/debian-volatile/dists/lenny/volatile/non-free/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

W: Failed to fetch http://ftp.debian.org/debian-security/dists/lenny/updates/main/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

W: Failed to fetch http://ftp.debian.org/debian-security/dists/lenny/updates/contrib/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

W: Failed to fetch http://ftp.debian.org/debian-security/dists/lenny/updates/non-free/binary-i386/Packages  404 Not Found [IP: 130.89.149.226 80]

E: Some index files failed to download, they have been ignored, or old ones used instead.

任何人都可以幫我更新此清單以使所有網址都有效。

很抱歉問題的標題很奇怪,但我不知道正確的術語。

答案1

您要查找的文件是/etc/apt/sources.list.

您的主機可能正在使用較舊的 OpenVZ 範本之一,該範本的儲存庫 URL 不正確。

試試我的清單:

deb http://security.debian.org/lenny/updates 主要貢獻非免費
deb http://揮發性.debian.org/debian-揮發性 lenny/揮發性主要貢獻非自由
deb http://ftp.us.debian.org/debian/ lenny main
deb-src http://ftp.us.debian.org/debian/ lenny main
deb-src http://security.debian.org/lenny/updates main
deb-src http://揮發性.debian.org/debian-揮發性 lenny/揮發性主

答案2

似乎不http://ftp.devian.org/debian-security存在。當我觀看時http://ftp.debian.org/,我看到的只是debian/

也許嘗試一下security.debian.org

答案3

儘管人們可能會認為它的名字是這樣的,但ftp.debian.org它並不比其他 Debian 鏡像更完整。例如,它沒有debian-volatile. Debian 網站有一個Debian 易失性鏡像列表。安全性更新應直接來自security.debian.org.

您需要編輯/etc/apt/sources.list.將 volatile 和 security 行變更為類似的內容

deb http://ftp.nl.debian.org/debian-volatile lenny/volatile main contrib non-free
deb http://security.debian.org/ lenny/updates main contrib non-free

當您這樣做時,您也可以更改要使用的核心線ftp.nl.debian.org

相關內容