Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login
    Introducing Netgate Nexus: Multi-Instance Management at Your Fingertips.

    after pppoe (mpd) restart, dyndns update error

    Scheduled Pinned Locked Moved Routing and Multi WAN
    9 Posts 3 Posters 378 Views 3 Watching
    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.
    • FireOdoF Offline
      FireOdo
      last edited by FireOdo

      Hi,

      I updated yesterday to 2.9.0 CE and I found a problem when pppoe-wan interface is restarted. The dyndns clients dont get updated and this error is shown in log:

      ERROR [phpDynDNS] (redacted) Could not determine the request IP address (using "wan", "pppoe0"): gateway not online
      

      This never happend since I can remember (back to pfsense 2.4.1 etc).

      I'm thinking its a timing problem

      Aug 23 05:03:01	php-fpm	78988	NOTICE [Filter] IP Address has changed, killing states on former IP Address xx.13.177.77.
      Aug 23 05:03:01	php-fpm	78988	NOTICE Default gateway setting WAN IPv4 Gateway as default.
      Aug 23 05:02:58	php-fpm	78775	ERROR [phpDynDNS] (redacted) Could not determine the request IP address (using "wan", "pppoe0"): gateway not online
      

      (the dyndns tryes to update before gateway is really up) because if I call instantly after pppoe restart,

      /etc/rc.dyndns.update
      

      everything gets OK.

      I would have opened a redmine ticket but if I call pfsense redmine I get a "404 Not Found" ...
      (seems like Friday the 13teen and the black cat together ๐Ÿ˜‘ )

      Have a nice sunday,
      FireOdo

      EDIT: Here my "quick and dirty" workaround:

      As after a restart of the pppoe session the file /etc/rc.newwanip is called, I attached at the end of that file
      (before the "?>"

      shell_exec('/etc/rc.dyndns.update');
      

      and that resolved the dyndns update (for me).
      As I said - its a quick&dirty patch until the bug introduced by 2.9.0 is found.

      Kettop Mi4300YL CPU: i5-4300Y @ 1.60GHz RAM: 8GB Ethernet Ports: 4
      SSD: SanDisk pSSD-S2 16GB (ZFS) WiFi: WLE200NX
      pfsense 2.9.0 CE
      Packages: Apcupsd, Cron, Iftop, Iperf, LCDproc, Nmap, pfBlockerNG, RRD_Summary, Shellcmd, Snort, Speedtest, System_Patches.

      P GertjanG 2 Replies Last reply Reply Quote 1
      • P Offline
        pfpv
        last edited by pfpv

        Thank you for posting. I came here to post the same. I have the exact same issue that started with 2.9.0. I will try your workaround. I am pinging @jimp and @johnpoz to bring attention to this. DynDNS is critical to those on PPPoE.
        EDIT: I am using if_pppoe. So, it's not dirver related.

        And while we are on the topic of DynDNS I would like to bring another old issue to attention:
        https://forum.netgate.com/topic/201207/when-one-dyndns-entry-is-force-updated-the-others-get-n-a-for-cached-ip

        P 1 Reply Last reply Reply Quote 1
        • P pfpv referenced this topic
        • P Offline
          pfpv @pfpv
          last edited by

          I would also like to ping @stephenw10, as he recently worked on the if_pppoe kernel driver. Although this issue is not related, and may not even be related to the driver.

          1 Reply Last reply Reply Quote 0
          • P pfpv referenced this topic
          • P Offline
            pfpv @FireOdo
            last edited by

            @FireOdo
            Your workaround works quite well. And DynDNS doesn't update at all without that line in /etc/rc.newwanip
            I wonder how it was before this bug showed up. Maybe the developers forgot this line. I kind of wonder what the original mechanism was.

            FireOdoF 1 Reply Last reply Reply Quote 0
            • FireOdoF Offline
              FireOdo @pfpv
              last edited by FireOdo

              @pfpv said in after pppoe (mpd) restart, dyndns update error:

              Maybe the developers forgot this line.

              No, they have not. This line is just a circumvention of the issue, added by myself.

              I kind of wonder what the original mechanism was.

              As far as I understand the code, the original mechanism is at line 262 - but it seems that this mechanism got a timing problem. (I might be wrong, but thats what I think).

              Kettop Mi4300YL CPU: i5-4300Y @ 1.60GHz RAM: 8GB Ethernet Ports: 4
              SSD: SanDisk pSSD-S2 16GB (ZFS) WiFi: WLE200NX
              pfsense 2.9.0 CE
              Packages: Apcupsd, Cron, Iftop, Iperf, LCDproc, Nmap, pfBlockerNG, RRD_Summary, Shellcmd, Snort, Speedtest, System_Patches.

              1 Reply Last reply Reply Quote 0
              • GertjanG Offline
                Gertjan @FireOdo
                last edited by Gertjan

                @FireOdo said in after pppoe (mpd) restart, dyndns update error:

                As after a restart of the pppoe session the file /etc/rc.newwanip is called, I attached at the end of that file
                (before the "?>"

                shell_exec('/etc/rc.dyndns.update');

                and that resolved the dyndns update (for me).

                like this :

                75b499e1-ed83-4eb9-93a5-56dd4bc2e2a0-image.png

                ?

                have a look at the file "/etc/rc.dyndns.update".
                It calls "services_dyndns_configure($interface);"
                Now, back to my image, the first spot marked in green : is was already called.
                But with a condition (look further up) :

                if (!is_ipaddr($oldip) || ($curwanip != $oldip) || file_exists("{$g['tmp_path']}/{$interface}_upstart4") ||
                    (!is_ipaddrv4(config_get_path("interfaces/{$interface}/ipaddr")) && (config_get_path("interfaces/{$interface}/ipaddr") != 'dhcp')))
                

                The conditions are :
                If there was not an old known (WAN) IP,
                or
                The current WAN IP different from the old WAN IP
                or
                If the file /tmp/{$interface}_upstart4 exists (or /var/tmp/{$interface}_upstart4, not sure)
                or
                If (see the config.xml file) interfaces/{$interface}/ipaddr is NOT a IPv4 address
                or
                If (see the config.xml file) interfaces/{$interface}/ipaddr is not set to 'dhcp'

                Then the last part is executed, and also "services_dyndns_configure($interface);" get called.

                Can you check if that final part gets executed ? If the 'if' fails then yeah, no "services_dyndns_configure($interface);" gets called.

                No "help me" PM's please. Use the forum, the community will thank you.

                FireOdoF 1 Reply Last reply Reply Quote 1
                • FireOdoF Offline
                  FireOdo @Gertjan
                  last edited by FireOdo

                  @Gertjan said in after pppoe (mpd) restart, dyndns update error:

                  Can you check if that final part gets executed ? If the 'if' fails then yeah, no "services_dyndns_configure($interface);" gets called.

                  As far as I can see - no fails, digging.

                  PS. I am still digging, but in my case it seems a issue between dpinger and the gateway of my ISP.

                  Kettop Mi4300YL CPU: i5-4300Y @ 1.60GHz RAM: 8GB Ethernet Ports: 4
                  SSD: SanDisk pSSD-S2 16GB (ZFS) WiFi: WLE200NX
                  pfsense 2.9.0 CE
                  Packages: Apcupsd, Cron, Iftop, Iperf, LCDproc, Nmap, pfBlockerNG, RRD_Summary, Shellcmd, Snort, Speedtest, System_Patches.

                  GertjanG 1 Reply Last reply Reply Quote 0
                  • GertjanG Offline
                    Gertjan @FireOdo
                    last edited by

                    @FireOdo

                    With 'fail' I meant that this if test resulted in a 'false' so lines 225 to 290 are skipped, so line 259 ( services_dnsupdate_process($interface); ) doesn't get executed.

                    No "help me" PM's please. Use the forum, the community will thank you.

                    FireOdoF 1 Reply Last reply Reply Quote 0
                    • FireOdoF Offline
                      FireOdo @Gertjan
                      last edited by

                      @Gertjan said in after pppoe (mpd) restart, dyndns update error:

                      With 'fail' I meant that this if test resulted in a 'false' so lines 225 to 290 are skipped, so line 259 ( services_dnsupdate_process($interface); ) doesn't get executed.

                      Aha, OK - thanks for clarification.

                      Kettop Mi4300YL CPU: i5-4300Y @ 1.60GHz RAM: 8GB Ethernet Ports: 4
                      SSD: SanDisk pSSD-S2 16GB (ZFS) WiFi: WLE200NX
                      pfsense 2.9.0 CE
                      Packages: Apcupsd, Cron, Iftop, Iperf, LCDproc, Nmap, pfBlockerNG, RRD_Summary, Shellcmd, Snort, Speedtest, System_Patches.

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post
                      Copyright 2026 Rubicon Communications LLC (Netgate). All rights reserved.
                      Privacy Policy · Cookie Policy