Hi Stuart and the others,
> > pass out queue (std_out,lowdelay)
>
> here, you place ACKs from downloads at a higher priority than
> your voip calls. this is unlikely to be what you want with priq
> over a 140Kb/s link..
>
> there are some other things you could look at too but changing
> this would be a good place to start.
I decided to simplify the ruleset and queue setup following the
advices. I know have:
ext_if="fxp0"
int_if="vr0"
lan_net=$int_if:network
icmp_types="echoreq"
voipservers = "{ 200.184.77.145, 200.184.77.138 } "
atas = "{ 192.168.2.33, 192.168.2.100 }"
set skip on lo
set loginterface $ext_if
scrub in
altq on $ext_if priq bandwidth 130Kb queue {std_out, voip_out}
queue std_out priority 4 priq(default)
queue voip_out priority 11
altq on $int_if priq bandwidth 130Kb queue {std_in, voip_in}
queue std_in priority 4 priq (default)
queue voip_in priority 11
nat-anchor "ftp-proxy/*"
rdr-anchor "ftp-proxy/*"
nat on $ext_if from !($ext_if) -> ($ext_if:0)
rdr pass on $int_if proto tcp to port ftp -> 127.0.0.1 port 8021
anchor "ftp-proxy/*"
block in log
pass in quick on $int_if from $atas flags any keep state \
queue voip_in
pass out quick on $int_if to $atas flags any queue voip_in
pass out
pass in on $int_if from $int_if:network
pass out on $int_if from any to $int_if:network
# icmp
pass in inet proto icmp all icmp-type $icmp_types keep state
pass out on $ext_if inet proto udp from any to $voipservers \
queue voip_out keep state
When I start the voip call, as I said, the quality is quite
good indeed. A printscreen of the queues states is below:
queue std_out on fxp0 priority 4 priq( default )
[ pkts: 9895 bytes: 1284164 dropped pkts: 0 ...0 ]
[ qlength: 0/ 50 ]
[ measured: 0.1 packets/s, 58.40 b/s ]
queue voip_out on fxp0 priority 11
[ pkts: 18075 bytes: 1511111 dropped pkts: 0 ...0 ]
[ qlength: 0/ 50 ]
[ measured: 33.4 packets/s, 20.84Kb/s ]
queue std_in on vr0 priority 4 priq( default )
[ pkts: 14651 bytes: 16896830 dropped pkts: 37 ...18893 ]
[ qlength: 0/ 50 ]
[ measured: 3.4 packets/s, 3.96Kb/s ]
queue voip_in on vr0 priority 11
[ pkts: 14880 bytes: 1107273 dropped pkts: 0 ...0 ]
[ qlength: 0/ 50 ]
[ measured: 33.5 packets/s, 19.84Kb/s ]
The only traffic going through the std_in queue at this time is
the ssh traffic is the output of 'pfctl -vvsq'
Now when I start a download, the quality of the voip call is
immediately affected (gets worse). Just a while later, the queues
states show this:
queue std_out on fxp0 priority 4 priq( default )
[ pkts: 10807 bytes: 1349808 dropped pkts: 0 ... 0 ]
[ qlength: 0/ 50 ]
[ measured: 5.4 packets/s, 2.46Kb/s ]
queue voip_out on fxp0 priority 11
[ pkts: 24608 bytes: 2020685 dropped pkts: 0 ... 0 ]
[ qlength: 0/ 50 ]
[ measured: 33.4 packets/s, 20.84Kb/s ]
queue std_in on vr0 priority 4 priq( default )
[ pkts: 16707 bytes: 19142071 dropped pkts: 37 ... 18893 ]
[ qlength: 0/ 50 ]
[ measured: 12.2 packets/s, 109.24Kb/s ]
queue voip_in on vr0 priority 11
[ pkts: 20151 bytes: 1497327 dropped pkts: 0 ... 0 ]
[ qlength: 0/ 50 ]
[ measured: 25.8 packets/s, 15.29Kb/s ]
We see that the traffic going out through the voip_in queue went
down from 19.84 Kbps to 15.29Kbps.
The ATA is configured to use the G729a codec.
An hint or suggestion will be greatly appreciated.
Regards,
Jeff.
--
Want an e-mail address like mine?
Get a free e-mail account today at www.mail.com!