Answer the question
In order to leave comments, you need to log in
Is it possible to prioritize VoIP on a linux router?
Hi all!
There is a working network, quite simply arranged - several PCs, and several IP phones. All this is connected through simple SOHO switches to a router, which is a regular PC with linux (CentOS 6.7).
One interface looks to the network, the other directly to the Internet. Has an external routable address. It is also a phone server (asterisk 1.8). The Internet tariff is extremely small - 3Mbps.
Sometimes, accordingly, strange things happen to the voice, especially at the time of network loading.
Question: is it possible to set up prioritization of traffic from asterisk to the VoIP provider in this case? And, accordingly, coming from him.
What methods can be implemented, through tc somehow, or other ways?
How, in general, in theory, should this work?
Do you need to mark traffic in asterisk itself (ToS), or through iptables, or not mark at all, but do a selection by ports and IP, for example?
And further, is it all put in some kind of priority queue, or can you just allocate a guaranteed bandwidth for VoIP?
And, in general, will it work in principle? Or do I need to buy something more sharpened?
Answer the question
In order to leave comments, you need to log in
You need to mark traffic in asterisk itself (ToS), or through iptables,
$IPTABLES -A OUTPUT -t mangle -p udp -m udp --dport 5060 -j DSCP --set-dscp-class cs3 # SIP
$IPTABLES -A OUTPUT -t mangle -p tcp -m tcp --dport 5060 -j DSCP --set-dscp-class cs3 #SIP
$IPTABLES -A OUTPUT -t mangle -p udp -m udp --sport 10000:20000 -j DSCP --set-dscp-class ef # RTP
It is real to set up marking of packages using asterisk. Even sending marked packets to the provider is also real, but ... The provider will cut off all your traffic markings with the very first managed switch.
The best option when your entire channel is clogged is to make queues by traffic and by the user - this is done quite easily. www.awsswa.livejournal.com/10551.html
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question