软件中心需要一段时间才能加载


10

我有一台快速的计算机(出色的处理器,良好的SSD),但是Software Center加载需要30秒。这不是问题,我认为可能有问题。突触需要一秒钟来加载。

我跑去strace software-center看它是否在磁盘上跳动(它是SSD,我听不到),它正在声明并试图打开大量文件。摘录:

open("/usr/local/lib/python2.6/dist-packages/FlexGet-1.0r1465-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/FlexGet-1.0r1465-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/FlexGet-1.0r1465-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/progressbar-2.3_dev-py2.6.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/progressbar-2.3_dev-py2.6.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/progressbar-2.3_dev-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/progressbar-2.3_dev-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/progressbar-2.3_dev-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/pynzb-0.1.0-py2.6.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/pynzb-0.1.0-py2.6.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/pynzb-0.1.0-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/pynzb-0.1.0-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/pynzb-0.1.0-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/PyRSS2Gen-1.0.0-py2.6.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyRSS2Gen-1.0.0-py2.6.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyRSS2Gen-1.0.0-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyRSS2Gen-1.0.0-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyRSS2Gen-1.0.0-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/html5lib-0.90-py2.6.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/html5lib-0.90-py2.6.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/html5lib-0.90-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/html5lib-0.90-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/html5lib-0.90-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/PyYAML-3.09-py2.6-linux-x86_64.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyYAML-3.09-py2.6-linux-x86_64.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyYAML-3.09-py2.6-linux-x86_64.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyYAML-3.09-py2.6-linux-x86_64.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/PyYAML-3.09-py2.6-linux-x86_64.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/python2.6/dist-packages/transmissionrpc-0.6-py2.6.egg/StringIO", 0x7fff19d3af30) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/transmissionrpc-0.6-py2.6.egg/StringIO.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/transmissionrpc-0.6-py2.6.egg/StringIOmodule.so", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/transmissionrpc-0.6-py2.6.egg/StringIO.py", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/python2.6/dist-packages/transmissionrpc-0.6-py2.6.egg/StringIO.pyc", O_RDONLY) = -1 ENOENT (No such file or directory)

这可能是一条红鲱鱼。稍后在此暂停:

poll([{fd=3, events=POLLIN}], 1, 25000) = 1 ([{fd=3, revents=POLLIN}])
recvmsg(3, {msg_name(0)=NULL, msg_iov(1)=[{"l\2\1\1\v\0\0\0\3\0\0\0=\0\0\0\6\1s\0\7\0\0\0:1.3497\0"..., 2048}], msg_controllen=0, msg_flags=MSG_CMSG_CLOEXEC}, MSG_CMSG_CLOEXEC) = 91
recvmsg(3, 0x7fff8c57cc00, MSG_CMSG_CLOEXEC) = -1 EAGAIN (Resource temporarily unavailable)
sendmsg(3, {msg_name(0)=NULL, msg_iov(2)=[{"l\1\0\1\0\0\0\0\3\0\0\0{\0\0\0\1\1o\0\32\0\0\0/com/ubu"..., 144}, {"", 0}], msg_controllen=0, msg_flags=0}, MSG_NOSIGNAL) = 144
poll([{fd=3, events=POLLIN}], 1, 25000

然后再做一次...这两个暂停占了大部分加载时间。

然后,它真的会掉出数千条轮询/读取/暂时不可用的行。

那么到底是怎么回事?为什么Software Center扫描寻找什么可能的python包StringIO?虫子?

那么,为什么它停滞在看起来像是对something.ubuntu.com的网络请求(看不到完整的消息)?为什么仍然与ubuntu.com对话?


+1,这是对我上安装了Ubuntu的所有计算机一样的,所以我们必须等待修复
Praweł

@Oli这是什么版本的Ubuntu?我已经使用Lucid一段时间了,从未遇到过。
Mussnoon 2010年

我可以确认:这太慢了!我使用突触事实。
安德里亚·格兰迪

@Mussnoon:小牛。自从特立独行以来,这只是这么慢。我认为这可能与新增的“购买”或新版本的单点登录有关……无论哪种方式,让它停滞都是很糟糕的。
奥利(Oli)

3
这可能应该报告为错误。
Jorge Castro

Answers:


5

它似乎正在获取可用软件包的最新视图(如显示的apt-get update那样),这可能需要一段时间,具体取决于缓存的过期时间,软件存储库响应的速度以及您的速度。网络连接。

如评论中所述,刷新时缺乏交互性似乎是一个错误。


如果Aptitude,Synaptic甚至只是一次apt-get update相同的操作几乎在同一时间发生,我都会接受这作为答案。包括我输入密码在内,都会 time bash -c "sudo apt-get update"返回0m2.446s。热运行(紧接着没有输入密码)花费了0m0.572s。SC始终需要30秒以上的时间,因此,如果这是造成延迟的原因,则该错误不仅限于交互问题。
奥利(Oli)

嗯,很奇怪。第一次运行大约需要30秒钟,然后只花了几分钟。“ 30秒”对我来说始终是一个危险信号,表明DNS超时。无论如何,打开一个错误是最有意义的。
Kees Cook

您是否知道有什么我可以包装的东西可以检查它的网络流量?
奥利(Oli)

我以为我很夸张,但事实证明,我比给自己的信誉更耐心。刚用跑了软件中心time。1分55.410秒。哎哟。
奥利(Oli)

通常,我只是启动一个VM并尝试在运行tcpdump或时在那里复制它wireshark。但是,有一种方法可以做到这一点。我问过:askubuntu.com/q/11709/721
Kees Cook 2010年

0

我遇到同样的问题。当我第一次打开software-center时,它会快速打开。然后我关闭了它,但是我发现软件中心的进程没有被杀死。第二次打开它会花费很长时间。方法是关闭软件中心后手动终止软件中心进程。

我在thinkpad w500中使用ubuntu11.04 amd64 arch。

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.