Bug 241563 - pf: altq Adaptive RED (Random Early Detection) queuing support
Summary: pf: altq Adaptive RED (Random Early Detection) queuing support
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-pf mailing list
URL:
Keywords: feature, needs-qa
Depends on:
Blocks:
 
Reported: 2019-10-29 04:56 UTC by Archit Pandey
Modified: 2019-10-30 01:42 UTC (History)
2 users (show)

See Also:
koobs: mfc-stable12?


Attachments
ared.diff (5.58 KB, patch)
2019-10-29 04:56 UTC, Archit Pandey
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Archit Pandey 2019-10-29 04:56:57 UTC
Created attachment 208668 [details]
ared.diff

FreeBSD's PF firewall allows traffic shaping using Random Early Detection (RED). RED helps keep the average size of the queues low and allow occasional bursts of packets through the queue.

Adaptive RED (ARED) was proposed by Floyd et. al. [1] as an enhancement over RED. ARED solves most of the issues faced by RED with minimal changes and leaves its basic idea intact. The ARED algorithm regularly adapts the value of the maximum dropping probability and ensures that the queue length stays within the targeted range.

This patch implements ARED in PF ALTQ. It can be enabled by compiling the kernel with option ALTQ_ADAPTIVE_RED. The patch has been tested on FreeBSD-12.0-RELEASE. The results obtained from applying the patch have been included in our paper "Adaptive RED for FreeBSD: Design, Implementation and Challenges", recently presented at TENCON 2019.

[1] https://www.icir.org/floyd/papers/early.twocolumn.pdf

Authors:
Archit Pandey <architpandeynitk@gmail.com>
Mohit P Tahiliani <tahiliani@nitk.ac.in>
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2019-10-29 05:03:32 UTC
Thank you for the report and feature patch Archit/Mohit

If required, a patch against CURRENT would be appreciated as it will need to land in head first
Comment 2 Kubilay Kocak freebsd_committer freebsd_triage 2019-10-29 05:09:02 UTC
Will also need to be added to altq(4) manual page
Comment 3 Archit Pandey 2019-10-29 06:29:35 UTC
Hello Kubilay Kocak,

Thanks for editing the bug as required.

> If required, a patch against CURRENT would be appreciated as it will need to 
> land in head first

I created the patch against FreeBSD git repository (https://github.com/freebsd/freebsd). I believe the git repo tracks CURRENT on its master. My bad for not mentioning in the initial comment.

> Will also need to be added to altq(4) manual page

I'll work on this and update the diff file. Thank you for pointing out!