Manual Chapter :
Configuring SIP Load Balancing
Applies To:
Show VersionsBIG-IP LTM
- 17.1.1, 17.1.0, 17.0.0, 16.1.5, 16.1.4, 16.1.3, 16.1.2, 16.1.1, 16.1.0, 16.0.1, 16.0.0, 15.1.10, 15.1.9, 15.1.8, 15.1.7, 15.1.6, 15.1.5, 15.1.4, 15.1.3, 15.1.2, 15.1.1, 15.1.0, 15.0.1, 15.0.0
Configuring SIP Load Balancing
Overview: Configuring a SIP proxy
You can use the BIG-IP system as a Session Initiation Protocol (SIP)
proxy. When the BIG-IP system is placed between your SIP routers, session border controllers, and
soft switches, you can configure the system to route and load balance SIP messages across the
servers on your SIP network.
This graphic illustrates the relationships of the configuration objects that you must configure
on the BIG-IP system.
About managing MRF
SIP session traffic
Through the SIP Session Profile, you can use Message Routing Framework
(MRF) to manage SIP traffic across pool members by means of configuring and using Via
headers. When you configure Via headers to manage SIP traffic, dependencies between
settings apply, enabling you to steer traffic and control requests and responses, as
necessary.
When
a client Via header only specifies an address, without specifying a port, the BIG-IP system uses default port
5060
. For example, if a client sends
a request with Via header SIP/2.0/TCP
192.168.20.1
, in SIP session traffic scenario 1 (default), the BIG-IP system
sends a response to the client with Via header SIP/2.0/TCP 192.168.20.1/5060
.Example: SIP
session traffic scenario 1 (default)
In SIP session
traffic scenario 1 (default), the BIG-IP system receives a request with a Via1
header from a client, and inserts a Via2 header into the request before forwarding
the request to the server. When the server provides a response, the BIG-IP system
removes the Via2 header from the response, before forwarding the response to the
client. If the originating connection no longer exists, the Via2 header that BIG-IP
system inserted is no longer available; consequently, the BIG-IP system uses the
Via1 header, forwarding the message to the client IP address and port specified by
that Via header.
When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Enabled |
Do Not Connect
Back |
Disabled |
Insert Via
Header |
Enabled |
Custom
Via |
Not applicable |
Example: SIP
session traffic scenario 2
In SIP session traffic
scenario 2, the BIG-IP system receives a request with a Via1 header from a client,
and inserts a Via2 header into the request before forwarding the request to the
server. When the server provides a response, the BIG-IP system removes the Via2
header from the response, before forwarding the response to the client. When the
originating connection no longer exists, then the BIG-IP system drops the response
message and increments the statistic for
Messages failed due to connection
dropped
.When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Enabled |
Do Not Connect
Back |
Enabled |
Insert Via
Header |
Enabled |
Custom
Via |
Not applicable |
Example: SIP
session traffic scenario 3
In SIP session traffic
scenario 3, the BIG-IP system receives a request with a Via1 header from a client,
and inserts a Via2 header into the request before forwarding the request to the
server. When the server provides a response, the BIG-IP system removes the Via2
header from the response, before forwarding the response to the client. If the
originating connection no longer exists, then the Via header that BIG-IP system
inserted is no longer available; consequently, the BIG-IP system uses the next
available Via header, but, because the
Honor Via
setting is Disabled
, the BIG-IP system does not forward the message to the
client IP address and port specified by that Via header.When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Disabled |
Do Not Connect
Back |
Disabled |
Insert Via
Header |
Enabled |
Custom
Via |
Not applicable |
Example: SIP
session traffic scenario 4
In SIP session traffic
scenario 4, the BIG-IP system receives a request with a Via1 header from a client,
and inserts a Via2 header into the request before forwarding the request to the
server. When the server provides a response, the response from the BIG-IP to the
client must be managed by means of an iRule, for example,
MR::message nexthop TMM:flow_id
or
MR::message route virtual vs_name host
ip:port
. When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Not applicable |
Do Not Connect
Back |
Not applicable |
Insert Via
Header |
Enabled |
Custom
Via |
Custom Via header value, for example:
SIP/2.0/TCP
www.siterequest.com:4343 or SIP/2.0/SCTP
10.10.4.32 |
Example: SIP
session traffic scenario 5
In SIP session traffic
scenario 5, the BIG-IP system receives a request with a Via1 header from a client,
but does not insert a Via header into the request before forwarding the request to
the server. When the server provides a response, the BIG-IP system uses the client
Via1 header in the response to forward the message to the client IP address and port
specified by that Via header.
When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Enabled |
Do Not Connect
Back |
Not applicable |
Insert Via
Header |
Disabled |
Custom
Via |
Not applicable |
Example: SIP
session traffic scenario 6
In SIP session traffic
scenario 6, the BIG-IP system receives a request with a Via1 header from a client,
but does not insert a Via header into the request before forwarding the request to
the server. Instead, the BIG-IP system uses the Via1 header specified in the
request. When the server provides a response, the BIG-IP system uses the Via1 header
in the response, but does not forward the message to the client IP address and port
specified by that Via header.
When configuring this scenario, the following SIP Session
Profile settings apply.
SIP Session Profile control |
Setting or value |
---|---|
Honor Via |
Disabled |
Do Not Connect
Back |
Not applicable |
Insert Via
Header |
Disabled |
Custom
Via |
Not applicable |
Configuration objects required for a SIP proxy
This table names and describes the objects necessary to configure the BIG-IP system as
a SIP proxy.
Configuration Objects |
Description |
---|---|
Session Profile |
Defines how BIG-IP processes SIP messages, including the data used to persist SIP
connections. |
Transport config |
Defines how BIG-IP connects with the servers on your SIP network. |
Pool |
Defines how BIG-IP load balances connections across a group of servers. |
Peer |
Defines how BIG-IP connects with the servers on your network and to which servers
the system routes and load balances SIP messages. |
Static route |
Defines how BIG-IP routes SIP messages. |
Router profile |
Defines an instance of a SIP router. |
Virtual Server |
Defines the destinations in your network, including the servers that process
incoming SIP requests and the pool members that process connections between BIG-IP and
your SIP network. |
Task summary
for configuring SIP load balancing
Complete these tasks to configure SIP message routing on a
system.
Creating a SIP session profile
Create a SIP session profile to define how the BIG-IP system
processes SIP messages, including the data the system uses to persist SIP connections.
- On the Main tab, click.The SIP transport config list screen opens.
- On the menu bar, clickSession Profiles.The Session Profiles list screen opens.
- ClickCreate.The New SIP Session Profile screen opens.
- In theNamefield, type a unique name for the SIP session profile.
- From thePersist Keylist, select the value the system uses for persistence of a SIP session. The options are:OptionDescriptionCall-IDThe system uses the value in the Call-ID header field in the SIP message.CustomThe system uses the value of a custom key specified in an iRule.Src-AddrThe system uses the originating IP address in the SIP message.
- From thePersist Typelist, select one of these options:OptionDescriptionSessionPersistence is enabled.NonePersistence is disabled.
- In thePersist Timeout (seconds)field, type the number of seconds before a SIP session persistence record expires.
- ClickFinished.
Creating a transport config
Ensure that at least one SIP session profile exists in the BIG-IP system configuration.
Create a transport config to define how the BIG-IP system connects with the servers
on your network when routing and load balancing SIP messages.
- On the Main tab, click.The SIP session profiles list screen opens.
- On the menu bar, clickTransport Config.The New Transport Config screen opens.
- ClickCreate.
- In theNamefield, type a unique name for the transport config.
- For theProfilessetting, move both a transport protocol profile (TCP, UDP, or SCTP) and a SIP session profile from theAvailablelist to theSelectedlist.You can associate only one protocol profile and one SIP session profile with each transport config.
- ClickFinished.
Implementing Low-Latency Electronic Trading with FIX load balancing
Creating a peer
In order to create a peer, you must first ensure that at least one transport
configuration and one pool exist in the BIG-IP system
configuration.
You create a peer to define how the BIG-IP system connects with the servers on your
network, and to which servers the system routes and load balances messages.
- On the Main tab, click.The Diameter session profiles list screen opens.
- On the menu bar, clickPeers.The Peers list screen opens.
- ClickCreate.The New Peer screen opens.
- In theNamefield, type a unique name for the peer.
- In theDescriptionfield, type a description of the peer.
- From theConnection Modelist, select an option to specify how connections are distributed to a remote host.OptionDescriptionPer BladeThe number of connections are distributed and controlled per blade on a VIPRION system.Per Peer(Default) The number of connections to a remote host is per peer.Per TMMThe number of connections to a remote host is per TMM on the BIG-IP system.Per ClientThe number of connections to a remote host is per client connection. Responses are delivered to the connection initiating the request. This option is typically used when implementing a firewall, because of its restrictive functionality.The configuredConnection Mode,Number of Connections, andRatiosettings determine how the BIG-IP system uses connections to pool members in delivering messages.
- From thePoollist, select the pool of servers to which the system load balances Diameter messages.In the case where the calls should be always sent to a single SIP Server, you will still need to create a pool with a single member (the SIP Server) and add the same to the peer.
- From theTransport Configlist, select the transport configuration that defines the egress message routing peer connection.
- In theNumber of Connectionsfield, type the number of allowed connections between the BIG-IP system and the servers in the selected pool.
- In theRatiofield, type the ratio assigned to this peer for use within a static route.
- ClickFinished.
A peer determines how the BIG-IP system connects with the servers on your network,
and to which servers the system routes and load balances messages.
Creating a static route
Ensure that at least one peer and one virtual server exist in the BIG-IP system configuration.
Create a static route when you want to route SIP messages from specific clients to
specific domains, and load balance those SIP messages across a group of peers. If the
configured attributes of a static route match the attributes in a SIP message, the
system forwards the message to a member of the pool associated with one of the peers.
The BIG-IP system can use multiple SIP session profiles in a single routing
instance, because a different profile can be associated with each member of a
pool.
- On the Main tab, click.The SIP session profiles list screen opens.
- On the menu bar, clickStatic Routes.The Static Routes list screen opens.
- ClickCreate.The New Route screen opens.
- In theNamefield, type a unique name for the static route.
- In theRequest URIfield, type the value found in the request-uri of a SIP message that the system matches when routing a message.
- In theFrom URIfield, type the value found in theFromfield of a SIP message that the system matches when routing a message.
- In theTo URIfield, type the value found in theTofield of a SIP message that the system matches when routing a message.
- From theVirtual Serverlist, select the virtual server from which the system receives client requests for this static route.If you do not select a virtual server, the system uses this static route to route SIP messages originating from any client.
- From thePeer Selection Modefield, select how the system selects the Peer to route a SIP message to:OptionDescriptionRatioPeer selection is based on the ratio that is set for each peer in theSelectedlist.SequentialPeer selection is based on the order of the peers in theSelectedlist.
- For thePeerssetting, move the peers that define the servers to which the system load balances SIP messages from theAvailablelist to theSelectedlist.
- ClickFinished.
Creating a SIP router profile
Before you start this task, ensure that at least one static route exists on the BIG-IP system.
Create a SIP router profile to define how a router handles SIP traffic.
A SIP
routing profiles binds the virtual server that processes SIP requests from clients
with the peers that connect with the servers on your SIP network.
- On the Main tab, click.The SIP transport config list screen opens.
- On the menu bar, clickRouter Profiles.The Router Profiles list screen opens.
- ClickCreate.The New SIP Router Profile screen opens.
- In theNamefield, type a unique name for the SIP router profile.
- In the Settings area, select theCustomcheck box.
- From theOperation Modelist, selectLoad Balancing.
- To use connection mirroring, configure theTraffic Groupsetting.
- Clear theInherit traffic group from current partition / pathcheck box.
- From the list, select a traffic group, such as,traffic-group-1.
Changing traffic groups, with Connection Mirroring enabled, drops all mirrored connections and loses all persistence data. If you change traffic groups, mirroring must restart.The traffic group for the virtual address and mirrored attribute are overwritten by the attached router profile. - Select theConnection Mirroringcheck box.For connection mirroring to properly function, this device must be a member of a device group.
- In theMirrored Message Sweeper Intervalfield, type the milliseconds for the frequency of the mirrored message sweeper.
- For theStatic Routessetting, move routes that define how the BIG-IP system load balances SIP traffic from theAvailablelist to theSelectedlist.
- ClickFinished.
Creating a virtual server to handle SIP client requests
Ensure that both a SIP session profile and a SIP router profile exist in the BIG-IP system configuration.
Create a virtual server to handle SIP client requests.
- On the Main tab, click.The Virtual Server List screen opens.
- In theNamefield, type a unique name for the virtual server.
- From theTypelist, selectMessage Routing.
- In theDestination Address/Maskfield, type an address, as appropriate for your network.The supported format is address/prefix, where the prefix length is in bits. For example, an IPv4 address/prefix is10.0.0.1or10.0.0.0/24, and an IPv6 address/prefix isffe1::0020/64or2001:ed8:77b5:2:10:10:100:42/64. When you use an IPv4 address without specifying a prefix, the BIG-IP system automatically uses a/32prefix.
- In theService Portfield, type5060to route SIP traffic or5061to route TLS traffic.
- From theConfigurationlist, selectAdvanced.
- From theApplication Protocollist, selectSIP.
- From theSession Profilelist, select a SIP session profile.
- From theRouter Profilelist, select a SIP router profile.
- ClickUpdate.
Configuration objects required for a SIP proxy
This table names and describes the objects necessary to configure the BIG-IP system as
a SIP proxy.
Configuration Objects |
Description |
---|---|
Session Profile |
Defines how BIG-IP processes SIP messages, including the data used to persist SIP
connections. |
Transport config |
Defines how BIG-IP connects with the servers on your SIP network. |
Pool |
Defines how BIG-IP load balances connections across a group of servers. |
Peer |
Defines how BIG-IP connects with the servers on your network and to which servers
the system routes and load balances SIP messages. |
Static route |
Defines how BIG-IP routes SIP messages. |
Router profile |
Defines an instance of a SIP router. |
Virtual Server |
Defines the destinations in your network, including the servers that process
incoming SIP requests and the pool members that process connections between BIG-IP and
your SIP network. |
About checking pool
member health
You can configure the BIG-IP
system to monitor pool member health using
a SIP monitor. Use a SIP monitor to check the health of a host with an active
SIP session.
The SIP monitor also monitors a SIP connection independent of a specific SIP session and marks a
host that had been marked down, but is online again, as available.
Creating a SIP monitor
Create a SIP monitor to mark a pool member as down when that server stops
responding and then to mark the pool member as available when service is
restored.
- On the Main tab, click.The Monitors List screen opens.
- ClickCreate.The New Monitor screen opens.
- In theNamefield, type a name for the monitor.
- From theTypelist, selectSIP.The screen refreshes, and displays the configuration options for theSIPmonitor type.
- Configure additional settings based on your network requirements.
- ClickFinished.
Adding a health
monitor to a pool
Add health monitors to a pool when you want the
BIG-IP system to monitor the health of the pool members. Repeat this procedure for each
desired pool.
- On the Main tab, click.The Pool List screen opens.
- Click the name of the pool you want to modify.
- For theHealth Monitorssetting, in theAvailablelist, select a monitor type, and click<<to move the monitor to theActivelist.Hold the Shift or Ctrl key to select more than one monitor at a time.
- ClickFinished.
The new pool appears in the Pools list.
About viewing SIP session and router statistics
You can view statistics for SIP sessions and routes.
Viewing SIP session statistics
Ensure that at SIP session router profile are assigned to at least one virtual
server.
When you want to see how the BIG-IP system is handling SIP
communications, you can view statistics per SIP session profile.
- On the Main tab, click.The Local Traffic statistics screen opens.
- From theStatistics Typelist, selectProfiles Summary.
- In the Details column for the SIP Session profile, clickViewto display detailed statistics about SIP sessions.
Viewing SIP router statistics
Ensure that at SIP session and SIP router profile are assigned to at least one
virtual server.
When you want to see how the BIG-IP system is handling SIP
message routing, you can view statistics per SIP router profile.
- On the Main tab, click.The Local Traffic statistics screen opens.
- From theStatistics Typelist, selectProfiles Summary.
- In the Details column for the SIP Router profile, clickViewto display detailed statistics about the routing of SIP messages.