PPPoE With Static IP Assignment - Best Option?



  • Hello, new here, hope it's OK to ask a question.

    I'm having a bit of trouble with the PPPoE connection through PF. My current ("working") setup is as follows:

    Draytek in a "semi-bridged" mode with LAN PPPoE passthrough > PFsense > devices

    The Draytek has been configured for PPPoA, with the ISP credentials authenticating the connection. I have then checked the radio button to pass this PPP connection through via LAN. I then have PFsense connected via Port 1 on the Draytek, into the WAN port. I have then configured the PFsense WAN as PPPoE, and provided the same ISP credentials (as on the Draytek).

    This works, however I'm being assigned rolling IPs instead of my static one. This is obviously causing a problem for the services that rely on the static IP assignment. I've done some research into this, and have come across various solutions (virtual IPs, allowing the Draytek to fully authenticate etc). I'm not very experienced with this sort of thing, and was unsuccessful in testing prior. I wouldn't be entirely sure how to pass through the static IP to PF if the Draytek did do the full authentication.

    PFsense is currently assigned as the default gateway. DHCP and DNS are handled by the domain controller.

    The ISP provides no gateway, though has given me a block of IPs when I requested information:

    Subnet Network ID: XX.XX.XX.240
    IP of LAN port: XX.XX.XX.241
    Static IP: XX.XX.XX.242
    Subnet broadcast: XX.XX.XX.243

    Subnet mask is /30.

    Ideally if anyone can give advice or what method is generally used to overcome this issue, I would greatly appreciate it.

    Thanks in advance if you take the time.


  • LAYER 8 Global Moderator

    Well a mask of /30 would only be 2 workable IPs on that network.. I would assume their IP, or your gateway for the connection would be the .241 IP and IP on your device would be the .242



  • Just to add, looking at the router manual, the "PPPoE Pass-Trough" radio button states:

    If you check this box, PCs on the same network can use another set of PPPoE session (different with the Host PC) to access into Internet.

    It does also say however for PPPoA, which is what I am using:

    The router will behave like a modem which only serves the PPPoE client on the LAN.

    That's what I want it to do of course, create the link with the credentials, though why it's not giving me the static IP I don't know. Speaking with the ISP and the limitations there, the static assignment is performed on their end, which I imagine must be performed using my supplied credentials. If the credentials are correct, where does the issue arise?



  • @johnpoz

    Hi, thanks for responding.

    Yes that's correct, the 242 is the assignment of the device. Prior to installation, the old setup was working on that address. I wasn't fully aware what the other supplied addresses were referring to.

    Could I ask then what my best option is to have that function? I assume that it would require changing PF's WAN interface to another configuration type, or perhaps a modification on the Draytek modem?

    Thanks.



  • This post is deleted!


  • Figured it out in the end after a lot of searching. Guess it's not a common enough issue, but I found it.

    Thanks to a helpful post all the way back in 2012:

    a) In the Interfaces GUI, setup PPPoE on your WAN as normal and save. This makes a mpd_wan.conf.

    b) Open the console from your PF box (entry 5) and run:

    cp /var/etc/mpd_wan.conf /conf
    

    In the GUI, Diagnostics->Edit File, copy paste this or enter /conf/mpd_wan.conf

    In the pppoeclient: section, add the line

    set iface addrs !111.112.113.2 !111.112.113.1
    

    Substitute the first above for your static address, and the second above as your ISP gateway (IP of LAN Port in my initial post)

    e) Save the file

    f) Do something to restart the interface - e.g. hit save on Interfaces->WAN or even reboot, the conf will be preserved across reboots.

    g) From the console, you can verify that /var/etc/mpd_wan.conf is now a link (optional):

    ls -l /var/etc/mpd_wan.conf
    
    lrwxr-xr-x  1 root  wheel  18 Mar 19 16:17 /var/etc/mpd_wan.conf -> /conf/mpd_wan.conf
    

    The doc for mpd5 is at http://mpd.sourceforge.net/doc5/mpd.html and the "set iface" options are on page http://mpd.sourceforge.net/doc5/mpd2

    Seems to be working and my IP is now set correctly.

    EDIT: Why is this not standard in the GUI? It seems very simple to implement and would make it a lot clearer to people that it's possible. Granted, I'm no expert like I've said, but it took an awful lot of trial and error before I made it here. If the option was just there it would save me (and potentially others) a lot of trouble. Maybe something for a future release?


  • Banned

    @Armstrong said in PPPoE With Static IP Assignment - Best Option?:

    EDIT: Why is this not standard in the GUI? It seems very simple to implement and would make it a lot clearer to people that it's possible. Granted, I'm no expert like I've said, but it took an awful lot of trial and error before I made it here. If the option was just there it would save me (and potentially others) a lot of trouble. Maybe something for a future release?

    Create a feature request on https://redmine.pfsense.org/ then. Spice it up with a pull request containing the required code changes, if you want it added fast(er).



  • @Grimson

    If I had even half the ability of the developers I'd give it a try myself, but I no would no doubt just break something.

    I've submitted a feature request as suggested.


  • Netgate Administrator

    Static IPs are very rare for PPPoE. Even more rare are links with no gateway specified.

    If you need to use a custom mpd config though a conf file in /conf will be used in preference the generated one in /var/etc as you found.

    Steve


Log in to reply