PI TCPResponse Interface.
Just like the PI PING Interface, PI TCPResponse
will measure and archive response times. But, instead of
measuring the response time of a physical network interface,
this one will measure the response time of critical
services. By critical services we mean
services like FTP, Web Services,
Mail, or more.
Indeed, the TCPResponse Interface will send a connection
request to the appropriate port, depending on what you
configured in the tags, and then will wait for
the appropriate reply. What will
be sent to the PI Archive is the time between the
request and the reply.
As for PI Ping, the PI TCPResponse Interface
only has one interface-specific parameter,
Timeout. As you can see,
it has a default of five seconds, but
under ICU in the TCPResponse
tab, you can simply check that check-box and type
long timeout if you do not want to use the default.
To configure a TCPResponse tags,
you can use all of our numerical PointTypes
as the interface normally stores a response time.
For DNS operation, you could use our string
type. You may remember
the three parameters that associate tags with interfaces:
PointSouce, Location1,
and Location4.
PointSource in the tag should be equal to the
PointSource you set at the interface level.
By default, TCPResponse has a PointSource of,
of P. Location1 in the tag
should be set to the Interface ID number,
again, as specified in ICU.
And Location4 should represent the
number of the scan class you want to use, the frequency
at which you want to scan for a response time.
In some cases you may be
interested in using a different timeout that the one you specified
at the interface level. For such cases,
you can use Location3 in which you specify
a timeout for this particular tag in milliseconds.
And one of the most important fields
in TCPResponse tags, Location2,
which corresponds to the type of service you want to
measure. This will be described on next page.
As you can see, Location2
is the type of service you want to measure. It can take a number
from one to ten. You simply
set it to whatever service you want to measure:
FTP, HTTP, SMTP,
and so. One special
setting is the number 5, which means you want to measure
some generic TCP-IP service.
When using Location2 equal five,
the port number must be specified in the
InstrumentTag field. That will be covered in
the next page. Something else we can do with the
TCPResponse Interface is measure in DNS
Operations. These are Location2 equals
one and ten. The difference
in those two settings is that the first
one is Indirect DNS Operation, which means
the interface will use the default DNS
Server as configured in Windows.
Location ten is Direct DNS Operation.
For this one, you will
have to specify a DNS Server.
Again, this is done in InstrumentTag as described
on the next page. Just remember
that for Location2 equals ten,
you must be in Windows XP or
2003. Also, you may have
noticed there is no setting six.
This one is simply reserved
for backward compatibility with previous versions of the
TCPResponse Interface.
One last special detail here
is that for DNS Operations,
Location2 equals one or ten.
When you create a numerical tag, that
will store the completion time of the DNS
operation, the normal behavior of the
TCPResponse Interface. However, if you configure
a string tag for DNS settings,
it will not store the completion time of the operation,
but the actual result of the DNS
translation. The last location
code, Location5, is for
debugging. Zero means you do not send anything
to the PIPC.log file. Then you
have four different settings, depending on what messages
you want to send in the PIPC.log file.
These could be really helpful to troubleshoot
tags when you do not get the expected
result. The other important field
when configuring TCPResponse tags is
InstrumentTag. This one contains pairs of
keywords and values, all separated by
semicolons. The most important one is
Device Equals. For all the
settings except DNS Operation, Device
Equals should contain the machine on which to measure the
service. When using Location2
Equals five, which means you want to measure some generic
TCPIP Service, it is mandatory that Port
Equals is there, with the number of the Port to
monitor. On the other side, when
performing DNS Operations, the important
keyword is Input.
This is where you specify the Host Name to translate
to an IP Address, or for
entering a DNS Operation, you could also translate
IP Addresses into Host Names.
The main difference here between Indirect and
Direct DNS Operation is that you have to
specify an IP Address for the DNS Server to use
for their [inaudible] DNS Operation,
while Indirect DNS Operation will use the Default1
as configured in Windows.
As you already know, the PI TCPResponse Interface will send
queries to services and then wait for their reply.
The queries and replies
really depend on the settings you use in Location2.
For example, on the Web Server,
the expected reply is HTTP-1.1.
In some cases,
Web Server require a username and a password.
These Servers will reply Forbidden.
If you want to tell the PI
TCPResponse Interface to expect a different
answer than the default one, you could also use the keyword
Reply. This is true for
Location2 equals two, three four, seven,
and eight. Otherwise, the interface
will simply tell you the service is not running.
Something interesting you can do when
configuring PI Points is to configure them event-based.
Instead of scanning for values on a regular basis
based on the Scan Class you selected,
you can scan for values whenever a specified tag
receives a new value. If you
go into ExDesc, the extended descriptor attribute
of your tag, you can put event equals
and then the name of a tag. Whenever
this tag receives a new value, a scan will be triggered.
Obviously, as Location4 is
where you normally set the number of the Scan Class to use,
when configuring such tags, you should set
Location4 to zero. Also,
keep in mind this is a feature in UniInt,
the Universal Interface. That means
this is valid for all the IT Monitor Interfaces.
Now, let's look
at some examples of TCPResponse Tags. This is
how you would configure some in Excel using the Tag
Configurator Add-in. The first one
is an example of how you would measure the response time of
the SMTP service on a mail server.
The first three attributes you should think of
are the three attributes linking tags to interfaces:
PointSource,
Location1 -- the ID Number for the Interface --
and Location4 -- the ScanClass Number.
Then Location2 is the type
of service you want to measure. Four means
SMTP. When using SMTP, the only
thing you have to specify in InstrumentTag
is Device -- the IP Address
or the name of the mail server you want to measure the service
from. Our second example
will actually store the result of a DNS translation
for the IP Address 10.1.1.15.
As you can see,
the PointType is string. In Location2,
is one, which means Indirect DNS Operation.
As Indirect DNS Operation
will, by default, use the DNS
Server as specified in Windows, the only thing you have
to specify in InstrumentTag is Input. That means
the IP Address to translate into a
host name. In our last example,
we measure the response time of Terminal Services
on a server. Because we do not have
a pre-determined setting in Location2 for Terminal
Services, you would use Location2 set to
five, which means a generic TCPIP Service.
When you use a generic TCPIP Service,
what you have to do in addition to specifying the
Device on which to measure, you have
to specify the Port Number.
As you can see, Port Number for Terminal Services
is 3389. And that is what
completes our examples for TCP Response Tags.
If you have access to the regular class manual,
what you could do is go for Exercise #13.