Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Second MAC address for one IP address

    DHCP and DNS
    4
    8
    10.3k
    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.
    • savagoS
      savago
      last edited by

      Today most new pc/laptop have 2 nics (one ethernet and second wi-fi).
      Would be nice option adding aditional place for second mac in pfsense.

      Example from tomato:

      tomato1.JPG
      tomato1.JPG_thumb

      Sys 2.0-RC1: Intel Atom N330 Dual Core @1.6 2048M Ram 40GHD

      1 Reply Last reply Reply Quote 0
      • W
        wallabybob
        last edited by

        What are you proposing should be done with the second MAC address? For example, what should be done if a DHCP lease is active on one address and a DHCP request comes in from the other MAC address?

        1 Reply Last reply Reply Quote 0
        • jimpJ
          jimp Rebel Alliance Developer Netgate
          last edited by

          He just wants one IP entry for two separate MACs, so if your laptop plugs in or uses wifi it gets the same IP each way.

          Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

          Need help fast? Netgate Global Support!

          Do not Chat/PM for help!

          1 Reply Last reply Reply Quote 0
          • B
            Bai Shen
            last edited by

            @jimp:

            He just wants one IP entry for two separate MACs, so if your laptop plugs in or uses wifi it gets the same IP each way.

            I think wallabybob's issue was what happens if you leave the wifi on and plug in?  With both interfaces requesting an IP.

            1 Reply Last reply Reply Quote 0
            • jimpJ
              jimp Rebel Alliance Developer Netgate
              last edited by

              dhcpd tests by ping, it will see that the IP is in use and assign another.

              Then you just have the usual weirdness involved with having two interfaces on the same subnet…

              Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

              Need help fast? Netgate Global Support!

              Do not Chat/PM for help!

              1 Reply Last reply Reply Quote 0
              • W
                wallabybob
                last edited by

                @jimp:

                dhcpd tests by ping, it will see that the IP is in use and assign another.

                Then you just have the usual weirdness involved with having two interfaces on the same subnet…

                Behaviour might depend on the client. I have seen some unexpected (by me) behaviour when I have tried to switch my Ubuntu Linux netbook from wireless to wired interface on the same subnet. The wired interface gets assigned a new IP address but then apparently gets shutdown by network manager (because the new address is on the same subnet as another interface?). Here's an extract from the system log:

                Apr 25 07:55:08 xx NetworkManager: <info>dhclient started with pid 5178
                Apr 25 07:55:08 xx dhclient: Internet Systems Consortium DHCP Client V3.1.3
                Apr 25 07:55:08 xx dhclient: Copyright 2004-2009 Internet Systems Consortium.
                Apr 25 07:55:08 xx dhclient: All rights reserved.
                Apr 25 07:55:08 xx dhclient: For info, please visit https://www.isc.org/software/dhcp/
                Apr 25 07:55:08 xx dhclient:
                Apr 25 07:55:08 xx dhclient: Listening on LPF/eth0/00:24:78:13:01:76
                Apr 25 07:55:08 xx dhclient: Sending on  LPF/eth0/00:24:78:13:01:76
                Apr 25 07:55:08 xx dhclient: Sending on  Socket/fallback
                Apr 25 07:55:09 xx dhclient: DHCPREQUEST of 192.168.211.241 on eth0 to 255.255.255.255 port 67
                Apr 25 07:55:09 xx dhclient: DHCPACK of 192.168.211.241 from 192.168.211.173
                Apr 25 07:55:09 xx dhclient: bound to 192.168.211.241 – renewal in 3128 seconds.
                Apr 25 07:55:19 xx NetworkManager: <info>(eth0): canceled DHCP transaction, dhcp client pid 5178</info></info>

                Next time I try a switchover I'll try to take a bit more notice of what's going on with the other interfaces in the hope of working out a more reliable procedure to switchover.

                1 Reply Last reply Reply Quote 0
                • W
                  wallabybob
                  last edited by

                  After a bit of experimentation I discovered pfSense will let you assign the same IP address to two different MAC addresses but the hostnames have to be different.

                  In pfSense I assigned the IP address associated with my netbook's wired interface to the wireless MAC address on my netbook and disabled and enabled the wireless interface and it successfully got the IP address I had previously associated only with the wired interface's MAC address. I can put up with two different names for the same IP address. Now my automatic backup will run regardless of whether the netbook is online through the wired interface or wireless interface.

                  1 Reply Last reply Reply Quote 0
                  • B
                    Bai Shen
                    last edited by

                    @wallabybob:

                    After a bit of experimentation I discovered pfSense will let you assign the same IP address to two different MAC addresses but the hostnames have to be different.

                    In pfSense I assigned the IP address associated with my netbook's wired interface to the wireless MAC address on my netbook and disabled and enabled the wireless interface and it successfully got the IP address I had previously associated only with the wired interface's MAC address. I can put up with two different names for the same IP address. Now my automatic backup will run regardless of whether the netbook is online through the wired interface or wireless interface.

                    Nice.  I'll have to try it when I get home.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post
                    Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.