Forum Discussion
W__Tout_99150
Nimbostratus
Nov 06, 2012Calling a shell script from within an irule
I have a shell script (/bin/sh) I need to run from within an irule. Given the below scenario:
1- I extreact a header from the HTTP request
2- I extract two parameters from the header...
Kevin_Stewart
Employee
Nov 08, 2012I'd suggest 3 options, in order of preference:
1. Cron-managed data group management script - the manipulation of pool data is generally a manual process, so there's probably no reason to make the lookup mechanism real time either. The beauty of this is that you can create a monitor script attached to a "phantom" pool and have a monitor daemon-controlled mechanism that'll save in a config backup; and a process that diligently maintains a list of all IP-pool mapping that's a very fast lookup in your iRule.
2. Convert your HTTP class to a data group and add the HTTP logic to your iRule for more control over the process.
3. If you absolutely, positively must have this data in real time (even though the pool manipulation isn't), you can spin up a persistent netcat (or other) listener in the shell and use a sideband call in your iRule to call a system self-IP. You must absolutely make sure that your netcat script can only perform specific functions, and absolutely understand the security, performance, and supportability implications of this approach.
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
