Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

packets not matching pf rule?



hey guys, I have no idea what i'm doing wrong, but it seems ssh packets are not going into their allocated altq queue. this is what i have

altq on hme0 cbq bandwidth 512Kb queue { dns, ssh, ack_out, def }
        queue dns     on hme0 bandwidth 64Kb  priority 7 cbq(borrow ecn)
        queue ssh     on hme0 bandwidth 64Kb  priority 7 cbq(borrow ecn)
        queue ack_out on hme0 bandwidth 128Kb priority 6 cbq(borrow ecn)
queue def on hme0 bandwidth 256Kb priority 0 cbq(borrow default)

#nat on hme0 from 192.168.1.0/24 to ! 192.168.0.0/16 -> 192.168.1.2

pass out on hme0 from any to any queue (def, ack_out)
pass out quick on hme0 proto tcp from any port 22 to any queue (def,ssh)
pass out quick on hme0 proto udp from any to any port 53 queue dns

--

and it seems everything is matching just fine other than ssh after 'pfctl -f /etc/pf.conf' and then 'watch --interval=1 pfctl -s queue -v' and then sending a few pings, resolving some hostnames and logging into my ssh server from a remote host on the internet.

Every 1.0s: pfctl -s queue -v
 Mon Feb 15 16:52:56 2010

queue root_hme0 on hme0 bandwidth 512Kb priority 0 cbq( wrr root ) {dns, ssh, ack_out, def} [ pkts: 413 bytes: 67459 dropped pkts: 0 bytes: 0 ]
  [ qlength:   0/ 50  borrows:      0  suspends:      0 ]
queue  dns on hme0 bandwidth 64Kb priority 7 cbq( red ecn borrow )
[ pkts: 5 bytes: 375 dropped pkts: 0 bytes: 0 ]
  [ qlength:   0/ 50  borrows:      0  suspends:      0 ]
queue  ssh on hme0 bandwidth 64Kb priority 7 cbq( red ecn borrow )
[ pkts: 0 bytes: 0 dropped pkts: 0 bytes: 0 ]
  [ qlength:   0/ 50  borrows:      0  suspends:      0 ]
queue  ack_out on hme0 bandwidth 128Kb priority 6 cbq( red ecn borrow )
[ pkts: 11 bytes: 1110 dropped pkts: 0 bytes: 0 ]
  [ qlength:   0/ 50  borrows:      0  suspends:      0 ]
queue  def on hme0 bandwidth 256Kb priority 0 cbq( borrow default )
[ pkts: 397 bytes: 65974 dropped pkts: 0 bytes: 0 ]
  [ qlength:   0/ 50  borrows:      0  suspends:      0 ]

---

maybe it's obvious, i don't know, but i've munked with it and reconfigured pf from pf.conf quite a few times. at first i was not using two queues for it and just had an ssh queue like:
pass out quick on hme0 proto tcp from any port 22 to any queue ssh

that was not matching either
i can do it with altqd just fine though.

n0ah
netbsd/sparc64 fan




Home | Main Index | Thread Index | Old Index