IT袋

当前位置:主页 > 经验教程 > 系统教程 >

Linux

Linux 60秒快速性能分析操作手册(3)

时间:2024-01-23 15:00:25 来源:IT袋 作者:马勇
导读:Linux,一个较高的 15分钟负载 与一个 较低的1分钟负载 同时出现,可能意味着已经错过了问题发生的现场。 ┌──[root@vms100.liruilongs.github.io]-[~]└─$uptime 11:33

Linux

一个较高的 15分钟负载与一个较低的1分钟负载同时出现,可能意味着已经错过了问题发生的现场。

┌──[root@vms100.liruilongs.github.io]-[~]
└─$uptime
 11:33:45 up 35 min,  1 user,  load average: 1.39, 6.06, 11.64
┌──[root@vms100.liruilongs.github.io]-[~]
└─$ 

dmesg | tail或者cat /var/log/messages

或者 journalctl -k | tail 也可以结合 cat /var/log/messages 来排查

┌──[liruilong@liruilongs.github.io]-[~]
└─$dmesg | tail
[   12.216869] vmwgfx 0000:00:0f.0: [drm] Available shader model: SM_5.
[   12.225954] [drm] Initialized vmwgfx 2.20.0 20211206 for 0000:00:0f.0 on minor 0
[   12.233005] Bluetooth: hci0: unexpected cc 0x0c12 length: 2 < 3
[   12.233011] Bluetooth: hci0: Opcode 0x c12 failed: -38
[   12.238757] fbcon: vmwgfxdrmfb (fb0) is primary device
[   12.248762] Console: switching to colour frame buffer device 160x50
[   12.269448] vmwgfx 0000:00:0f.0: [drm] fb0: vmwgfxdrmfb frame buffer device
[   14.350586] block dm-0: the capability attribute has been deprecated.
[   14.446480] block nvme0n1: No UUID available providing old NGUID
[   14.498286] block nvme0n1: No UUID available providing old NGUID

这个命令显示过去 10 条系统日志,如果有的话。注意在这里寻找可能导致性能问题的错误。 添加 T和t 可以展示对应的时间

┌──[root@vms100.liruilongs.github.io]-[~]
└─$dmesg -T| tail
[日 1月 14 10:58:57 2024] vmxnet3 0000:1b:00.0 ens256: NIC Link is Up 10000 Mbps
[日 1月 14 10:59:38 2024] device ovs-system entered promiscuous mode
[日 1月 14 10:59:39 2024] Timeout policy base is empty
[日 1月 14 10:59:39 2024] Failed to associated timeout policy `ovs_test_tp'
[日 1月 14 10:59:40 2024] device br-tun entered promiscuous mode
[日 1月 14 10:59:40 2024] device br-int entered promiscuous mode
[日 1月 14 10:59:40 2024] device ens224 entered promiscuous mode
[日 1月 14 10:59:40 2024] device br-ex entered promiscuous mode
[日 1月 14 11:03:14 2024] capability: warning: `privsep-helper' uses deprecated v2 capabilities in a way that may be insecure
[日 1月 14 11:04:34 2024] hrtimer: interrupt took 11973872 ns
┌──[root@vms100.liruilongs.github.io]-[~]
└─$

在日常维护中,往往结合 grep 快速定位问题

┌──[root@liruilongs.github.io]-[~]
└─$ dmesg -T | grep -i error
[五 11月 10 10:32:57 2023] BERT: Boot Error Record Table support is disabled. Enable it by using bert_enable as kernel parameter.
┌──[root@liruilongs.github.io]-[~]
└─$ dmesg -T | grep -i warn
[五 11月 10 10:32:54 2023] Warning: Intel Processor - this hardware has not undergone upstream testing. Please consult http://wiki.centos.org/FAQ for more information
┌──[root@liruilongs.github.io]-[~]
└─$

相关阅读

  • win11密码设置教程 win 11系统怎么设密码

    win11密码设置教程 win 11系统怎么设密码

    正文核心介绍:win11密码设置教程的相关话题,关于win11密码设置教程 win 11系统怎么设密码,接下来就是全面介绍。 更新了新的win11系统之后许多求稳的小伙伴第一时间就会给电脑设置一个密码

  • windows11从哪里下载 win11纯净版下载位置及教程

    windows11从哪里下载 win11纯净版下载位置及教程

    跟大家说一说win11纯净版下载位置及教程方面的知识,关于windows11从哪里下载 win11纯净版下载位置及教程,接下来IT袋小编就来介绍。 纯净版的系统是不少的IT袋网友都喜欢使用的,因为它没有

  • win10 卓越性能设置 win101909怎么开启卓越性能模式

    win10 卓越性能设置 win101909怎么开启卓越性能模式

    为大家分享win101909怎么开启卓越性能模式方面的讲解,关于win10 卓越性能设置 win101909怎么开启卓越性能模式,相关内容具体如下: 在微软更新了win101909后,有很多新功能,其中的高性能模式,

  • 华为手机北斗导航如何开启 打开北斗定位系统方法

    华为手机北斗导航如何开启 打开北斗定位系统方法

    文章摘要:华为手机北斗导航如何开启和打开北斗定位系统方法的介绍,如有不对的地方欢迎指正! 从车道级导航到北斗创新应用,高精度成为全球卫星导航发展热点。 2 月 18 日,千寻位置与