Traffic Shaping Download on Multi Wan

  • Hi,

    My traffic Shaper is now working great for 1 WAN Connection…
    Therefore I continued the Setup of Second WAN. Now I have stable DSL Connection with 14/1 Speed and additional LTE Line with 30/5 Speed.

    The Download Speed Shaper is now affecting both Wans. Let's say surfing the Internet will balance on both Wans, but when the Limit is reached for setup in the Shaper it will slow down both Wans.

    Is there any way to shape both Wan Download Streams separatly to use both at their speedlimits?
    Based on other Articles this seems to be impossible. Is this still true with latest Version?

    This would make Shaping almost senseless on Multi-Wan Environment.
    The only workaround what i could currently see, is to manually split all Connections and send them into different Queues...

    Thanks for helping!

  • Shaping is per interface, so if you have two WANs feeding into the same LAN, you have a single LAN interface that has no idea about the two WANs.

    I haven't tried this, but in theory, if you create two separate queues on your LAN, then create a set of floating rules that trigger on new outgoing states on the WAN, you could put that connection in the correct LAN queue.


    Float Rule on WAN1 interface: put in qWAN1
    Float rule on WAN2 interface: put in qWAN2

    LAN qWAN1, qWAN2

    Then set your bandwidth on each qWAN that's appropriate for the corresponding WAN bandwidth.

  • Hi Harvy,

    I've tried your great Idea, however I've failed so far  :( …

    The Problem seems that the floating Rule must be pointing to the LAN Interface with Source IP set to the internal PC.

    As soon as i select a WAN Interface within the floating Rule, the traffic is not going to any Shaper Rule at all and qDefault is used.

    The outcome should be something like specific PC can use a Download Rate of 50% on Wan1 and 30% of WAN2


  • Are you trying to match connections coming in or going out?

    What i envisioned was something like this, in case this wasn't conveyed earlier. Lets say both WAN1 and WAN2 are both 10Mb/1Mb.

    qWAN1 - 1Mb

    qWAN2 - 1Mb

    qWAN1 - 10Mb
    qWAN2 - 10Mb

    WAN1 interface on BOTH directions - put all traffic in qWAN1
    WAN2 interface on BOTH directions - put all traffic in qWAN2

    On the WAN interfaces, you can probably just use FairQ as the scheduler unless you need to do real traffic shaping, then HFSC. But on the LAN, you may need to use HFSC and set the upper limit for both queues to be 10Mb.

  • Hi again,

    Thanks for pointing out the floating Rule again.

    So, Screenshot shows Rule as currently setup for Incoming/Outgoing Queue (2 Rules: 1 Time Source IP entered, 1 Time Destination IP entered).
    I was using Ackqueue/Queue as this was initially used by the Wizard already.

    So did i got you correctly that this is wrong and i should use In/Out Setting instead?

    Bye Markus

  • Actually, I am not familiar with the In/Out setting, I was thinking about "Direction" and being "Any", not "Both" like I stated earlier. Just set that rule to the WAN, not the LAN. The rule will only trigger on the WAN, but should assign both the In and Out state to the same queue, assuming the exact same named queue exists on both interfaces.

  • I swear there is a cool club of people who know how to fairly shape multi-wan traffic in a straightforward method. There must be some sort of standard practice that pfSense supports without needing work-arounds. This capability seems too fundamental to get zero developmen interest. /pseudorant

    I must be missing something here…

    The method I read about involved two (virtual?) pfSense setup's, the perimeter doing vlan traffic-shaping, and the 2nd doing routing of the shaped VLANs.

    I have not tried it myself.

  • Hmm,

    Somehow i don't get it… There must be a way of setting this up...
    Not my first Router with QoS, but seems like i'm too stupid  :-[

    I've tried a lot with floating Rules today.
    The only way to get the download shaped is by selecting Lan Interface and Local IP Address as Source.
    As soon as a WAN Interface is selected only Upload or outbound Traffic is shaped.

    Furthermore i have compared the HFSC Shaper to CBQ. CBQ seems to be more performant than HFSC. On HFSC it seems that around 10% of Uplink Speed get lost.
    So I've changed everything now to CBQ.

    CBQ has also different behavior on Uplink than on Downlink. On Download it will NEVER use the Borrow Function. I guess because the Root Queue on Lan Interface is always showing full usage even on a Idle Line.
    Do i have another Configuration mistake here or is this a bug? I've attached a screenshot with around 50% of load.

    On the Uplink Function it seems like it is never using the Bandwidth Parameter. Doesn't matter to which Value i set it, it will borrow everything until Latency goes up.
    If it would behave the same like on Download it would never exeed it's Bandwith Parameter.
    Another mistake?


  • Just asking myself if a Priority Queue might be enough for downloading. This might work even with Multi Wan….

  • Are your floating rules applied to both WAN interfaces?

    A priority queue can be dangerous if you ever have a higher priority flow that consumes a lot of bandwidth and completely kills a lower priority flow.

  • Hi Harvy,

    If applied to both WAN Interfaces, both WAN Queues are working for Upload. –> This should be OK.
    Currently, i'm not load balancing because i'm afraid for overloading 1 of the Download Lines.

    I want to shape the Download, and this seems to only work when the LAN Interface is selected in floating Rule.

Log in to reply