2 NICs, 1 IP… supported? DHCP Client ID?
-
Hi all,
I recall before I started using pfsense, and the routing was done by Apple AEBS devices, I was able to use one IP on my mac with both wireless and cabled LAN connected at the same time. The way I did this was by specifying the same DHCP Client ID in my mac's settings for both NICs, and binding that ID to a certain IP in the router. The plus was that I could switch from wifi to cable and back seamlessly, without losing any connection, but I would get better performance on cable sometimes.
Now on pfsense I hadnt set this up for a long time and decided to give it a try now. Because I can't link two different MAC addresses to the same IP in the DHCP server, I decided to do it the other way around: On the mac I selected 'DHCP with manual IP' and put the same IP in both the wifi and lan cards' TCP/IP settings. It seemed to work well for a while (strangely, all incoming traffic seemed to go through wifi while all outgoing traffic went through the cable), but at some point I returned to my computer to find that the connection was gone. I had to turn off and turn on wifi and lan to get it working again. I checked the pfsense log, since I first thought this was related to updating to 1.2.3 yesterday, but all I found is this:
Jan 23 22:31:04 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 22:31:04 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 22:15:00 check_reload_status: check_reload_status is starting Jan 23 22:11:08 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 22:11:08 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 22:06:50 dnsmasq[12226]: reading /var/dhcpd/var/db/dhcpd.leases Jan 23 21:51:12 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 21:51:12 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 21:34:34 last message repeated 2 times Jan 23 21:31:16 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 21:31:16 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 21:30:01 dnsmasq[12226]: reading /var/dhcpd/var/db/dhcpd.leases Jan 23 21:11:20 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 21:11:20 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 20:55:12 kernel: em3: link state changed to DOWN Jan 23 20:55:02 dnsmasq[12226]: reading /var/dhcpd/var/db/dhcpd.leases Jan 23 20:51:24 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 20:51:24 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 20:31:28 kernel: arp: 192.168.1.3 moved from 00:1b:63:ae:45:51 to 00:1b:63:c3:cb:84 on em0 Jan 23 20:31:28 kernel: arp: 192.168.1.3 moved from 00:1b:63:c3:cb:84 to 00:1b:63:ae:45:51 on em0 Jan 23 20:11:42 dnsmasq[12226]: reading /var/dhcpd/var/db/dhcpd.leases
IRC logs indicate that I disconnected around 22:16, nothing exciting seems to be happening there.
Is this setup just really bad for pfsense, or should it work? -
The log has a lot of messages saying that the IP address has moved interfaces, which is not surprising considering your configuration. Its at least an "unexpected configuration". I don't like such noise in log files because it makes it harder to spot "significant" reports.
If I recall correctly, you are not supposed to have more than one interface in a subnet. If that's so, you have an illegal configuration and can't reasonably expect much help if it misbehaves.
I suspect there are better ways to do what you want (failover? additional bandwidth?), but I don't have any to suggest.
-
Thanks for the reply. The point of this is that I can plug my laptop into the cable for gigabit speeds when I want, but I don't lose connections when I decide to go wireless. When the cards have different IPs and I disconnect the cable, I lose all the connections for a while even though the wifi is already connected.
I do have an update though; it seems that this was not the problem that is causing the connection to be dropped. I only had one connection on all night and still it got disconnected. There were no more such messages in the log, since I only had the wireless connection on, so something else must be going on. Any ideas where to look?