SNAT with adress range?

Hello.

Is it possible to assign address range in SNAT instead of one address?

I tested that I can put two addresses in SNAT but what about range.

And second question.

When I put two addresses every time client sends request the source IP changes like round robin. Is it normal behaviour that can not be avoided?

M.

Hi,

You can create a SNAT pool with multiple addresses for TMM to use to SNAT traffic. If you want to ensure the same SNAT IP is used for the same client IP, you can use an iRule to apply a hash:

Aaron

Hello hoolio.

Thanks for answering me. But let me ask further for clarification. When I’m talking about SNAT pool whith range for example having class C address

I have 253 adresses that can be used. Do I have put each one by one?

marcinq - I have done exactly what you are doing. By far the easiest way to do it is by modifying the bigip.conf file directly. That is a lot easier than adding them in one by one. Add one, look how it is in the config file, then repeat 253 times, using a spreadsheet or something to count up through the IP addresses. (I used Excel and exported it to .txt) Edit the bigip.conf file as necessary, and then reload the bigip.conf file back to the LTM, and run a “b load” command for 10.x at the CLI or “tmsh load sys config partitions all” command for 11.x… Hope this helps.

in case bigpipe is available.

[root@ve1024:Active] config  b snatpool test members 1.1.1.{1..5}
[root@ve1024:Active] config  b snatpool test list
snatpool test {
   members {
      1.1.1.1
      1.1.1.2
      1.1.1.3
      1.1.1.4
      1.1.1.5
   }
}

Nitass - is there a TMSH equivalent for that? Would make my life easier occasionally. :stuck_out_tongue:

is there a TMSH equivalent for that? Would make my life easier occasionally. :Pi think there is no equivalent command in tmsh but we may be able to make it using scripting.

Found it. :slight_smile:

tmsh create /ltm snatpool client1_snatpool members add { 1.1.1.50 2.2.2.50 }

tmsh create /ltm snatpool client1_snatpool members add { 1.1.1.50 2.2.2.50 }i thought you meant series of member IP address.

Oops. I thought this would work -

tmsh create /ltm snatpool client1_snatpool members add { 1.1.1.{1..5}}

I get -

Syntax Error: “1.1.1.2” unknown property

is there a TMSH equivalent for that? Would make my life easier occasionally. :Pit would look like this.

CreatePoolMembers

Hello.

Thank all of you for the answer. I see both methods are possible.

I mean - put list one by one and option with scripting what nitass suggested.