Forum Discussion
babudheen_72823
Nimbostratus
May 08, 2014How to enable logs on LTM if http profile is not used
Hi,
Can anyone help me how can we enable logging through irule in case HTTP profile not enabled in one VIP configuration in LTM.
Need valuable help.
Regards
Papdheen M
Kevin_Stewart
Employee
May 19, 2014There's a few ways to do this:
-
An iRule - if you want to be very specific about what you log, you can issue an HSL log statement within an iRule. Example:
when CLIENT_ACCEPTED { set hsl [HSL::open -proto UDP -pool syslog-pool] } when HTTP_REQUEST { switch -glob [string tolower [HTTP::uri]] { "/app1*" { HSL::send $hsl "<134>User accessing /app1 from [IP::client_addr]" } "/app2*" { HSL::send $hsl "<134>User accessing /app2 from [IP::client_addr]" } } } -
A request logging profile - under Local Traffic - Profiles - Other - Request Logging, create a request logging profile that details what data you want captured and what syslog pool you want it sent to. This is quite a bit more brute force than the iRule approach, so maybe not entirely what you're looking for. Here's some additional information on the request logging profile nonetheless:
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects