System messages

Last Updated : May 13, 2024 |

About this task

System messages can alert you to system problems, such as a device that is about to fail. By default, many of the messages are displayed on the system console and are stored in /var/log. To display system messages:

Procedure

Enter dmesg | more

The system displays the most recent messages as shown in the following example:

Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Linux version 2.6.32-279.el6.x86_64 (mockbuild@x86-008.build.bos.redhat.com) (gc c version 4.4.6 20120305 (Red Hat 4.4.6-4) (GCC) ) #1 SMP Wed Jun 13 18:24:36 ED T 2012
Command line: ro root=UUID=3b8fa701-8689-4e03-b022-869d34fbc0be rd_NO_LUKS  KEYB OARDTYPE=pc KEYTABLE=us LANG=en_US.UTF-8 rd_NO_MD SYSFONT=latarcyrheb-sun16 cras hkernel=auto rd_NO_LVM biosdevname=0 rd_NO_DM rhgb quiet
KERNEL supported cpus: 
Intel GenuineIntel
AMD AuthenticAMD
Centaur CentaurHauls
BIOS-provided physical RAM map:
BIOS-e820: 0000000000000000 - 000000000009c000 (usable)
BIOS-e820: 0000000000100000 - 00000000cd2f0000 (usable)
BIOS-e820: 00000000cd2f0000 - 00000000cd31c000 (reserved)
BIOS-e820: 00000000cd31c000 - 00000000cd35b000 (ACPI data)
BIOS-e820: 00000000cd35b000 - 00000000d0000000 (reserved) 
BIOS-e820: 00000000e0000000 - 00000000f0000000 (reserved)  
BIOS-e820: 00000000fe000000 - 0000000100000000 (reserved) 
BIOS-e820: 0000000100000000 - 0000000230000000 (usable)
DMI 2.7 present.
SMBIOS version 2.7 @ 0xFD050

The /var/log directory contains several message files. The most recent messages are in /var/log/messages. Previous system messages are organized into weekly message files and are identified by the date that is appended to the messages file.

The message files may contain not only system messages, but also crash dumps and other data, which can cause /var/log to grow quite large. To keep the directory to a reasonable size and ensure that future crash dumps can be saved, you should remove unneeded files periodically. You can automate the task by using crontab. See your RHEL system documentation for information on crontab.