Forum Discussion
mihaic
Jan 27, 2015MVP
Http class to irule conversion?
Does anyone know how to convert a http class to an irule.
Starting with version 11.4 it seems http classes do not exist anymore.
I need to convert a lot of http classes to an irule for a new device w...
Jan 27, 2015
Hi mihaic,
sorry, it took a bit longer as I crashed my v10 VE license and had to wait for a nice guy at F5 to provide a new one. Anyway, here we go:bigpipe pool list | grep -oE '^(pool [^ ]+|[[:blank:]]+([0-9]+\.){3}[0-9]+:[[:alnum:]]+)' | \
sed -r ':a;N;$!ba;s/\n[[:blank:]]+/ /g' | \
sed -r 's/pool ([^ ]+) (.*)$/ltm pool \1 { members { \2 } monitor gateway_icmp }/g'
The one-liner above dumps all pool configuration data, extracts name and members only and builds the syntax to import in v11.
Btw, if you are already on v10 you can use the tmsh commands to export the configuration in proper way:tmsh list ltm monitor http
tmsh list ltm pool
Commands above provide all data in required format to import directly into v11.
Import works fine via tmsh as well:tmsh load sys config merge file
or inside tmsh:
load sys config merge from-terminal
(copy and paste input and press ^D to finish)
Don´t forget to save to startup config afterwards:
tmsh save sys config
Thanks, Stephan
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