RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1498902 - systemd unit file for rsyslog is missing dependency to network.target
Summary: systemd unit file for rsyslog is missing dependency to network.target
Keywords:
Status: CLOSED DUPLICATE of bug 1401456
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: rsyslog
Version: 7.4
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Radovan Sroka
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-10-05 14:06 UTC by Dan Kamm
Modified: 2017-10-09 10:18 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-10-09 10:18:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Dan Kamm 2017-10-05 14:06:44 UTC
Description of problem:

rsyslogd does not send any messages to a remote log concentrator over network after system reboot.

Systemd unit file of rsyslog (/usr/lib/systemd/system/rsyslog.service) is missing the following statement:
<<
[Unit]
...
After=network.target
>>

If rsyslog is configured to send log messages to a log concentrator, after a reboot of the systen, rsyslog is being started before network.target is ready. As sequence, log messages are not being sent out via network.

Adding the dependency to network.target solves the issue.

This dependency was configured in RHEL 7.3 and before in /usr/lib/systemd/system/rsyslog.service

Version-Release number of selected component (if applicable):

- RHEL 7.4
- rsyslog-8.24.0-12.el7.x86_64

How reproducible:

Everytime after system reboot.


Steps to Reproduce:
1. Configure rsyslog to send logs to a network log concentrator
2. #reboot
3. #logger "let me log this"

Actual results:

String "let me log this" does not appear in log concentrator (however, it is logged locally in messages)

Expected results:

String "let me log this" does show up in log concentrator

Additional info:

Diff of rsyslog.service file comparison RHEL 7.3 and 7.4:
$ diff rsyslog.service.rhel73 rsyslog.service.rhel74
4c4,5
< After=network.target
---
> Documentation=man:rsyslogd(8)
> Documentation=http://www.rsyslog.com/doc/
12a14
> Restart=on-failure

"Workaround": Manually restart rsyslog after system boot AND wait for network being up and running. (however, this is no productive workaround).


rsyslog configuration:

# cat /etc/rsyslog.d/syslog.conf 
# Send all logs to Graylog/syslog.<fqdn-deleted>
$PreserveFQDN on
*.*                       @syslog.<fqdn-deleted>:1514

Comment 2 Radovan Sroka 2017-10-09 10:18:19 UTC
This is going to be resolved in rhbz#1401456.

I'm closing this as duplicate.

*** This bug has been marked as a duplicate of bug 1401456 ***


Note You need to log in before you can comment on or make changes to this bug.