Articles of apt

sudo apt-get update不会更新Debian Wheezy中的存储库

我正在尝试使用下面的命令来更新存储库,但它是失败的: sudo apt-get update 以上是上述命令的输出: Hit http://dl.google.com stable Release.gpg Hit http://deb.opera.com stable Release.gpg Hit http://liveusb.info all Release.gpg Hit http://dl.google.com stable Release Hit http://deb.opera.com stable Release Hit http://liveusb.info all Release Hit http://dl.google.com stable/main i386 Packages Hit http://repo.mysql.com wheezy Release.gpg Hit http://linux.dropbox.com wheezy Release.gpg Hit http://deb.opera.com stable/non-free i386 Packages Hit http://liveusb.info all/main i386 Packages Hit http://security.debian.org wheezy/updates […]

EC2 Ubuntu 14.04实例:运行`apt-get update`导致“Hash Sum mismatch”

每当我用Ubuntu 14.04(使用ami-a182b391 ,从这里find)创build一个新的AWS EC2实例,然后立即运行sudo apt-get -y update ,它会给我一个错误。 这里的操作系统信息: $ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 14.04.2 LTS Release: 14.04 Codename: trusty 以下是失败的apt命令: $ sudo apt-get -y update Ign http://us-west-2.ec2.archive.ubuntu.com trusty InRelease Ign http://us-west-2.ec2.archive.ubuntu.com trusty-updates InRelease Hit http://us-west-2.ec2.archive.ubuntu.com trusty Release.gpg Hit http://us-west-2.ec2.archive.ubuntu.com trusty-updates Release.gpg Hit http://us-west-2.ec2.archive.ubuntu.com trusty Release Hit […]

Ubuntu14.04 – 无法apt-get更新

sudo apt-get update 返回一些错误: W:无法获取http:// archive.ubuntu.com/ubuntu/dists/trusty/Release无法在发布文件中find期望条目'restricted / source / Sources'(错误的sources.list条目或格式错误的文件) W:无法获取http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/binary-amd64/Packages哈希值总和不匹配 W:无法抓取http:// archive.ubuntu.com/ubuntu/dists/trusty-security/universe/binary-amd64/Packages哈希值总和不匹配 W:无法获取http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/binary-i386/Packages哈希值总和不匹配 W:无法获取http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/i18n/Translation-en哈希总和不匹配 E:一些索引文件无法下载。 他们被忽略了,或者旧的被使用。 它似乎发生在Ubuntu的官方回购。 任何想法为什么? 有关信息,我的sources.list是以下内容: #———————————————————-# # OFFICIAL UBUNTU REPO # #———————————————————-# ###### Ubuntu Main Repos deb http://archive.ubuntu.com/ubuntu trusty main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty main restricted universe multiverse ###### Ubuntu Update Repos deb http://archive.ubuntu.com/ubuntu trusty-security […]

/etc/cron.daily/apt:分割错误

我有一个系统,我与特立独行和“自动应用安全更新”设置。 现在正在每天发送电子邮件: Subject: Anacron job 'cron.daily' on gwen /etc/cron.daily/apt: Segmentation fault 如果我手动“apt-get update; apt-get dist-upgrade”,它运行得很好。 另外,如果我login并运行/etc/cron.daily/apt它也不会给段错误。 我做了一些search谷歌和大部分的结果似乎是从2008年和“pam_mount”,这是不是在这个系统上。

Debian aptitude:确定一个软件包来自哪个版本库?

在能力方面,我怎么知道包裹是从哪里来的? 我已经build立了我的apt sources.list和preferences文件钉住,但我只是想确保我不是不知不觉升级到来自backports或不稳定的软件包。

有没有办法使用python apt模块添加ppa?

我需要使用python脚本将ppa添加到远程服务器。 相当于我想要做的是: $ add-apt-repository ppa:user/ppa-name 我假设它看起来像这样: import apt cache = apt.Cache() # ?? add the ppa here ?? cache.update() cache.open(None) cache['package_from_ppa'].mark_install() cache.upgrade() cache.commit() 但是我一直无法find与添加存储库相关的apt模块源代码。

