Need a Scritp (VB or batch)

March 4, 2014 at 14:12:05
Specs: Windows, 8 Gig
Hi All,

I need a script which will give me the output in a text file as per below formate..
Where XXXX, YYYY and ZZZZ could be a server name or a server group name..
ABCD would be the time template.
MYNAME is the name of the persone who has updated the task.


required formate.
**********************************************************************************************************
# USE FOR Suppression of alerts for XXXX and YYYY and ZZZZ- DO NOT DELETE!!!
TIMETEMPLATE "ABCD"
DESCRIPTION "Suppress Alert for XXXX and YYYY and ZZZZ"
TIMETMPLCONDS
TIMETMPLCOND
TIMECONDTYPE Match
TIME FROM hh:mm TO hh:mm
DATE ON mm/dd/yy


# USE FOR Suppression of alerts for XXXX and YYYY and ZZZZ- DO NOT DELETE!!!
MSGTARGETRULE
DESCRIPTION "Suppress Alert for XXXX and YYYY and ZZZZ"
MSGTARGETRULECONDS
MSGTARGETRULECOND
DESCRIPTION "Performed by: MYNAME"
CONDSTATUSVAR "Maintenance"
NODE
NODEGROUP "XXXX"
NODEGROUP "YYYY"
NODEGROUP "ZZZZ"
MSGOPERATIONS
MSGOPERATION
TIMETEMPLATE "ABCD"
SUPPRESS

message edited by gjbedi


See More: Need a Scritp (VB or batch)

Report •

#1
March 5, 2014 at 08:12:34
You need to describe the input.

How To Ask Questions The Smart Way


Report •

#2
March 10, 2014 at 10:38:06
Hi Razor,

In input I need to mention three - four things.
1. REFFRENCE NUMBER
2. SERVER NAME
3. TIME
4. DATE

Input you can take anything for the server name or the server group name.

please ginf the inputs as highlighted

# USE FOR Suppression of alerts for XXXX and YYYY and ZZZZ- DO NOT DELETE!!!
TIMETEMPLATE "ABCD"
DESCRIPTION "TICKET Number# 123456789, Suppress the alerts for the below mentioned NODES"
TIMETMPLCONDS
TIMETMPLCOND
TIMECONDTYPE Match
TIME FROM HH:MM TO HH:MM
DATE ON mm/dd/yy


# Suppress the alerts for the below mentioned NODES.
MSGTARGETRULE
DESCRIPTION "Number# 123456789, Suppress the alerts for the below mentioned NODES"
MSGTARGETRULECONDS
MSGTARGETRULECOND
DESCRIPTION "Performed by: ABC"
CONDSTATUSVAR "Maintenance"
NODE
NODEGROUP "XXXX"
NODEGROUP "YYYY"
NODEGROUP "ZZZZ"
MSGOPERATIONS
MSGOPERATION
TIMETEMPLATE "ABCD"
SUPPRESS


Report •

#3
March 10, 2014 at 10:44:36
Is this the input file, or output?

How To Ask Questions The Smart Way


Report •

Related Solutions

#4
March 10, 2014 at 12:40:48
the highlighted part is the input from a text file....and rest is the output on a diffrent file

Report •

#5
March 10, 2014 at 13:24:02
So you need to show us what the input file looks like.

How To Ask Questions The Smart Way


Report •

#6
March 11, 2014 at 14:27:09
Hi Razor,

Thanks a ton for your response.

So the input file would be a text file in which I need to mention the Node Group name/s, Date and Time in the below format

Ticket Number:123456789
Server Group Name: XXXX, YYYY, ZZZZ
Time: HH:MM to HH:MM
Date: MM/DD/YY TO MM/DD/YY


Report •

Ask Question