пятница, 28 декабря 2007 г.

LoadRunner - проблемы мониторинга UNIX ресурсов

Проблема 1 - Cannot initialize the monitoring on unixpc

Во время проведения нагрузочного тестирования, при попытке снять показания с UNIX сервера с помощью "UNIX Resources" монитора в LoadRunner Controller, зачастую получаем ошибку:

Monitor name :UNIX Resources. Cannot initialize the monitoring on unixpc. Error while creating the RPC client. Ensure that the machine can be connected and that it runs the rstat daemon (use rpcinfo utility for this verification). Detailed error: RPC: Failed to create RPC client.
RPC-TCP: Failed to establish RPC server address.

RPC-TCP: RPC Server <100001,> is not registered on host 'unixpc'. (entry point: CFactory::Initialize). [MsgId: MMSG-47190]

Решение

To be able to perform monitoring of UNIX resources an additional daemon is needed on the this machine. It's supposed to be places in /etc/netd.conf

"rstatd" - preferable set it to autostart.

После включения необходимого daemon LoadRunner начнет без проблем мониторить ресурсы UNIX сервера.


Проблема 2 - Internal rpc error (error code:2)

При измерении системных ресурсов Unix, система до какого-то периода снимает данные с rstat демона, потом резко перестает это делать, выдавая ошибку:

Monitor name :UNIX Resources. Internal rpc error (error code:2). Machine: some IP Hint: Check that RPC on this machine is up and running. Check that rstat daemon on this machine is up and running (use rpcinfo utility for this verification). Details: RPC: RPC call failed.

Решение

To configure the rstatd daemon:
Run the command: su root
Go to /etc/inetd.conf and look for the rstatd row (it begins with the word rstatd). If it is commented out (with a #), remove the comment directive, and save the file.
From the command line, run: kill -1 inet_pid
where inet_pid is the pid of the inetd process. This instructs the inetd to rescan the /etc/inetd.conf file and register all daemons which are uncommented, including the rstatd daemon.

Run rup again. If the command still does not indicate that the rstatd daemon is configured, contact your system administrator.

Note 1: To monitor a UNIX machine through a firewall, you must run a UNIX utility called rpcinfo and identify the rstatd's port number. By running rpcinfo -p <hostname>, you will receive a list of all RPC servers registered in the host's portmapper, along with the port number. This list will not change until rstatd is stopped and rerun.

Some firewalls allow you to open an RPC program number instead of a port. In such cases, open program 100001. If are prompted to include a version number, specify versions 3 and 4. You have only to find the port to which it is listening.

Note 2: rpcinfo probably no more exist, so you can try to use rpcbind


2 комментария:

Анонимный комментирует...

Goal:
I try to monitor Unix resources of server by LoadRunner.

HowTo:
Preparation was done as following at customer's side.

* Check if configuration of service rstatd was set correctly at daemon xinetd/inetd
- look at file "/etc/inetd.conf" or "/etc/xinetd.conf" and check settings
rstatd/1-5 dgram rpc/udp wait root /usr/bin/tcpd /usr/sbin/rpc.rstatd

* Get incoming connection from Controller (163.x.x.x) to SAP server (157.x.x.x) on port 111 by rstatd internal settings with granted access.

For rstatd running under xinetd/inetd daemon:
- add the following line at file "/etc/hosts.allow"
rpc.rstatd: 163.x.x.x/255.255.255.0

- restart xinetd/inetd

Result:
Monitor name :UNIX Resources. Cannot initialize the monitoring on 157.x.x.x. Error while creating the RPC client. Ensure that the machine can be connected and that it runs the rstat daemon (use rpcinfo utility for this verification). Detailed error: RPC: Failed to create RPC client.
RPC-TCP: Failed to establish RPC server address.

Analysis of problem:

>telnet 157.x.x.x 111
connection from Controller_pc to server is fine

>rpcinfo -p
100000 2 tcp 111 portmapper
100000 2 udp 111 portmapper
100001 2 udp 12623 rstatd

Assumption about reason of problem:
Probably firewall restrictions doesn't allow to monitor server.

AQ:
Could you advise how i can fix problem?

Анонимный комментирует...

Solution:

Correct firewall rule which should be:

Source: 163.x.x.x
Destination: 157.x.x.x
Protocol: udp
Packet transformation: INPUT
Target: ACCEPT
Port: 12623

Approximately like this:
iptables -A INPUT -s 163.x.x.x -i ethX -d 157.x.x.x -p UDP --dport 12623 -j ACCEPT

Условия копирования публикаций:

Все публикации в данном блоге являются частной собственностью авторов. Любое копирование информации допускается только при условии указания имени автора и активной ссылки на источник.