尽pipe在/etc/apt/sources.list中没有sid,Debian仍然从sid抓取软件包

我有一台安装了Debian Lenny的机器。 不知何故,当我做apt-get更新,我收到这个输出: sudo apt-get update Get:1 http://ftp.de.debian.org lenny Release.gpg [1034B] Ign http://ftp.de.debian.org lenny/main Translation-en_US Ign http://ftp.de.debian.org lenny/contrib Translation-en_US Get:2 http://mirror.yandex.ru sid Release.gpg [836B] Ign http://ftp.de.debian.org lenny/non-free Translation-en_US Hit http://ftp.de.debian.org lenny/volatile Release.gpg Ign http://ftp.de.debian.org lenny/volatile/main Translation-en_US Ign http://ftp.de.debian.org lenny/volatile/contrib Translation-en_US Ign http://ftp.de.debian.org lenny/volatile/non-free Translation-en_US Hit http://ftp.de.debian.org lenny/updates Release.gpg Ign http://ftp.de.debian.org lenny/updates/main Translation-en_US Ign http://ftp.de.debian.org lenny/updates/contrib […]

为什么不安装mysql-server包创build一个root帐户?

这不是为什么? 那很重要。 这是我自己怎么做的? 我正在使用Ubuntu 10.04 LTS服务器 。 我只是想安装一个MySQL服务器 ,但由于某种原因,它不会让我。 当我运行apt-get install mysql-server一切正常。 在安装结束时popup一个模式窗口,要求我inputroot密码。 这里唯一的奇怪之处在于特殊字符的编码(比如模态窗口的边界)有点混乱。 但我认为这不是主要问题。 在安装结束时,MySQL自动启动,一切正常,直到我尝试login。 mysql -u root -p提示我Enter password: 。 我input在安装过程中使用的密码,并得到这个错误: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)当我尝试与空密码我得到相同的错误,除了(using password: YES)部分(using password: NO) 。 我做了一些Google研究,已经尝试了所有的mysqld_safe –skip-grant-tables & thingy。 我也检查了mysql用户表。 唯一的入口是debian-sys-maint用户。 mysql> SELECT * FROM user; +———–+——————+——————————————-+————-+————-+————-+————-+————-+———–+————-+—————+————–+———–+————+—————–+————+————+————–+————+———————–+——————+————–+—————–+——————+——————+—————-+———————+——————–+——————+————+————–+———-+————+————-+————–+—————+————-+—————–+———————-+ | Host | User […]

在哪里可以finddebian用于运行apt-get update的sources.list的URL?

任何人都可以告诉我在哪里可以findURL放在/etc/apt/sources.list debian,以便我可以运行apt-get update ? 通过searchGoogle我找不到确切的答案。 当我目前尝试运行apt-get update我得到: W: Failed to fetch ftp://ftp.debian.org/debian/dists/lenny/contrib/binary-i386/Packages Unable to fetch file, server said 'Failed to open file. ' [IP: 130.89.148.12 21] W: Failed to fetch ftp://ftp.debian.org/debian/dists/lenny/non-free/binary-i386/Packages Unable to fetch file, server said 'Failed to open file. ' [IP: 130.89.148.12 21] 我不知道如何解决这个问题。 以下是我目前的sources.list样子: deb ftp://ftp.debian.org/debian lenny main contrib non-free deb-src ftp://ftp.debian.org/debian […]

在cron任务中运行“apt-get -y upgrade”,但不升级系统

这个服务器运行Debian 7,我正面临一个很大的谜团。 这是我的cron任务: $ sudo crontab -e 42 15 * * * apt-get -y update >> /var/log/my-apt-update.txt 52 15 * * * apt-get -y upgrade >> /var/log/my-apt-upgrade.txt 我添加了">> /var/log/my-apt-upgrade.txt"部分,因为我试图理解为什么我的系统永远不会升级。 cron任务运行。 每天我在/ var / log / syslog中都有这些行: Nov 14 15:42:01 myhostname /USR/SBIN/CRON[3374]: (root) CMD (apt-get -y update >> /var/log/my-apt-update.txt) Nov 14 15:52:01 myhostname /USR/SBIN/CRON[3394]: (root) CMD […]