Forum Discussion
Nicolas_MENOUX_
Nimbostratus
May 18, 2010How to get the line number of my Irule for debugging ?
Hi,
I use many IRules on my F5 BigIP to rewrite URLs for specific services. I logged these rewrited urls into local0.info but I would like to insert in that log the line concerned in my IRul...
hoolio
Cirrostratus
May 18, 2010Hi Nicolas,
I don't think there is a way to get the line number programmatically from an iRule. I suppose you could increment a local variable before each log line and log that though:
set counter 0
log local0. "$counter: my log message"
... iRule code ...
incr counter
log local0. "$counter: my next log message"
... iRule code ...
Or you could hard code the debug lines:
log local0. "1: my log message"
... iRule code ...
log local0. "2: my next log message"
... iRule code ...
Aaron
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
