Forum Discussion
rgordon_01
Nimbostratus
Mar 02, 2016LTM I want to add 329 networks to be directed to a different pool than assigned to the VS. Could this be done by importing External file management?
Here is the situation. During testing we've setup an iRule and datagroup that says when client accepted if ip address equals what is in datagroupA send to this pool else send to this pool. Everythi...
raduioncu_16351
Nimbostratus
Mar 02, 2016Hi,
You can easily script a data group generation (even from Excel - use CONCATENATE() ) that contains the subnet as key and the pool name as data so you can more easily assign the pool - then just copy and paste the entries in TMSH.
create ltm data-group internal TEST-IP type ip
modify ltm data-group internal TEST-IP records add { 10.1.0.0/24 { data "STOREA-POOL" } }
modify ltm data-group internal TEST-IP records add { 10.2.0.0/24 { data "STOREB-POOL" } }
....
ltm data-group internal TEST-IP {
records {
10.1.0.0/24 {
data STOREA-POOL
}
10.2.0.0/24 {
data STOREB-POOL
}
}
type ip
}
Radu
rgordon_01
Nimbostratus
Mar 03, 2016I created a text file -here's few lines as example:
modify ltm data-group internal TEST-IP records add { 10.175.129.0/24 { data "silverlight" } }
modify ltm data-group internal TEST-IP records add { 10.175.132.0/24 { data "silverlight" } }
modify ltm data-group internal TEST-IP records add { 10.175.133.0/24 { data "silverlight" } }
modify ltm data-group internal TEST-IP records add { 10.175.139.0/24 { data "silverlight" } }
modify ltm data-group internal TEST-IP records add { 10.175.143.0/24 { data "silverlight" } }
executed the command from TMSH on our test f5. It created the new data group which is good but when you view the address records from the GUI it's not what I'm looking for. They showed up as:
10.175.129.0/24:=silverlight
10.175.132.0/24:=Silverlight
All the networks in my text file will go to the same pool which the iRule is already redirecting them to. So then I removed data "Silverlight from the command and ran this
modify ltm data-group internal TEST-IP records add { 10.175.129.0/24 }
modify ltm data-group internal TEST-IP records add { 10.175.132.0/24 }
modify ltm data-group internal TEST-IP records add { 10.175.133.0/24 }
modify ltm data-group internal TEST-IP records add { 10.175.139.0/24 }
modify ltm data-group internal TEST-IP records add { 10.175.143.0/24 }
the data looks more like I expected now EXCEPT the mask shows up as /24 instead of 255.255.255.0 like it's setup in our working production LTM. It may accept both ways but checking the help menu says it does not. So now I have to go back and redo excel to create a new text file with the correct mask format. Although this was easier than manually entering each network I've still had to do a lot of work to get the text file in the correct format. Can you confirm yes or no that the /24 does not work for the mask format?
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
