For more information regarding the security incident at F5, the actions we are taking to address it, and our ongoing efforts to protect our customers, click here.

Forum Discussion

johnbernardcheu's avatar
Jul 27, 2017

Request Logging Profile - Respond On Error

hi there, I can't seem to get the Respond On Error feature to work. The template works fine. When I do a tcpdump I don't see the error response being modified. I also don't see any errors being logged either. I m on v12.1 LTM VE. Any ideas?

 

ltm profile request-log my_request_log {
    app-service none
    defaults-from request-log
    log-request-logging-errors yes
    log-response-by-default yes
    log-response-logging-errors enabled
    proxy-close-on-error no
    proxy-respond-on-logging-error yes
    proxy-response "  ERROR 
 503 ERROR-Service Unavailable 
"
    request-log-error-pool request_pool
    request-log-error-protocol mds-udp
    request-log-error-template none
    request-log-pool request_pool
    request-log-protocol mds-udp
    request-log-template "Client for request settings $CLIENT_IP http request $HTTP_REQUEST  ,http status code $HTTP_STATCODE, http status $HTTP_STATUS"
    request-logging enabled
    response-log-error-pool request_pool
    response-log-error-protocol mds-udp
    response-log-error-template none
    response-log-pool request_pool
    response-log-protocol mds-udp
    response-log-template "Client for response settings $CLIENT_IP http request $HTTP_REQUEST  ,http status code $HTTP_STATCODE, http status $HTTP_STATUS"
    response-logging enabled
}

tcpdump result. Disregard the checksum error as it occurs even under normal conditions.

 

10.10.1.100.80 > 10.10.1.130.35445: Flags [P.], cksum 0x1808 (incorrect -> 0                                                                                                                     xe545), seq 1:233, ack 282, win 4661, options [nop,nop,TS val 2229884405 ecr 145                                                                                                                     9866], length 232 out slot1/tmm1 lis=/Common/http_vs
    0x0000:  4500 011c 2b47 4000 ff06 389b 0a0a 0164  E...+G@...8....d
    0x0010:  0a0a 0182 0050 8a75 b5d0 1a65 4bc1 ee9e  .....P.u...eK...
    0x0020:  8018 1235 1808 0000 0101 080a 84e9 55f5  ...5..........U.
    0x0030:  0016 469a 4854 5450 2f31 2e30 2035 3030  ..F.HTTP/1.0.500
    0x0040:  2049 6e74 6572 6e61 6c20 5365 7276 6572  .Internal.Server
    0x0050:  2045 7272 6f72 0d0a 4461 7465 3a20 5468  .Error..Date:.Th
    0x0060:  752c 2032 3720 4a75 6c20 3230 3137 2031  u,.27.Jul.2017.1
    0x0070:  363a 3338 3a31 3220 474d 540d 0a53 6572  6:38:12.GMT..Ser
    0x0080:  7665 723a 2041 7061 6368 652f 322e 342e  ver:.Apache/2.4.
    0x0090:  3130 2028 4465 6269 616e 2920 4f70 656e  10.(Debian).Open
    0x00a0:  5353 4c2f 312e 302e 3174 206d 6f64 5f70  SSL/1.0.1t.mod_p
    0x00b0:  6572 6c2f 322e 302e 3964 6576 2050 6572  erl/2.0.9dev.Per
    0x00c0:  6c2f 7635 2e32 302e 320d 0a43 6f6e 7465  l/v5.20.2..Conte
    0x00d0:  6e74 2d4c 656e 6774 683a 2031 0d0a 436f  nt-Length:.1..Co
    0x00e0:  6e6e 6563 7469 6f6e 3a20 636c 6f73 650d  nnection:.close.
    0x00f0:  0a43 6f6e 7465 6e74 2d54 7970 653a 2074  .Content-Type:.t
    0x0100:  6578 742f 6874 6d6c 3b20 6368 6172 7365  ext/html;.charse
    0x0110:  743d 5554 462d 380d 0a0d 0a0a 0114 0100  t=UTF-8.........
    0x0120:  0001 0f2f 436f 6d6d 6f6e 2f68 7474 705f  .../Common/http_
    0x0130:  7673                                     vs
No RepliesBe the first to reply