![Ubuntu 无人值守升级在 Ubuntu 14.04.4 上不起作用](https://linux22.com/image/683774/Ubuntu%20%E6%97%A0%E4%BA%BA%E5%80%BC%E5%AE%88%E5%8D%87%E7%BA%A7%E5%9C%A8%20Ubuntu%2014.04.4%20%E4%B8%8A%E4%B8%8D%E8%B5%B7%E4%BD%9C%E7%94%A8.png)
我已经在 Ubuntu 14.04 服务器中启用了无人值守升级,它似乎正在运行,但它并没有更新可以更新的软件包。
例如现在我得到
46 packages can be updated.
apt-get upgrade 确认前输出:
The following packages will be upgraded:
galera-3 libgd3 libjbig0 libmariadbclient18 libmysqlclient18 libpcre3
libssl1.0.0 libssl1.0.2 libzip4 mariadb-client-10.1 mariadb-client-core-10.1
mariadb-common mariadb-server-core-10.1 mysql-common newrelic-daemon
newrelic-php5 newrelic-php5-common newrelic-sysmond openssl php-common
php-igbinary php-imagick php-json php-memcache php-memcached php-msgpack
php-xdebug php5.6-bcmath php5.6-cli php5.6-common php5.6-curl php5.6-fpm
php5.6-gd php5.6-imap php5.6-json php5.6-mbstring php5.6-mcrypt php5.6-mysql
php5.6-opcache php5.6-readline php5.6-recode php5.6-soap php5.6-xml
php5.6-zip php7.0-common php7.0-json
46 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
/etc/apt/apt.conf.d/50unattended-upgrades 包含:
Unattended-Upgrade::Allowed-Origins {
"${distro_id}:${distro_codename}-security";
"${distro_id}:${distro_codename}-updates";
// "${distro_id}:${distro_codename}-proposed";
// "${distro_id}:${distro_codename}-backports";
};
今天的 unnattended-upgrades.log 结尾是
2016-05-29 17:05:37,434 DEBUG pkgs that look like they should be upgraded:
2016-05-29 17:05:37,448 DEBUG fetch.run() result: 0
2016-05-29 17:05:37,448 DEBUG blacklist: []
2016-05-29 17:05:37,449 INFO No packages found that can be upgraded unattended and no pending auto-removals
发生了什么?我如何才能弄清楚无人值守升级为何不起作用?
谢谢
答案1
可能的解决方案是您的Allowed-Origins
过滤器与包中的原始标签不匹配。
为了在我的系统上调试这个问题,我创建了一个脚本(参见要点:分布信息) 来转储当前的来源规则,如所使用的unattended-updates
,也用于在请求时转储包的来源。