Project 10-3
In this hands-on project, you view the configuration of the System Log Daemon and the logrotate
utility on Ubuntu Server Linux.
1. Boot your Ubuntu Server Linux virtual machine. After your Linux system has been
loaded, log into tty1 using the user name of root and the password of LNXrocks!.
2. At the command prompt, type ls –l /dev/log and press Enter. What is the file type?
Which daemon on Ubuntu Server Linux uses this file and what is its purpose?
3. At the command prompt, type less /etc/rsyslog.conf and press Enter to view
the configuration file for the System Log Daemon. Are there any entries that specify
facilities, priorities, or log file locations? What does the last line of the file specify?
Press q when finished to quit the less utility.
4. At the command prompt, type less /etc/rsyslog.d/50-default.conf and
press Enter. Where do kernel messages of any priority get logged to by default? What
does the – character next to the filename indicate? Press q when finished to quit the
less utility.
5. At the command prompt, type tail /var/log/kern.log and press Enter. Observe
the entries.
6. At the command prompt, type ls /var/log/cups and press Enter. What daemon creates
the log files within the /var/log/cups directory?
7. At the command prompt, type cat /etc/cron.daily/logrotate and press Enter
to observe the logrotate command that is run each day.
8. At the command prompt, type less /etc/logrotate.conf and press Enter to view
the configuration file for the logrotate command. How many copies of old log files
are kept by default? When finished, press q to quit the less utility.
9. At the command prompt, type ls /etc/logrotate.d and press Enter. How many
files are in this directory? Will entries in these files override the same entries in /etc/logrotate.conf?
10. At the command prompt, type cat /etc/logrotate.d/cups-daemon and press
Enter. How many copies of old log files are kept for the log files in the /var/log/cups
directory? Will the log files be rotated if they contain no contents?
11. Type exit and press Enter to log out of your shell.
Answer 2
*************
its symbolic file used for logging socket connections , systemd-journald is a system service that collects and stores logging data. he daemon will implicitly collect numerous metadata fields for each log messages in a secure and unfakeable way.
Answer 3
**********
$IncludeConfig /etc/rsyslog.d/*.conf
it includes the file of all the conf extension
log file location = /etc/rsyslog.d/*.conf
Answer 4
**********
/var/log/kern.log
Using - as a filename to mean stdin/stdout is a convention that a
lot of programs use. It is not a special property of the filename.
The kernel does not recognise - as special so any system calls
referring to - as a filename will use - literally as the
filename.
WE ARE ALLOWED TO ATTEND FIRST 4 QUESTION BUT I DID MORE FOR YOU IF YOU NEED TO SOLVE ALL REMAINING POST IN ANOTHER THREAD. THANKS
if you have any doubt then please ask me without any hesitation in the comment section below , if you like my answer then please thumbs up for the answer , before giving thumbs down please discuss the question it may possible that we may understand the question different way and i can edit and change the answers if you argue, thanks :)
Get Answers For Free
Most questions answered within 1 hours.