Configure Routed IPTV on your UBNT EdgeMax or USG

Intro

I never used the FritzBox that XS4All uses at consumers for there Internet/IPTV/VoIP bundle, instead I used the EdgeMax Pro 8 with a EdgeSwitch 16 150W. This worked very well for some years but then I did hear/read on a blog/forum that they switched to Routed IPTV instead of the Bridged IPTV that I still was using.

So did search some on the internet how to reconfigure my EdgeMax Pro 8 to Routed IPTV. Found on the UBNT forum a threat about what people did try to get it working. So spend also a evening trying some configurations.

So I was thinking why not make a blog about it, so I can find it always back and help other people also with it.

So what is difference between Bridged IPTV and Routed IPTV

With Bridged IPTV you make a bridge group on you router and assign ports to this bridge group, so the SetupBox is directly connected to the IPTV network. With Routed IPTV you route the traffic from your LAN to the IPTV network of your IPTV provider.

So with Bridge IPTV Configuration the Set-Top Box (STB) was connected to the EdgeMax Pro directly, so on eth3 that was a member of the bridge group, and VIF on eth1.4 was also a member of the bridge group.

With Routed IPTV the Set-Top Box (STB) is connected to my EdgeSwitch 16 150W, this makes it also more easy to connect more SetupBoxes in different places in the house.

Why are providers like KPN and XS4All choosing Routed IPTV, this is because to support services like Netflix that use the internet.

Overview of hardware setup

So I was thinking lets make a drawing how the hardware is set-up.

Step-By-Step Configuration

Setup routed IPTV

configure

set interfaces ethernet eth1 hdcp-options default-route "no-update"
set interfaces ethernet eth1 hdcp-options default-route-distance 1
set interfaces ethernet eth1 hdcp-options name-server "no-update"

set interfaces ethernet eth1 vif 4 address "dhcp"
set interfaces ethernet eth1 vif 4 description "WAN - IPTV"
set interfaces ethernet eth1 vif 4 dhcp-options client-option "send vendor-class-identifier "IPTV_RG";"
set interfaces ethernet eth1 vif 4 dhcp-options client-option "request subnet-mask, routers, rfc3442-classless-static-routes;"

set interfaces ethernet eth1 vif 4 dhcp-options default-route "no-update"
set interfaces ethernet eth1 vif 4 dhcp-options default-route-distance "210"
set interfaces ethernet eth1 vif 4 dhcp-options name-server "no-update"
set interfaces ethernet eth1 vif 4 ip source-validation "loose"

commit
save
exit

Modify our DHCP configuration to include IPTV parameters

configure

set service dhcp-server global-parameters "option vendor-class-identifier code 60 = string;"
set service dhcp-server global-parameters "option broadcast-address code 28 = ip-address;"

commit
save
exit

NAT rules are required for the IPTV Set-Top Box (STB) to connect to the IPTV platform

The following commands will return 2 configuration lines required.

sudo su
r_ip=$(show dhcp client leases | grep router | awk '{ print $3 }');
iptv_static=$(echo "set protocols static route 213.75.112.0/21 next-hop $r_ip")
echo -e "$iptv_static"
exit

copy output to text file

configure

set service nat rule 5001 description "MASQ corporate_network to IPTV network"
set service nat rule 5001 log disable
set service nat rule 5001 outbound-interface eth1.4
set service nat rule 5001 protocols all
set service nat rule 5001 destination address 213.75.112.0/21
set service nat rule 5001 type masquerade

(YOUR SET LINE FOR STATIC ROUTE, received from previous step) Copy the line from the text file and paste it here. 

So will look like understanding:

set protocols static route 213.75.112.0/21 next-hop [IP ADDRESS IPTV Router]

commit
save
exit

Setup the IGMP Proxy

configure

set protocols igmp-proxy interface eth1.4 alt-subnet 0.0.0.0/0
set protocols igmp-proxy interface eth1.4 role upstream
set protocols igmp-proxy interface eth1.4 threshold 1

set protocols igmp-proxy interface eth7 alt-subnet 0.0.0.0/24
set protocols igmp-proxy interface eth7 role downstream
set protocols igmp-proxy interface eth7 threshold 1

commit
save
exit

Conclusion

I switched my Set-Top Box (STB) off and on, it connected to the IPTV router and downloaded new software and I could look again IPTV on my Set-Top Box (STB).

Here are some links with more information.

Netwerkje.com explaining very nicely difference between Bridged vs Routed (Dutch)

UBTN Forum with thread about configurations for USG also

XS4All Configuration other modems

comments powered by Disqus