LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 04-24-2019, 04:26 PM   #1
Surya22
LQ Newbie
 
Registered: Apr 2019
Posts: 2

Rep: Reputation: Disabled
How do I forward particular logs under a directory using rsyslog?


Trying to froward following logs from /home/ddlog/ms/logs/execution_logs/_abc-xyz-ms_* to VMware vRealize Log Insight using rsyslog.For some reason that does not seem to be working.

I have tried using imfile -

# load the external log
$InputFileName /home/ddlog/ms/logs/execution_logs/_abc-xyz-ms_*
$InputFileTag ddlog
$InputFileStateFile ms
$InputFileSeverity debug
$InputFileFacility local7
$InputRunFileMonitor
local7.* @@hostname:514

Commenting out the imfile and updating the rsyslog.conf with the "*.* @@remote-host:514" seems to work perfectly fine but I am more concerned about forwarding specific logs.
 
Old 04-24-2019, 08:34 PM   #2
smithclarkson01
LQ Newbie
 
Registered: Apr 2019
Posts: 2

Rep: Reputation: Disabled
Trying to froward following logs from /home/ddlog/ms/logs/execution_logs/abc-xyz-ms* to VMware vRealize Log Insight using rsyslog.For some reason that does not seem to be working.

I have tried using imfile -

Now load the external log
$InputFileName /home/ddlog/ms/logs/execution_logs/abc-xyz-ms* $InputFileTag ddlog $InputFileStateFile ms $InputFileSeverity debug $InputFileFacility local7 $InputRunFileMonitor local7.* @@hostname:514

Commenting out the imfile and updating the rsyslog.conf with the ". @@remote-host:514" seems to work perfectly fine but I am more concerned about forwarding specific logs.


Download 9Apps 9Apps install VidMate app VidMate download 9apps install

Last edited by smithclarkson01; 05-01-2019 at 02:46 PM.
 
Old 04-25-2019, 02:04 AM   #3
lisaalisa
LQ Newbie
 
Registered: Apr 2019
Posts: 1

Rep: Reputation: Disabled
I have tried using imfile -

# load the external log
$InputFileName /home/ddlog/ms/logs/execution_logs/_abc-xyz-ms_*
$InputFileTag ddlog
$InputFileStateFile ms
I have tried using imfile -

# load the external log
$InputFileName /home/ddlog/ms/logs/execution_logs/_abc-xyz-ms_*
$InputFileTag ddlog
$InputFileStateFile ms
 
Old 07-20-2019, 10:05 PM   #4
scottsen11
LQ Newbie
 
Registered: Jul 2019
Posts: 1

Rep: Reputation: Disabled
How do I forward particular logs under a directory using rsyslog?

If you are just testing and not adding new data to the files you should remove the state files. InputFileStateFile is deprecated I think. It might not work for a glob where many files cannot use the same state file. Try removing that config line. Check for syntax errors with rsyslogd -N 1. You can get lots of debug output with -dn which might provide a clue. droidmoda.com

Last edited by scottsen11; 07-24-2019 at 04:07 AM.
 
  


Reply

Tags
linux, logs, redhat, rhel7, rsyslog


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[rsyslog] how to get the original IP address in rsyslog relay chain wolf4666 Linux - Software 4 10-18-2018 09:17 AM
[SOLVED] Every two minutes rsyslog outputs - rsyslogd: action 'action 3' resumed (module 'builtin:omfile') [v8.32.0 try http://www.rsyslog.com/e/2359 Toadman Linux - Software 9 09-01-2018 12:41 PM
Back up logs file and create a script showing the backed up logs and the running logs Billy_6052 Programming 5 12-13-2014 02:32 AM
[SOLVED] Parse a particular string in files in particular directory and its sub-directories rajivdp Linux - Newbie 4 05-04-2010 08:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:17 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration