1

Whenever I run tail -F /var/log/syslog, I notice there is duplicate entry in the log.

user@svr01:~$ tail -F /var/log/syslog
Jun 19 03:13:37 svr01 dhcpd[2361]:    in your dhcpd.conf file for the network segment
Jun 19 03:13:37 svr01 sh[2361]:    in your dhcpd.conf file for the network segment
Jun 19 03:13:37 svr01 dhcpd[2361]:    to which interface enp0s3 is attached. **
Jun 19 03:13:37 svr01 sh[2361]:    to which interface enp0s3 is attached. **

The only difference is one started with sh[2361], while the other one is dhcpd[2361].

  1. May I know what is the purpose of the duplication of the log?

  2. Besides grep, is there a way to remove the duplication so that easier to read the log?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.