Information: Forum is in read-only mode
For details and other support options see https://www.adiscon.com/news/support-forum-set-to-read-only-mode/

Monitorware - Accessing logs via UNC Path & include host

Support, Questions and Discussions on MonitorWare Agent

Moderator: alorbach

Google Ads


Monitorware - Accessing logs via UNC Path & include host

Postby BrianR » Tue Aug 07, 2007 2:05 am

Hello,

I'm attempting to deploy a limited number of MWAgent servers by geographic region, each responsible for reading logs from several servers in that geographical region (accessing the logs via \\\\unc\\path). This part works as expected.

However, when forwarding to syslog the source/host always appears to be the MWAgent server, rather than the actual source of the message. Is it possible to manipulate the messages so the actual source is sent to the syslog server (possibly by extracting the hostname from the UNC path of the source service/log)?

Thank you,

-Brian
BrianR
New
 
Posts: 3
Joined: Tue Aug 07, 2007 2:02 am

Postby alorbach » Mon Aug 13, 2007 3:28 pm

Dear Brian,

there is a property called %generatedfilename% which contains the full filename and path of the current processed logfile. You can use this property to determine from where the logfile was read from.

However it also possible to overwrite the %source% property by using a Set Property Action. Use this kind of Property value:
Code: Select all
%generatedfilename:/\\\\/$:/\\/%


It will start searching wit \\ and end searching with \. The content between will be set to the desired property (source in our case). This will work for UNC pathes like this:
\\server\c$\temp\file.log

I also attached XML Code for a Action. Copy this into your clipboard, you can paste it as Action within the MWAgent Client.

Code: Select all
<Actions><Action name="Overwrite Source Property" type="1012" Comments="" bActionEnabled="1" nPropertyType="-1" szPropertyValue="%generatedfilename:/\\\\/$:/\\/%" szPropertyType="source"/></Actions>
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby BrianR » Tue Sep 18, 2007 10:26 pm

Thank you! This is exactly what I was trying to do.

I had some license issues which made the Set Property Action unavailable, but once I got that sorted out. :D
BrianR
New
 
Posts: 3
Joined: Tue Aug 07, 2007 2:02 am

Google Ads



Return to MonitorWare Agent

Who is online

Users browsing this forum: No registered users and 0 guests

cron