Forum Discussion
vallesm77_95699
Feb 16, 2012Nimbostratus
Search a Record In data-group
Hello,
I don't find the good syntax (v11).
I want to search a record on Data-group and init a variable
If my data-group contains only one Record it's ok by the command :
set var [findclass "ForbiddenUrl" [class get VIP_Internet] " "]
log local0. "$var"
Result
==> redirect http://website.fr
My data-group
ltm data-group internal /Common/VIP_Internet {
records {
"ForbiddenUrl redirect http://website.fr" { }
}
type string
}
But if the data-group contains 2 (or much) records the command don"t work.
I must not use the correct command.
How do you do ?
Thanks
- nitassEmployeee.g.
root@ve1110(Active)(/Common)(tmos) list ltm data-group internal VIP_Internet ltm data-group internal VIP_Internet { records { ForbiddenUrl1 { data "redirect http://website1.fr" } ForbiddenUrl2 { data "redirect http://website2.fr" } } type string } [root@ve1110:Active] config cat /var/log/ltm Feb 16 01:40:58 tmm info tmm[7321]: Rule /Common/myrule : [class get VIP_Internet]: {ForbiddenUrl1 {redirect http://website1.fr}} {ForbiddenUrl2 {redirect http://website2.fr}} Feb 16 01:40:58 tmm info tmm[7321]: Rule /Common/myrule : [class search -value VIP_Internet starts_with ForbiddenUrl1]: redirect http://website1.fr Feb 16 01:40:58 tmm info tmm[7321]: Rule /Common/myrule : [class search -value VIP_Internet starts_with ForbiddenUrl2]: redirect http://website2.fr Feb 16 01:40:58 tmm info tmm[7321]: Rule /Common/myrule : [class search -value VIP_Internet starts_with ForbiddenUrl3]:
- vallesm77_95699NimbostratusThanks
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