I have the following setup of a network interface with an alias network:
/etc/hostname.igc0
[...]
inet 192.168.14.1 0xffffff00
inet alias 192.168.54.1 0xffffff00
that does the output
# ifconfig igc0
[...]
media: Ethernet autoselect (1000baseT full-duplex)
status: active
inet 192.168.14.1 netmask 0xffffff00 broadcast 192.168.54.255
inet 192.168.54.1 netmask 0xffffff00 broadcast 192.168.54.255
Then I want to use dhcpd with
/etc/dhcpd.conf
[...]
option routers 192.168.54.1;
subnet 192.168.54.0 netmask 255.255.255.0 {
range 192.168.54.200 192.168.54.230;
default-lease-time 600;
max-lease-time 7200;
}
This exact setup was running fine for "subnet 192.168.14.0", but when I
changed to "subnet 192.168.54.0" and tried to restart dhcpd it failed.
Here's what I can see:
# /usr/sbin/dhcpd
Can't listen on igc1 - it has no IP address.
Can't listen on igc0 - dhcpd.conf has no subnet declaration for
192.168.14.1.
fatal in dhcpd: No interfaces to listen on.
So it tries to look specifically for the first subnet and doesn't even
acknowledge the presence of the aliased subnet.