Learn F5 Technologies, Get Answers & Share Community Solutions Join DevCentral

Filter by:
  • Solution
  • Technology
Answers

LTM HTTP Monitor Send and Receive syntax

Hi,

I'm trying to configure a monitor that will check if a website is up on a Linux server. My Send string is GET /dms/loginForm.jpg HTTP/1.1\r\nHost:7270 \r\nConnection: close\r\n\r\n and if i leave the receive string blank it works and if I set the receive string to 200 OK it works, even though on of the sites is down. See below.

[Joseph.Johnson@US-MABILLDC-INTLTM-02:Active:Changes Pending] ~ # curl -vk http://10.202.10.169:7270/dms/loginForm.jsp

  • About to connect() to 10.202.10.169 port 7270 (#0)
  • Trying 10.202.10.169... connected
  • Connected to 10.202.10.169 (10.202.10.169) port 7270 (#0)

GET /dms/loginForm.jsp HTTP/1.1 User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 OpenSSL/1.0.1j zlib/1.2.3 libidn/0.6.5 Host: 10.202.10.169:7270 Accept: /

< HTTP/1.1 200 OK < Cache-Control: no-cache < Date: Thu, 10 Aug 2017 20:00:03 GMT < Pragma: no-cache < Content-Length: 2824 < Content-Type: text/html; charset=UTF-8 < Expires: Thu, 01 Jan 1970 00:00:00 GMT < X-ORACLE-DMS-ECID: dc812bacc6eaa1df:-521687cc:15dcd4a6325:-8000-0000000000000163 < Set-Cookie: JSESSIONID=zarNu3_3TyGdblWUPx-DjF7ACO-t3xgVoiK9zVVT3zGdcvNJXN1U!-1852036927; path=/; HttpOnly

[Joseph.Johnson@US-MABILLDC-INTLTM-02:Active:Changes Pending] ~ # curl -vk http://10.202.10.70:7270/dms/loginForm.jsp * About to connect() to 10.202.10.70 port 7270 (#0) * Trying 10.202.10.70... Connection refused * couldn't connect to host * Closing connection #0 curl: (7) couldn't connect to host

Why is it that even with no connection made, the monitor is still marking the pool member as up when i set the receive string to 200 OK and is there anything i should change with it?

Thanks in advance!

0
Rate this Question
Comments on this Question
Comment made 5 days ago by Chris Grant

If you run a tcpdump on the HTTP monitor instead of manually curling, do you get the same results? Remember that monitors run on the nonfloating self IP.

0
Comment made 4 days ago by Joseph.Johnson 153

Thanks, that helped out, I saw that the reason I was getting down monitor with 200 OK was because the send string was incorrect and it was sending back 400 error. The pool members use port 8069, is there anyway I can check for a page on a different port on the server to monitor, 7270. For example, the pool members use port 8069 but i want the monitor to be something similar to GET /dms/loginForm.jpg HTTP/1.1\r\nHost:7270? \r\nConnection: close\r\n\r\n.

0
Comment made 4 days ago by Ed Summers 1030

Use the Alias Service Port (GUI) or Destination (TMSH) option on the monitor configuration. If set to * the monitor will use the port configured for the pool member. If set explicitly, the monitor will use the port you configure.

The port doesn't go into the Host header. That header is typically used to specify the hostname that the request is destined for (www.example.com, etc.). It's a required header in HTTP/1.1 requests, but can be blank unless the server requires that a value be set (example: multiple sites running on the same port).

0

Answers to this Question

placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER

Hi,

To check monitor send string, you can follow this snippet!

0
Comments on this Answer
Comment made 4 days ago by Stanislas Piron 4774

And the host value in the monitor send string must be the host as leave the big ip on server side of user request, not the node IP address.

0