【发布时间】:2011-05-24 02:04:35
【问题描述】:
【问题讨论】:
-
这个可以移到超级用户,对吧?
-
对于 Debian 开始 packages.debian.org/stable 向下钻取。非常靠近(向下)包的页面是您可以下载的架构列表。点击下载。
【问题讨论】:
试试
apt-get -d install <packages>
它记录在man apt-get。
只是为了澄清;下载的包位于apt包中 缓存在
/var/cache/apt/archives
【讨论】:
apt-get -d 的系统上已经是最新的,这是否有效?
至少有这些apt-get 扩展包可以提供帮助:
apt-offline - offline apt package manager
apt-zip - Update a non-networked computer using apt and removable media
这特别适用于想要下载您可以访问网络但想安装在您没有网络访问的另一台机器上的情况。
否则,apt-get 的 --download-only 选项是您的朋友:
-d, --download-only
Download only; package files are only retrieved, not unpacked or installed.
Configuration Item: APT::Get::Download-Only.
【讨论】:
aptitude download <package_name>。避免了apt-get在安装包时遇到的问题
apt download <package_name>(类似于 biocyberman 的回答,但我认为 apt 现在比 aptitude 更常见)。
不要忘记选项“-o”,它可以让您在任何地方下载,尽管您必须先创建“存档”、“锁定”和“部分”(该命令会打印需要的内容)。
apt-get install -d -o=dir::cache=/tmp whateveryouwant
【讨论】:
apt-get -d -o=dir::cache=/tmp/pkg rabbitmq-server E: Invalid operation rabbitmq-server应该是:$ apt-get download -o=dir::cache=/tmp/pkg rabbitmq-server Get:1 Downloading rabbitmq-server 2.7.1-0ubuntu4 [2,745 kB] 13% [1 rabbitmq-server 361 kB/2,745 kB 13%]