我有麻烦aptitude update和apt-get update不下载某个列表文件(具体http://gb.archive.ubuntu.com精确/宇宙源头[5019 KB])。
我可以从这里通过浏览器下载它:http : //gb.archive.ubuntu.com/ubuntu/dists/precise/universe/source/Sources.bz2
计划是通过我的本地机器下载,将其 FTP 到服务器aptitude并apt-get查找它并Hit在本地保存文件而不是重新下载。
所以我正在寻找apt将源列表下载到的位置,包缓存当然是/var/cache/apt但包列表不在那里?
首先,让我知道自从我升级这个特定的服务器已经有一段时间了。
当我执行sudo apt-get update大多数端点时,似乎都可以正常到达。然而,有一些相当令人不安的失误:
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/main/source/Sources 404 Not Found [IP: 91.189.92.190 80]
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/universe/source/Sources 404 Not Found [IP: 91.189.92.190 80]
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/main/binary-amd64/Packages 404 Not Found [IP: 91.189.92.190 80]
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/universe/binary-amd64/Packages 404 Not Found [IP: 91.189.92.190 80]
E: Some index files failed to download. They have been ignored, or old ones used instead.
Run Code Online (Sandbox Code Playgroud)
如果我尝试继续前进,sudo apt-get upgrade我会收到大量如下所示的错误,并且没有任何更新:
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ natty-updates/main libc6 amd64 2.13-0ubuntu13.2
403 Forbidden
Run Code Online (Sandbox Code Playgroud)
我的服务器源列表指向错误的服务器还是什么?
我在几台 Ubuntu 12.04 服务器上安装了 Percona DB 5.6。在其中一些上,我已经能够使用以下命令成功升级到最新版本(5.6.17)
apt-get update
apt-get upgrade
Run Code Online (Sandbox Code Playgroud)
在其他几个上, apt-get update + Upgrade 告诉我没有什么可做的,尽管那里安装的版本只有 5.6.15。为什么找不到最新版本?
已更新的服务器的最新版本:“服务器版本:5.6.17-65.0-587.precise-log (Ubuntu)”
未更新的服务器版本:“服务器版本:5.6.15-63.0-log Percona Server (GPL),版本 63.0”
我已确认以下行位于所有服务器上的 /etc/apt/sources.list 中:
deb http://repo.percona.com/apt precise main
deb-src http://repo.percona.com/apt precise main
Run Code Online (Sandbox Code Playgroud)
(它必须在某个时候起作用,因为它们最初都是使用 apt-get 安装的)
编辑:根据estibordo的建议,我添加了输出
apt-cache policy percona-server-server-5.6
Run Code Online (Sandbox Code Playgroud)
(percona-server-common-5.6 和 percona-server-client-5.6 也与此相同)
从未升级的服务器:
percona-服务器-服务器-5.6:
安装:1:5.6.15-rel63.0-519.precise
候选:1:5.6.15-rel63.0-519.precise
版本表:
*** 1:5.6.15-rel63.0-519.精确0
100 /var/lib/dpkg/状态
5.6.17-65.0-587.精确0
500 个 http://repo.percona.com/apt/precision/main amd64 软件包
在我升级的服务器上,输出如下:
percona-服务器-服务器-5.6:
安装:5.6.17-65.0-587.precise
候选:5.6.17-65.0-587.precise
版本表:
*** 5.6.17-65.0-587.精确0
500 个 http://repo.percona.com/apt/precision/main amd64 软件包
100 /var/lib/dpkg/状态
为什么会有差异,或者更重要的是,如何修复卡在 5.6.15 上的问题?谢谢。
我正在安装一个新服务器,当它突然停止工作时,我一直在调整我的 vsftpd 设置。我注意到服务 vsftpd 只有在vsftpd.conf为空或被删除时才有效。所以我决定使用apt-get remove vsftpdand重新安装 vsftpd ,apt-get install vsftpd但是vsftpd.conf我之前删除的文件因为我想重新开始配置而一直丢失。
如何重新安装 vsftpd 以便找回我的 vsftpd.conf 文件?
我使用 Ubuntu 进行开发和依赖项需求之一
apt-get libgraphicsmagick1-dev
Run Code Online (Sandbox Code Playgroud)
现在我需要部署到运行 AMI 且仅支持 YUM 或 RPM 的 AWS EC2,上面的等效命令是什么?请注意,我无法更改服务器操作系统选择。谢谢。
我运行 Debian 6 服务器并使用它来托管十几个基于 LAMP 的网站。我将其配置为在有软件更新可用时通过电子邮件发送给我,今天早上我收到了 6 个与 mySql 相关的新可用更新的通知:
mysql-server, mysql-client, mysql-common
和其他一些依赖项。我试图运行
apt-get 更新 apt-get 升级
一切顺利,直到升级过程遇到mysql-client。我得到的错误如下:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages will be upgraded:
mysql-client-5.5
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 0 B/1,772 kB of archives.
After this operation, 7,049 kB of additional disk space will be used.
Do you …Run Code Online (Sandbox Code Playgroud) 在进行运行时apt upgrade,Tomcat 7 安装后脚本与 common A new version of configuration file /etc/default/tomcat7 is available.... 不幸的是,我没有足够快地处理它并且 SSH 连接被重置。我该如何从中恢复?我可以重新连接到安装后屏幕吗?杀死它安全吗?如果我杀死它,是否有我应该手动执行的脚本?
我看到了这个问题,这样做操作系统版本的升级,但无论哪种解决方案(screen -r)是不相关的或者说我没有正确使用它。
$ screen -r
There is no screen to be resumed.
Run Code Online (Sandbox Code Playgroud)
我可以看到正在运行的进程:
$ ps -a
PID TTY TIME CMD
416 pts/2 00:00:00 frontend
423 pts/2 00:00:00 tomcat7.postins
430 pts/2 00:00:00 ucf
475 pts/2 00:00:00 whiptail
634 pts/1 00:00:00 ps
Run Code Online (Sandbox Code Playgroud)
正如 Dmitry Zayats 所建议的,我查看了 Tomcat 7 安装后脚本。在我安装的 Ubuntu 14.04 中,它可以在这里找到:/var/lib/dpkg/info/tomcat7.postinst
打开它,我相信我看到了我最初失去连接的相关行:
ucf --debconf-ok --sum-file …
注意:我对 Ubuntu 很陌生(我是 CentOs 人)
我试图安装到 openssh-server 但我得到了:
root@5b4ca6d66450:/home# apt-get install openssh-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package openssh-server
Run Code Online (Sandbox Code Playgroud)
现在,当我检查我的 /etc/apt/sources.list 时,我得到:
root@5b4ca6d66450:/home# cat /etc/apt/sources.list
deb http://deb.debian.org/debian jessie main
deb http://deb.debian.org/debian jessie-updates main
deb http://security.debian.org jessie/updates main
Run Code Online (Sandbox Code Playgroud)
我接下来添加以下行 - 但我仍然得到相同的结果
deb http://deb.debian.org/debian jessie contrib
Run Code Online (Sandbox Code Playgroud)
有什么明显的我做错了吗?
我使用此命令检查了我的操作系统安装
uname -a
Run Code Online (Sandbox Code Playgroud)
并得到了这个结果
Linux uc3-dev 2.6.32.27-0.2-default #1 SMP 2010-12-29 15:03:02 +0100 x86_64 x86_64 x86_64 GNU/Linux
Run Code Online (Sandbox Code Playgroud)
我在一个新的服务器上,所以我认为 apt-get 没有安装。我安装 apt-get 的最佳方法是什么?顺便说一下,我拥有所有管理员权限。
这是 lsb_release -a 的输出
如果“lsb_release”不是拼写错误,您可以运行以下命令来查找包含二进制文件的包:
command-not-found lsb_release
-bash: lsb_release: command not found
Run Code Online (Sandbox Code Playgroud) 我使用了一些具有apt-get search jetty的 apt-get 版本,它会返回包含单词 jetty 的所有包的列表。但是当我输入 apt-get 时,我得到以下命令列表:
apt 0.8.10.3 for i386 compiled on Apr 15 2011 21:02:20
Usage: apt-get [options] command
apt-get [options] install|remove pkg1 [pkg2 ...]
apt-get [options] source pkg1 [pkg2 ...]
apt-get is a simple command line interface for downloading and
installing packages. The most frequently used commands are update
and install.
Commands:
update - Retrieve new lists of packages
upgrade - Perform an upgrade
install - Install new packages (pkg is libc6 not …Run Code Online (Sandbox Code Playgroud)