Skip to content

Instantly share code, notes, and snippets.

@msoe
Last active January 28, 2018 14:26
Show Gist options
  • Save msoe/c516c272b0668209a6373b8529130327 to your computer and use it in GitHub Desktop.
Save msoe/c516c272b0668209a6373b8529130327 to your computer and use it in GitHub Desktop.

Setting up a standalone F5 GTM from command line using tmsh

In this example, we have:

  • A datacenter "dc1"
  • "dc1" has one BIG-IP as a host "host1"
  • "host1" has one virtual server "www_vs", that host the instance of the web site
  • "global_server_pool" has "www_vs"
  • "global_server_pool" is a group of all website instances across data centers
  • "wideip" creates a name "domain.com" for "global_server_pool"
  • A DNS listener "dns1_listener", that accepts and responds DNS queries

Provisioning the system

# tmsh
# modify sys provision gtm level nominal
# save sys config
# list sys provision
# modify sys db setup.run value false

Creating a data center

# tmsh 
# gtm
# create datacenter dc1
# list datacenter dc1 all-properties

Defining a server

# tmsh 
# gtm
# create server host1 datacenter dc1 monitor bigip address add 192.168.64.20
# list server host1 all-properties

Creating virtual servers to host the site content

# tmsh 
# gtm
# modify server host1 virtual-servers add { www_vs { destination 10.128.20.1:80 monitor tcp } }
# list server host1 all-properties

Creating a pool

# tmsh 
# gtm
# create pool global_server_pool members add { host1:www_vs }
# list pool global_server_pool all-properties

Creating a wideip

# tmsh gtm
# create wideip mydomain.com pools add { global_server_pool } aliases add { www.mydomain.com } 
# list wideip mydomain.com all-properties

Creating a listener

# tmsh gtm
# create listener dns1_listener address 192.168.20.19
# list listener dns1_listener
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment