DHCP relay not working in 2.1.1-RELEASE
after upgrade on pfsense 2.1.1 does not work DHCP relay. DHCP Relay service not started. DHCP Relay service not started and in log writes "dhcrelay: Can't attach interface wan to bpf device /dev/bpf0: Device not configured".
Not sure this is a bug or my ignorance?
same error is also in the 2.1.2 release. In LIVE CD working. HDD does not work. Error occurs in 32bit and 64 bit version. New installation and update.
I had the same issue on two machines when I updated to 2.1.2. I was forced to roll back. Both were using NanoBSD installs.
Our office uses DHCP relay no problem, formerly on 2.1.1, on 2.1.2 since before any other system in the world. No issues. Something somehow specific to what you're doing. Can you describe your setup? It looks like maybe it's putting "wan" (friendlyifname I'm guessing) instead of the NIC name (em0, em1_vlan50, etc.) in the dhcrelay command, but I'm not seeing anywhere in the code where it would do that.
I can confirm your observation with the -i wan. I can confirm it does this on my old 2.1.1 setup as well. I rolled back. The only change between the two was to upgrade using the auto updater from 2.1.1 to 2.1.2.
We have a couple of VLAN interfaces which are our inside, we have a physical interface which is our outside. The vlan interfaces are setup in the dhcprelay the wan interface is not. We also run the captive portal on the inside interfaces if that makes a difference.
I noticed that if I tried manually to start dhcprelay without the -i wan statement it launches but doesn't perform its job.
If the DHCP Relay server is not on any local subnet, and not on any subnet that has an internal static route, but is somewhere that no specific route is known, then this code finds the default gateway and uses that in the DHCP relay "-i" parameter. The current code gets just the interface name (like "wan", "opt1"). But DHCP Relay command needs to be fed the actual device name "vr0", "vr1" etc.
To break this I simply enabled DHCP Relay, select "LAN" interface, and put Destination Server 220.127.116.11
Making this changed fixed it.
I attach a network diagram, screen log functional relay in version 2.1 and functionless relay in version 2.1.2 and config. pfSense running in VMware. According to the messages in the log I would guess an error when compiling the kernel.
![network diagram.PNG](/public/imported_attachments/1/network diagram.PNG)
![network diagram.PNG_thumb](/public/imported_attachments/1/network diagram.PNG_thumb)
2.1 screen OK
2.1.2 screen Fail
I guess the kernel compile error by:
I tried to repair using MAKEDEV, but this command is missing in pfSense :( :
Don't mess with trying to compile anything. The network diagram you have drawn is exactly the sort of case that has the problem. Your DHCP server is reached across the pfSense WAN (which is an unusual but not invalid configuration). The fix is for exactly that, when the DHCP is to be relayed out the default gateway.
Make that 1-line change to /etc/inc/services.inc and it should work.
Thank you very much. It works.