cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
bascheew
New Contributor II

How to bind SIP trunks to a specific VLAN interface IP

Jump to solution

Let's say I have several VLANs and I have a SIP trunk setup between the 7100 and a few other systems that are on these various VLANs. Is there a way to bind a SIP trunk to a specific VLAN interface IP regardless of which VLAN it passes through?  I know that on the interfaces the media-gateway command is used to designate either the primary or secondary IPs of the interface, or to use a loopback interface IP.  What if I don't want any of these choices and I want to use the IP of the voice VLAN interface in all cases?  Is this possible?

Thank you!

Labels (1)
0 Kudos
1 Solution

Accepted Solutions
Anonymous
Not applicable

Re: How to bind SIP trunks to a specific VLAN interface IP

Jump to solution

It may help for me to first explain how the IP address is derived for outbound SIP/RTP packets generated by the NetVanta 7100.  When a SIP trunk is configured we will look at the IP address for the peer configured with sip-server primary command.  We then use the route table to figure out what egress interface is used to reach that peer IP address.  Then we will look at the egress interface used, and see what is configured for the media-gateway ip command on that interface.  That setting (primary, secondary, or loopback) will determine what we use as the source IP address for outbound SIP/RTP packets generated by the NetVanta 7100 for the remote SIP peer. 

If you want to use the same address on multiple interfaces, media-gateway ip loopback 1 should be used where the loopback 1 IP address is set to your desired address.  For existing configurations, if you change the address, you will have to change anything pointing to the old address (SIP peers, registered phones, etc).  It may be easiest to simply move the existing voice vlan IP address to the loopback 1 interface and then assign another open IP address in the same subnet to the voice vlan interface. I hope this helps.

Thanks,

Matt

View solution in original post

0 Kudos
3 Replies
Anonymous
Not applicable

Re: How to bind SIP trunks to a specific VLAN interface IP

Jump to solution

It may help for me to first explain how the IP address is derived for outbound SIP/RTP packets generated by the NetVanta 7100.  When a SIP trunk is configured we will look at the IP address for the peer configured with sip-server primary command.  We then use the route table to figure out what egress interface is used to reach that peer IP address.  Then we will look at the egress interface used, and see what is configured for the media-gateway ip command on that interface.  That setting (primary, secondary, or loopback) will determine what we use as the source IP address for outbound SIP/RTP packets generated by the NetVanta 7100 for the remote SIP peer. 

If you want to use the same address on multiple interfaces, media-gateway ip loopback 1 should be used where the loopback 1 IP address is set to your desired address.  For existing configurations, if you change the address, you will have to change anything pointing to the old address (SIP peers, registered phones, etc).  It may be easiest to simply move the existing voice vlan IP address to the loopback 1 interface and then assign another open IP address in the same subnet to the voice vlan interface. I hope this helps.

Thanks,

Matt

0 Kudos
Anonymous
Not applicable

Re: How to bind SIP trunks to a specific VLAN interface IP

Jump to solution

Here is a good reference for the media-gateway ip command that I forgot to link in my last reply:

Configuring IP Interfaces for SIP in AOS IPBGs

Thanks,

Matt

bascheew
New Contributor II

Re: How to bind SIP trunks to a specific VLAN interface IP

Jump to solution

Thank you Matt, this is very informative.  Before receiving your answer I tested using a loopback interface and then all the phones unregistered.  Your explanation clears up why that happened!  I think going forward on new installs we will setup a loopback interface from the start and use that for everything, and if we ever need it to be sourced from the egress interface we'll use "ip primary" on a case by case basis.