Score:0

Rsyslog unable to receive syslogs from two or more switches , error in rsyslog configuration file

ng flag

I am trying to send syslogs from routers/switches in a production environment to a linux server which has Rsyslog installed on it. Its working fine as long as rsyslog config file is set to receive logs from one switch, as soon as I am making changes to the rsyslog configuration file to receive logs from another switch as well , its throwing error while restarting rsyslog server after making changes and the logs are no longer recorded. Its back to normal operation of recording logs as long as I am configuring it to receive logs from just one switch.enter image description here

Zius_123 avatar
ng flag
# # Where to place spool and state files # $WorkDirectory /var/spool/rsyslog module(load="imfile" PollingInterval="10") # # Include all config files in /etc/rsyslog.d/ # $IncludeConfig /etc/rsyslog.d/*.conf If $fromhost-ip == "##.##.#.###" then { Action (type="omfile" File="/home/**path**/**path**/**path**/latest.log") } If $fromhost-ip == "##.##.#.###" then { Action (type="omfile" File="/**path**/*path*/*path*/***/latest.log") }
pt flag
If you need to add more information to your question, **edit the question** rather than adding it as a comment. As you can see, comments don't allow you to properly format config files or source code, rendering them almost unreadable. It is also much better to include text directly in your question, rather than linking to *images* of text (because we can't copy-and-paste text from the image, and when the linked image expires this question will be useless to future readers).
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.