Bug 270687 - Net/mpd5 version 5.9_14 exhibits a bug where certain websites fail to load.
Summary: Net/mpd5 version 5.9_14 exhibits a bug where certain websites fail to load.
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Eugene Grosbein
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-07 13:45 UTC by Zsolt
Modified: 2023-05-05 21:51 UTC (History)
1 user (show)

See Also:
eugen: maintainer-feedback+


Attachments
my working mpd.conf (940 bytes, text/plain)
2023-04-07 13:45 UTC, Zsolt
no flags Details
tail -f daemon.log | grep mpd (21.89 KB, text/plain)
2023-05-05 07:21 UTC, fbsdbugs
no flags Details
mtu1500 (24.41 KB, text/plain)
2023-05-05 07:40 UTC, fbsdbugs
no flags Details
proposed fix (2.10 KB, patch)
2023-05-05 18:35 UTC, Eugene Grosbein
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Zsolt 2023-04-07 13:45:12 UTC
Created attachment 241339 [details]
my working mpd.conf

Hello,

I recently updated from version 5.9_13 to 5.9_14 of the net/mpd5, and I encountered an issue where some websites would not load. Specifically, I had problems accessing duckduckgo.com, index.hu, and digi24.ro. To resolve this, I had to revert to version 5.9_13.

I have included my mpd5 configuration file for reference.

Thank you,
Zsolt
Comment 1 fbsdbugs 2023-05-04 21:31:05 UTC
Hi,

same ISP, same problem here.

First I played a bit with `iface mtu` and/or `max-payload` in mpd.conf, that didn't help, but I'm not sure exactly what values I tried, some variations of 1492 and 1500.

Then I reverted just the `#define PPPOE_MTU` (back to 1492) in `patch-max-payload` and that fixed it, now it works as before.

If you want, I can do some debugging, but you'll need to guide me, I don't really know what I'm doing (I just read the changelog _13 -> _14 and guessed).

Best regards,
rrveex
Comment 2 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 05:01:28 UTC
Please show output of ifconfig command for your PPPoE interface with working and non-working version of mpd5.
Comment 3 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 05:02:35 UTC
(In reply to fbsdbugs from comment #1)

Also, please post your mpd.conf
Comment 4 fbsdbugs 2023-05-05 07:04:41 UTC
Ok, must have had a typo last night as I played with the conf.

Setting `iface mtu` to 1492 does indeed fix the problem with the unmodified _14.

_14 with `set iface mtu 1492` or _13 or my_modified_14 w/o any mtu setting in .conf:

tun0: flags=88d1<UP,POINTOPOINT,RUNNING,NOARP,SIMPLEX,MULTICAST> metric 0 mtu 1492

_14 w/o setting any mtu in .conf:

tun0: flags=88d1<UP,POINTOPOINT,RUNNING,NOARP,SIMPLEX,MULTICAST> metric 0 mtu 1500


create bundle static B1
set bundle enable ipv6cp
set iface name tun0
set iface route default
set iface enable tcpmssfix

set iface disable on-demand
set iface idle 0

set iface mtu 1492 # <-----

create link static L1 pppoe
set link action bundle B1 
set link disable multilink
set link disable chap pap
set link accept pap  
set link max-redial 0    
set link keep-alive 10 60
set pppoe iface igc3
set pppoe service ""
set auth authname [...]
open
Comment 5 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 07:11:18 UTC
Please add the following command to the "startup" section of mpd.conf:

log +auth +bund +iface +iface2 +lcp +lcp2 +link

Use unmodified 5.9_14, make PPPoE connection and post mpd.log
Comment 6 fbsdbugs 2023-05-05 07:21:44 UTC
Created attachment 241987 [details]
tail -f daemon.log | grep mpd

This is original _14, still with mtu 1492 in settings.

I couldn't find any mpd.log, grep-ed it out of daemon.log while restarting mpd5 service.

Please note I have 2 lines, same provider, settings, etc.
Comment 7 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 07:37:29 UTC
Supplied log is fine too. Now I need the log for unmodified 5.9_14 and configuration with any "mtu" settings commented out/removed.
Comment 8 fbsdbugs 2023-05-05 07:40:14 UTC
Created attachment 241988 [details]
mtu1500

Here you go
Comment 9 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 08:39:34 UTC
The problem is that your provider does not specify right MTU size for its side of the link. So, your work-around is right, specify mtu 1492 in mpd.conf.

I will post a patch that restores compatibility by default and eliminates need for work-around a bit later.
Comment 10 Zsolt 2023-05-05 14:43:20 UTC
"set link mtu 1492" that fixed also at my side!

Thanks,
Comment 11 Zsolt 2023-05-05 14:54:05 UTC
Mistake
Comment 12 Zsolt 2023-05-05 14:56:17 UTC
'set iface mtu 1492' this fixed it.

Sorry for confusion.
Comment 13 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 18:35:56 UTC
Created attachment 242001 [details]
proposed fix

Undo all your changes to /usr/ports/net/mpd5/files
Download this patch to /usr/ports/net/mpd5/files/patch-mtu
Rebuild, reinstall and restart mpd5 using configuration without any mtu settings.
Comment 14 fbsdbugs 2023-05-05 19:20:25 UTC
Works with the patch without mtu setting.

Thank you!
Comment 15 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 20:43:08 UTC
Please do not close the PR until the port updated.
Comment 16 commit-hook freebsd_committer freebsd_triage 2023-05-05 21:48:11 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=174076e946ae413c0f8903891a450eb821274ca2

commit 174076e946ae413c0f8903891a450eb821274ca2
Author:     Eugene Grosbein <eugen@FreeBSD.org>
AuthorDate: 2023-05-05 21:38:48 +0000
Commit:     Eugene Grosbein <eugen@FreeBSD.org>
CommitDate: 2023-05-05 21:46:57 +0000

    net/mpd5: undo regression for specific PPPoE peers

    mpd5-5.9_14 introduced regression for specific case
    when no mtu configured for PPPoE peer that does not advertize any MTU itself.
    mpd5 should default to 1492 then but revision 14 defaults to 1500.

    The problem may be worked around specifying 1492 for link or interface MTU
    until upgrade to this revision that restores compatibility.

    PR:     270687

 net/mpd5/Makefile                |  2 +-
 net/mpd5/files/patch-max-payload | 65 +++++++++++++++++++++++++++++++++-------
 2 files changed, 55 insertions(+), 12 deletions(-)
Comment 17 Eugene Grosbein freebsd_committer freebsd_triage 2023-05-05 21:51:28 UTC
Please remove patch-mtu then update your Ports tree to get mpd5-5.9_15 with final fix.