CompTIACompTIA
XK0-005 · Question #158
XK0-005 Question #158: Real Exam Question with Answer & Explanation
The correct answer is B: Edit the /etc/rsyslog.conf file to include the line cron.emerg.* /dev/console. The administrator aims to configure the system to send critical or higher severity log messages from the cron utility to the console.
System Management
Question
A Linux administrator wants to configure log messages of critical or higher severity levels from the cron utility to be logged to the console. Which of the following will accomplish this objective?
Options
- AEdit the /etc/logrotate.d/cron file to include the line cron.emerg.* /dev/console
- BEdit the /etc/rsyslog.conf file to include the line cron.emerg.* /dev/console
- CEdit the /etc/logrotate.conf file to include the line cron.emerg.* /dev/console
- DEdit the /etc/rsyslog.d/conf file to include the line cron.emerg.* /dev/console
Explanation
The administrator aims to configure the system to send critical or higher severity log messages from the cron utility to the console.
Common mistakes.
- A. Files in
/etc/logrotate.d/are used bylogrotateto manage the archiving and deletion of log files, not to configure real-time message routing to the console. - C. The
/etc/logrotate.conffile is the main configuration file forlogrotate, defining global log rotation policies, and is not used for real-time log message forwarding. - D. While rsyslog can use files in
/etc/rsyslog.d/, the specific file nameconfis not standard, and/etc/rsyslog.confis the primary and most common location for such global configuration directives.
Concept tested. Syslog configuration for routing messages by facility and severity
Topics
#Logging#rsyslog#System Configuration#Log Management
Community Discussion
No community discussion yet for this question.