AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / unix / 问题 / 757781
Accepted
Digger
Digger
Asked: 2023-09-30 04:14:42 +0800 CST2023-09-30 04:14:42 +0800 CST 2023-09-30 04:14:42 +0800 CST

Aptitude 在哪里记录警告?

  • 772

资质版本0.8.7

Debian 9(延伸)

在最近的软件包升级过程中,Aptitude GUI 显示以下警告,框起来并以亮红色显示:

W: APT had planned for dpkg to do more than it reported back...

所述显示的警告还包含有关计划操作数量与执行操作数量的信息,以及有关哪个特定包受到影响的信息,但在记录这一附加信息之前我愚蠢地承认了尖叫声(我想我可以在某处引用日志)。

好吧,我找不到正确的日志文件。仅供参考,/var/log/aptitude显示最近的活动,但主题警告消息不存在...

以下三个链接可能会提供一些见解,但我仍然找不到所需的日志:

https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1647638

https://askubuntu.com/questions/1378118/apt-had-planned-for-dpkg-to-do-more-than-it-reported-back

https://groups.google.com/g/linux.debian.bugs.dist/c/n74RYhzpzNM

在哪里可以找到所需的日志文件?

debian
  • 2 2 个回答
  • 97 Views

2 个回答

  • Voted
  1. Best Answer
    tink
    2023-09-30T05:31:54+08:002023-09-30T05:31:54+08:00

    没有任何 - 默认情况下 aptitude 不会将错误或警告写入磁盘。所有的内容/var/log/aptitude都是安装。

    如果您想要额外的日志记录,您需要说明aptitude这一点。

    来自man aptitude:

       --log-file=<file>
           If <file> is a nonempty string, log messages will be written to it, except that if
           <file> is “-”, the messages will be written to standard output instead. If this option
           appears multiple times, the last occurrence is the one that will take effect.
    
           This does not affect the log of installations that aptitude has performed
           (/var/log/aptitude); the log messages written using this configuration include
           internal program events, errors, and debugging messages. See the command-line option
           --log-level to get more control over what gets logged.
    
           This corresponds to the configuration option Aptitude::Logging::File.
    
       --log-level=<level>, --log-level=<category>:<level>
           --log-level=<level> causes aptitude to only log messages whose level is <level> or
           higher. For instance, setting the log level to error will cause only messages at the
           log levels error and fatal to be displayed; all others will be hidden. Valid log
           levels (in descending order) are off, fatal, error, warn, info, debug, and trace. The
           default log level is warn.
    
           --log-level=<category>:<level> causes messages in <category> to only be logged if
           their level is <level> or higher.
    
           --log-level may appear multiple times on the command line; the most specific setting
           is the one that takes effect, so if you pass --log-level=aptitude.resolver:fatal and
           --log-level=aptitude.resolver.hints.match:trace, then messages in
           aptitude.resolver.hints.parse will only be printed if their level is fatal, but all
           messages in aptitude.resolver.hints.match will be printed. If you set the level of the
           same category two or more times, the last setting is the one that will take effect.
    
           This does not affect the log of installations that aptitude has performed
           (/var/log/aptitude); the log messages written using this configuration include
           internal program events, errors, and debugging messages. See the command-line option
           --log-file to change where log messages go.
    
           This corresponds to the configuration group Aptitude::Logging::Levels.
    

    [编辑] 好吧……试图引导你去喝水并让你喝水花了太长时间:

    /etc/apt/apt.conf.d/50aptitude只需创建包含以下内容的文件- 这也将使您不必使用命令行开关:

    Aptitude::Logging::File "/var/log/aptitude.out";
    Aptitude::Logging::Levels "*:info";
    
    • 2
  2. Digger
    2023-10-03T05:47:54+08:002023-10-03T05:47:54+08:00

    这对我有用:

    每当我调用Aptitude时,我都会使用

    aptitude --log-file=/tmp/AptitudeLog.log --log-level=info

    然后,因为如果我需要任何关联的日志信息,我永远不会记得在哪里查找,所以我在/var/log和中留下了上述临时日志文件的链接/var/log/apt

    问题结束!

    • 1

相关问题

  • GRUB 配置以识别同一 Linux 发行版的不同桌面环境(安装)

  • astyle 不会更改源文件格式

  • 接收有关全新 Debian 的电子邮件

  • Debian Stretch:libgs_plugin_systemd-updates.so 中的 gnome-software 段错误

  • 如何在拼音输入法中输入ü?

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    模块 i915 可能缺少固件 /lib/firmware/i915/*

    • 3 个回答
  • Marko Smith

    无法获取 jessie backports 存储库

    • 4 个回答
  • Marko Smith

    如何将 GPG 私钥和公钥导出到文件

    • 4 个回答
  • Marko Smith

    我们如何运行存储在变量中的命令?

    • 5 个回答
  • Marko Smith

    如何配置 systemd-resolved 和 systemd-networkd 以使用本地 DNS 服务器来解析本地域和远程 DNS 服务器来解析远程域?

    • 3 个回答
  • Marko Smith

    dist-upgrade 后 Kali Linux 中的 apt-get update 错误 [重复]

    • 2 个回答
  • Marko Smith

    如何从 systemctl 服务日志中查看最新的 x 行

    • 5 个回答
  • Marko Smith

    Nano - 跳转到文件末尾

    • 8 个回答
  • Marko Smith

    grub 错误:你需要先加载内核

    • 4 个回答
  • Marko Smith

    如何下载软件包而不是使用 apt-get 命令安装它?

    • 7 个回答
  • Martin Hope
    user12345 无法获取 jessie backports 存储库 2019-03-27 04:39:28 +0800 CST
  • Martin Hope
    Carl 为什么大多数 systemd 示例都包含 WantedBy=multi-user.target? 2019-03-15 11:49:25 +0800 CST
  • Martin Hope
    rocky 如何将 GPG 私钥和公钥导出到文件 2018-11-16 05:36:15 +0800 CST
  • Martin Hope
    Evan Carroll systemctl 状态显示:“状态:降级” 2018-06-03 18:48:17 +0800 CST
  • Martin Hope
    Tim 我们如何运行存储在变量中的命令? 2018-05-21 04:46:29 +0800 CST
  • Martin Hope
    Ankur S 为什么 /dev/null 是一个文件?为什么它的功能不作为一个简单的程序来实现? 2018-04-17 07:28:04 +0800 CST
  • Martin Hope
    user3191334 如何从 systemctl 服务日志中查看最新的 x 行 2018-02-07 00:14:16 +0800 CST
  • Martin Hope
    Marko Pacak Nano - 跳转到文件末尾 2018-02-01 01:53:03 +0800 CST
  • Martin Hope
    Kidburla 为什么真假这么大? 2018-01-26 12:14:47 +0800 CST
  • Martin Hope
    Christos Baziotis 在一个巨大的(70GB)、一行、文本文件中替换字符串 2017-12-30 06:58:33 +0800 CST

热门标签

linux bash debian shell-script text-processing ubuntu centos shell awk ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve