- 具体错误
$ sudo debtap -u
==> Synchronizing pkgfile database...
:: Updating 2 repos...core is up to dateextra is up to date
==> Synchronizing debtap database...% Total % Received % Xferd Average Speed Time Time Time CurrentDload Upload Total Spent Left Speed0 260 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404gzip: /var/cache/debtap/debian-main-packages-files.gz: unexpected end of file% Total % Received % Xferd Average Speed Time Time Time CurrentDload Upload Total Spent Left Speed0 260 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404gzip: /var/cache/debtap/debian-non-free-packages-files.gz: unexpected end of file% Total % Received % Xferd Average Speed Time Time Time CurrentDload Upload Total Spent Left Speed0 260 0 0 0 0 0 0 --:--:-- 0:00:01 --:--:-- 0
curl: (22) The requested URL returned error: 404gzip: /var/cache/debtap/debian-contrib-packages-files.gz: unexpected end of file% Total % Received % Xferd Average Speed Time Time Time CurrentDload Upload Total Spent Left Speed0 278 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404gzip: /var/cache/debtap/ubuntu-packages-files.gz: unexpected end of file
Synchronization failed. Exiting...
- 解决步骤1
编辑/usr/bin/debtap:
ftp.debian.org/archive.ubuntu.com
改为
mirrors.ustc.edu.cn
- 解决步骤2
上面步骤解决了网站可能联接不上的问题。我在riscv64 Arch Linux上,更新还是报错。反复安装、更新都不对。一怒之下,分析了一下debtap,怀疑有问题。先在浏览器上输入了http://mirrors.ustc.edu.cn相关目录,确实有很多东西。于是怀疑是$_arch这个变量不对。于是进行了手工替换:
http://mirrors.ustc.edu.cn/debian/dists/sid/main/Contents-$_arch.gz
改成
http://mirrors.ustc.edu.cn/debian/dists/sid/main/Contents-riscv64.gz