我有一段网络,无法访问互联网。但是它充满了 Ubuntu 16.04 的 mashines,我必须从这个网络段下载一些标准包,但我不能,因为我没有机会在这个区域上网。所以我使用了 apt-mirror,下载了整个 repos,这在任何 ubuntu 16.04的初始source.list文件中都有说明。它大约500GB。但是,当我尝试安装比“mc”或一些通用软件包更多的东西时,我陷入了依赖地狱。例如,尝试安装“sssd”我收到:
root@ubuntu:~# apt-get install sssd
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
sssd : Depends: python-sss (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-ad (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-common (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-ipa (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-krb5 (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-ldap (= 1.13.4-1ubuntu1.15) but it is not going to be installed
Depends: sssd-proxy (= 1.13.4-1ubuntu1.15) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
但是它是如何工作的,当我从同一个 repo 安装包时,但不是从我的本地电脑上下载,而是从互联网上下载的。这意味着,apt-mirror 不会下载整个 repo 并且遗漏了一些东西。所以,我有两个问题:
- 我如何下载整个 repo,它将模拟 repo 在互联网上的工作?
- 如果我不能,我如何将包添加到我自己的本地仓库并在某些时候修复依赖关系?
谢谢!
我发现这本手册对我帮助很大
https://www.debian.org/doc/manuals/repository-howto/repository-howto.en.html