Page 1 of 1

Problems mangeling voip-traffic

Posted: Sun Feb 26, 2017 11:07 pm
by horstkevin
Hi there,

the situation:
German Telekom ADSL-Connection via Mikrotik RB750Gr3 with PPPoE (modem draytek vigor 130)
connection: Upload: round about 500kbit/s, Download: 6.000kbit/s.
Voip-Telephone using Audio Codec 711
SIP-Port 5060-5076
RTP-Port: 5004-5020

Setup:
Mikrotik:
ether1 = Internet-Gateway via PPPoE
ether2 = LAN 192.168.10.0/24
ether5 = Separate subnet for voip-devices 192.168.11.0/24, VoIP-telephone directly connected with IP 192.168.11.2
NAT enabled. Maybe STUN in use ?!
The telephone works fine.

Because the internet connection has not a very high bandwidth i want to priorize voip-connection.
For this i want to mark the voip-packets first, before priorizing it in a queue.
voip1.jpg
Beginning from the bottom the second line shows the voip-data-transfer. It's about 85kbit/s and 50 packets/s.
I wonder why there's no traffic like that in the LAN, going from and to IP 192.168.11.2.

So I tried to mark all udp-packets of the voip-port-range as you can see here:
voip2.jpg
voip3.jpg
But almost no packets are marked, only a very few like 1 or 2 after some seconds.
I also tried to mangle all UDP-packets with incoming interface ether5 (for testing purposes only), but this doesnt work either.

Can you tell me where's the mistake? Is it because of STUN?
What is the right chain to mangle: prerouting or forward? Or doesn't it matter in this case?

Regards,
horstkevin

Re: Problems mangeling voip-traffic

Posted: Mon Feb 27, 2017 6:50 pm
by scotthammersley
Would need to see the full configuration of the mangle tree and queue configuration. I would suggest marking the connections first based on the applicable source and destination IP's/ports. Once you have the connections marked correctly in the list, you then mark the packets based on those connections. Could probably help you better with some more of your configuration.

Re: Problems mangeling voip-traffic

Posted: Mon Feb 27, 2017 7:46 pm
by pe1chl
Unless your phone is very broken I suggest not using mangling by port number but use the DSCP as the selection for the priority.
(as I have explained in other threads about QoS)
Also make sure you use Queue tree, not simple Queue. Or you have to turn off Fasttrack.