Project

General

Profile

Actions

Bug #731

closed

Shaper: p2p catch all bandwidth allows various selections but only % usable

Added by Josh Stompro over 14 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Traffic Shaper (ALTQ)
Target version:
-
Start date:
07/12/2010
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
2.0
Affected Architecture:

Description

Brief description: When setting the amount of bandwidth that can be used in the traffic shaper wizard, peer to peer networking, p2p catch all section, the drop down box to select how the bandwidth is expresses allows the user to select %, bit/s, kilobit/s, megabit/s, gigabit/s. But if anything other than % is selected, the wizard returns the error "Only percentage bandwidth specification is allowed" For the best user experience all the unusable types should be removed and only % should remain.

Tested on 2.0-BETA3 Sun Jul 11 23:57:27 EDT 2010 Nanobsd 2G

Steps to reproduce:
  1. Firewall->Traffic Shaper
  2. Wizards Tab
  3. traffic_shaper_wizard_multi_lan.xml
  4. Number of LAN Type Connections: Enter 5, Next.
  5. connupload: 650 Kbit/s, conndownload: 2200 Kbit/s, select 5 lan interfaces, click next.
  6. Don't change anything on VOIP page, click next.
  7. Don't change anything on Penalty box page, click next.
  8. Unchecks and check enable on Peer to Peer networking page so check boxes get enabled(another bug)
  9. Check p2pCatchAll:
  10. Enter amount of bandwidth for p2p Catch All in Kbit/s and change % to Kbit/s
  11. Check box next to bittorrent.
  12. Click next.
  13. Error is displayed: Only percentage bandwidth specification is allowed.

ermal asked that this bug be opened in this form post.
http://forum.pfsense.org/index.php/topic,26195.msg136384.html#msg136384


Files

pfsense-traffic-shaping-wizard.jpg (117 KB) pfsense-traffic-shaping-wizard.jpg screenshot of traffic wizard example Grioghar Thomas-Baldwin, 02/12/2023 01:56 AM
Actions #1

Updated by Chris Buechler about 10 years ago

  • Status changed from New to Resolved
Actions #2

Updated by Grioghar Thomas-Baldwin almost 2 years ago

This claims to be resolved over 8 years ago, however at this moment I'm getting this error.

In the source in function step4_stepsubmitphpaction(): https://github.com/pfsense/pfsense/blob/master/src/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc#L632

The only options allowed are "%" for bandwidthspeed, and between 2-15% for a value.

function step4_stepsubmitphpaction() {
    global $config;
    global $stepid, $savemsg;

    if ( $_POST['enable'] ) {
        if (!$_POST['bandwidth']) {
            $savemsg="A value for bandwidth must be specified.";

            $stepid--;
            return;
        }
        if (!is_numeric($_POST['bandwidth'])) {
            $savemsg="The posted value is not a valid bandwidth.";
            $stepid--;
            return;
        }
        if ($_POST['bandwidthspeed'] <> *"%"* ) {
            $savemsg = gettext("Only percentage bandwidth specification is allowed.");
            $stepid--;
            return;
        }
        $bw = $_POST['bandwidth'];
        if ( *$bw > 15 || $bw < 2* ) {
            $savemsg="Values should be between 2% and 15%!";
            $stepid--;
            return;
        }
        if ($_POST['address'] <> "" && !is_ipaddroralias($_POST['address'])) {
            /* item is not an ip or alias.  error out */
            $savemsg=gettext("Address must be a valid IP address or Firewall Alias.  Please correct this value to continue.");
            $stepid--;
        }
    }
}

However, the dropdown for percentage also allows for bits/Kilobits/Megabits/Gigabits:

screenshot of traffic wizard example

I also don't see in any rules or queue configuration where 2-15% is ever set, instead simply putting the penalty box with the lowest queue ID.

I would very much like to declare the configuration to use 50-75% of total bandwidth, or explicitly declare speed. This appears to not allow for this at all.

In the documentation at https://docs.netgate.com/pfsense/en/latest/recipes/traffic-shaper-altq-wizard.html#penalty-box , this appears to be implied that the functionality is there, not making explicit declaration that 2-15% is the only option.

Please advise.

Thanks!

Actions

Also available in: Atom PDF