Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logs #136

Open
junxnone opened this issue Oct 23, 2024 · 0 comments
Open

Logs #136

junxnone opened this issue Oct 23, 2024 · 0 comments

Comments

@junxnone
Copy link
Owner

junxnone commented Oct 23, 2024

Linux Logs

  • Logs Files 分别记录了哪些 log,分别由哪些应用记录,碰到什么样的问题应该对应的去找哪个 log
  • 例如: 系统自动重启了,应该怎么 debug

一些常见的 log 文件

文件或目录 说明
/var/log/apt/(目录) 包含与apt软件包管理相关的日志文件。如apt-history.log记录软件包安装、升级和移除操作历史;apt-term.log包含apt操作的终端输出信息。
/var/log/auth.log 记录系统认证相关事件,包括用户登录、认证成功和失败尝试等。
/var/log/boot.log 包含系统启动过程的日志信息,记录各个服务和进程启动情况。
/var/log/cron.log 与定时任务相关,记录定时任务执行情况。
/var/log/dmesg 存储内核环形缓冲区信息,记录系统启动时内核检测硬件设备、加载驱动等信息。
/var/log/faillog 记录用户登录失败的详细信息。
/var/log/kern.log 记录内核相关消息,包括内核警告、错误及其他重要事件。
/var/log/mail.log(或/var/log/maillog) 若系统运行邮件服务器,记录邮件传输相关信息。
/var/log/messages 通用系统消息日志文件,记录各种系统事件信息。
/var/log/secure 与安全相关,记录用户认证、访问控制等方面事件。
/var/log/syslog 记录系统各种消息,包括系统服务消息、内核消息等。
/var/log/ufw.log 若启用UFW防火墙,记录防火墙相关事件。
/var/log/wtmp 二进制文件,记录系统登录和注销历史信息。
/var/log/lastlog 记录每个用户最近一次登录的时间戳等信息。
/var/log/dpkg.log 记录使用dpkg命令安装、升级和删除软件包的详细信息。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant