大网数据广告活动
服务器运维问答

Is there a way to make apt-get upgrade not show changelogs?

· 52CE 我爱测

I want to be able to script apt-get upgrade to run seamlessly without prompts, but in my experiments, I can't get it to stop showing prompts, even with -y or --force yes . Lately, when setting up RPis from scratch, this is an exa…

问题原文

原帖链接 · mredig · CC BY-SA 3.0

I want to be able to script apt-get upgrade to run seamlessly without prompts, but in my experiments, I can't get it to stop showing prompts, even with -y or --force yes. Lately, when setting up RPis from scratch, this is an example offender that I simply have to hit q to continue with the upgrade:

ca-certificates (20141019+deb8u2) stable; urgency=medium

  Update Mozilla certificate authority bundle to version 2.9.
    The following certificate authorities were added (+):
    + "Certplus Root CA G1"
    + "Certplus Root CA G2"
    + "Certum Trusted Network CA 2"
    + "Hellenic Academic and Research Institutions ECC RootCA 2015"
    + "Hellenic Academic and Research Institutions RootCA 2015"
    + "ISRG Root X1"
    + "OpenTrust Root CA G1"
    + "OpenTrust Root CA G2"
    + "OpenTrust Root CA G3"
    + "SZAFIR ROOT CA2"
    The following certificate authorities were removed (-):
    - "CA Disig"
    - "NetLock Business (Class B) Root"
    - "NetLock Express (Class C) Root"
    - "NetLock Notary (Class A) Root"
    - "NetLock Qualified (Class QA) Root"
    - "Sonera Class 1 Root CA"
    - "Staat der Nederlanden Root CA"
    - "Verisign Class 1 Public Primary Certification Authority - G2"
    - "Verisign Class 3 Public Primary Certification Authority"
    - "Verisign Class 3 Public Primary Certification Authority - G2"

 -- Michael Shuler <[email omitted]>  Fri, 18 Nov 2016 09:09:47 -0600

Honestly, this is annoying even when I'm manually running the program as it can take several minutes and I will walk off, expecting to come back to a completed task and only find it to be paused part way through.

I saw something about making it quieter with -qq or something, but I'm a bit afraid it might overwrite a conf file that differs from defaults (while annoying, I find that to be acceptable).

So, honestly, I don't even know how to ask the right question - I just want this prompt gone.

已采纳解答

原帖链接 · jordanm · CC BY-SA 3.0

The output you are seeing comes from the apt-listchanges package, which is not default. There are multiple ways you can prevent the changes from pausing the update process:

  1. Set APT_LISTCHANGES_FRONTEND=cat in the environment
  2. Edit /etc/apt/listchanges.conf and set frontend=cat under the apt section
  3. Uninstall the apt-listchanges package

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2017-02-28)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。