https://redmine.pfsense.org/https://redmine.pfsense.org/favicon.ico?16780521162020-09-09T22:18:35ZpfSense bugtrackerpfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=476832020-09-09T22:18:35Z→ luckman212luke.hamburg@gmail.com
<ul></ul><p>I notice <a class="issue tracker-1 status-11 priority-4 priority-default closed" title="Bug: Double Traffic Graph (Duplicate)" href="https://redmine.pfsense.org/issues/10852">#10852</a> also seems to be the same issue.</p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=476972020-09-10T12:06:48ZJim Pingle
<ul><li><strong>Target version</strong> set to <i>2.5.0</i></li></ul> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=483842020-10-06T09:33:29ZAnonymous
<ul><li><strong>Assignee</strong> set to <i>Jim Pingle</i></li></ul> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=483862020-10-06T09:38:12ZJim Pingle
<ul><li><strong>Subject</strong> changed from <i>Reopen - Traffic graph shows 2X the actual traffic on VLAN interfaces.</i> to <i>Traffic graph shows 2X the actual traffic on VLAN interfaces.</i></li><li><strong>Assignee</strong> changed from <i>Jim Pingle</i> to <i>Renato Botelho</i></li></ul><p>Last time this came up it was due to VLAN traffic counting twice on the parent. In <a class="external" href="https://redmine.pfsense.org/issues/3314#note-21">https://redmine.pfsense.org/issues/3314#note-21</a> it was Renato that added the patch (or noted it was added, at least). Might be one we need to track down and reapply after the last stable merge.</p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=489602020-10-23T16:42:07ZMarcos M
<ul></ul><p>Jim Pingle wrote:</p>
<blockquote>
<p>Last time this came up it was due to VLAN traffic counting twice on the parent. In <a class="external" href="https://redmine.pfsense.org/issues/3314#note-21">https://redmine.pfsense.org/issues/3314#note-21</a> it was Renato that added the patch (or noted it was added, at least). Might be one we need to track down and reapply after the last stable merge.</p>
</blockquote>
<p>Looked at commits during that time, but no luck finding it:<br /><a class="external" href="https://redmine.pfsense.org/projects/pfsense/repository/revisions?page=637">https://redmine.pfsense.org/projects/pfsense/repository/revisions?page=637</a></p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=490012020-10-26T12:29:11ZRenato Botelhorenato@netgate.com
<ul><li><strong>Assignee</strong> changed from <i>Renato Botelho</i> to <i>Luiz Souza</i></li></ul><p>Luiz enabled ALTQ on if_vlan.c few time before this ticket was opened. He is going to check if his commit re-introduced this issue</p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=490022020-10-26T13:18:01ZRenato Botelhorenato@netgate.com
<ul></ul><p>It regressed before as we can see on <a class="issue tracker-1 status-3 priority-4 priority-default closed" title="Bug: Duplicated traffic graphs (Resolved)" href="https://redmine.pfsense.org/issues/7751">#7751</a> and fix was committed to 2.4.4 branch on FreeBSD-src</p>
<pre>
commit 327d0a44358
Author: Luiz Souza <luiz@netgate.com>
Date: Thu Aug 17 23:31:03 2017 -0500
Fix the counter values for VLAN interfaces. The packet bytes are already counted in IFQ_HANDOFF().
Ticket #7751
diff --git a/sys/net/if_vlan.c b/sys/net/if_vlan.c
index e50b3ddebba..8ccd9c44453 100644
--- a/sys/net/if_vlan.c
+++ b/sys/net/if_vlan.c
@@ -1136,12 +1136,8 @@ vlan_start(struct ifnet *ifp)
* Send it, precisely as ether_output() would have.
*/
error = (p->if_transmit)(p, m);
- if (error == 0) {
- if_inc_counter(ifp, IFCOUNTER_OPACKETS, 1);
- if_inc_counter(ifp, IFCOUNTER_OBYTES, len);
- if_inc_counter(ifp, IFCOUNTER_OMCASTS, mcast);
- } else
- if_inc_counter(ifp, IFCOUNTER_OERRORS, 1);
+ if_inc_counter(ifp,
+ (error == 0) ? IFCOUNTER_OPACKETS : IFCOUNTER_OERRORS, 1);
}
}
</pre> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=491282020-11-02T06:32:08ZLuiz Souzaluiz@netgate.com
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Feedback</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul><p>Fix committed.</p>
<p>The fix is a bit different with the new code.</p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=491312020-11-02T07:03:25ZRenato Botelhorenato@netgate.com
<ul></ul><p>Fixed by commit 2841d41b090 on branch devel-12 of FreeBSD-src repository</p> pfSense - Bug #10812: Traffic graph shows 2X the actual traffic on VLAN interfaces.https://redmine.pfsense.org/issues/10812?journal_id=494922020-11-14T11:22:24ZDanilo Zrenjanin
<ul><li><strong>Status</strong> changed from <i>Feedback</i> to <i>Resolved</i></li></ul><p>Tested on :<br /><pre>
2.5.0-DEVELOPMENT (amd64)
built on Sat Nov 14 07:01:37 EST 2020
FreeBSD 12.2-STABLE
</pre></p>
<p>The Traffic graph shows correct values for vlan interfaces. Ticket resolved.</p>