Forum Discussion
swo0sh_gt_13163
Sep 16, 2013Altostratus
undefined procedure error in iRule
Hello Folks,
Could you please help me correcting my following iRule?
================================================================
when CLIENT_ACCEPTED {
if {
[IP::addr [IP::remote_addr] equa...
Sep 16, 2013
Hi Darshan, I will look for a working example based on switch.
Another alternative is using datagroups (classes). In the following example an external datagroup (file based) is used:[root@ltmve:Active] config cat dg_snat_mapping_ip
host 10.100.100.20 := "10.100.100.120",
host 10.100.100.21 := "10.100.100.121",
host 10.100.100.22 := "10.100.100.122",
host 10.100.100.23 := "10.100.100.123",
host 10.100.100.24 := "10.100.100.124",
network 10.100.100.0/24 := "10.100.100.126",
[root@ltmve:Active] config bigpipe class ext_dg_snat list
class ext_dg_snat {
type ip
filename "/config/dg_snat_mapping_ip"
mode read
separator ":="
}
when CLIENT_ACCEPTED {
set entry [class match -value [IP::client_addr] equals ext_dg_snat]
if { $entry ne "" } {
snat $entry
}
else {
log local0. "No SNAT for [IP::client_addr]"
}
}
Thanks,
StephanRecent 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