Forum Discussion
4 Replies
Sort By
- Brad_ParkerCirrus
Here is a very basic way of doing it.
when CLIENT_ACCEPTED { if { [IP::addr [IP::client_addr] equals 8.8.8.8] }{ node 10.0.0.1 } }
Are you wanting to map multiple sources to multiple nodes? That would require a little more logic but can be accomplished with a data group with the value being the node you want a particular source to go to.
when CLIENT_ACCEPTED { if { [class match [IP::client_addr] equals source_dg] }{ node [class lookup [IP::client_addr] source_dg] } else { pool default_pool } }
- Tariq_Sako_9038Nimbostratus
thanks a lot for your kind help, the first one seems great, but will the rest of clients proceed normally load balanced to the nodes? or should i add (else) too there?
- Brad_ParkerCirrusWith the first one if it doesn't match the IF statement then it will use the default pool assigned to the VIP. Typically if I'm going to use an iRule to load balance more than just a one off exception I use the iRule to pick the pool or node for all traffic. The first one I would just consider an exception so I wouldn't use the iRule to pick the pool or node for all traffic.
- Tariq_Sako_9038Nimbostratus
Thanks a lot Brad for your kind help, i really appreciate your time and efforts.