Forum Discussion
Jeff_Morrison_4
Nimbostratus
Apr 05, 2006Logging to syslog from iRule
I am wanting to send HTTP information to my syslog-ng server. I have tried to add logging to my iRule but I don't see any information being sent to the Local0 files on the F5.
I would appre...
Colin_Walker_12
Apr 05, 2006Historic F5 Account
Well, first of all, I'm not sure you really want to pass all HTTP traffic to the LTM log, unless it's for a short period of testing or something to that effect.
Second, you can send any information you want to the log, but there isn't a command to generate a standardized log formatted entry.
So, you can create your own logging string, and have it fire for every HTTP_REQUEST event if that's what you're trying to track (like most webservers do).
This would simply be something like:
when HTTP_REQUEST {
log local0. "[IP::client_addr] - [clock format $time_now -format {%d/%m/%Y:%H:%M:%S}] [HTTP::request]"
}Of course you'd want to configure the logging string to fit your needs.
Colin
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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