Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Dynamic speed limiting, based on total usage?

    Scheduled Pinned Locked Moved Traffic Shaping
    2 Posts 2 Posters 713 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      Javik
      last edited by

      Is there some way to have pfSense do dynamic speed adjustment of limiters, to adjust the limits up and down depending on current total bandwidth usage?

      Let's say we have a 100 megabit Internet connection.

      There will be four levels of management:

      • Rapid-change high limit (RCHL): 95 megabit
      • Rapid-change low limit (RCLL): 45 megabit
      • Slow-change high limit (SCHL): 90 megabit
      • Slow-change low limit (SCLL): 50 megabit

      Rate of change settings:

      • Rapid-change in speed (RCS): 5 megabit
      • Slow-change in speed (SCS): 0.5 megabit

      Limiter hard limits:

      • Limiter Minimum speed (LMIN): 0.5 megabit
      • Limiter Maximum speed (LMAX): 50 megabit

      Limiter-Speed is initialized set to LMAX.

      Every 2 seconds, adjust the limiters:

      • Get total interface utilization (TIU) of WAN interface

      Rapid changes to limiter:

      • If TIU => RCHL, decrease Limiter-Speed by RCS (5 megabit)
      • If TIU =< RCLL, increase Limiter-Speed by RCS (5 megabit)

      Slow changes to limiter:

      • If TIU < RCHL and TIU > SCHL, decrease Limiter-Speed by SCS (0.5 megabit)
      • If TIU < SCLL and TIU > RCLL, increase Limiter-Speed by SCS (0.5 megabit)

      Correct too high or too low speed changes:

      • If Limiter-Speed < LMIN, set Limiter-Speed to LMIN
      • If Limiter-Speed > LMAX, set Limiter-Speed to LMAX

      ,

      The result of doing this, is that this allows overall device speeds to increase when the Internet usage is low, and pfSense would only impose a speed restriction on the devices as the Internet usage rises.

      The rapid-change section allows the limiter to aggressively respond to sudden spikes or drops in demand.

      1 Reply Last reply Reply Quote 0
      • G
        Gatekeeper-ZA
        last edited by

        This would be great am searching for something like this myself you can do it with schedulers though but its not dynamic.
        my service has exact times when congestion occurs or the isp starts their throttling so its quite easy to do it this way.

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.