#617264 dhcp-helper: does not handle interfaces with labels

Package:
dhcp-helper
Source:
dhcp-helper
Description:
A DHCP relay agent
Submitter:
Marc Haber
Date:
2015-03-14 02:39:04 UTC
Severity:
normal
#617264#5
Date:
2011-03-07 17:00:33 UTC
From:
To:
Hi,

dhcp-helper does not work with interfaces that have a label (created
with "ip addr add dev int103 10.1.103.254/24 brd + label
int103:67fe8). It simply doesn't forward an incoming request.

strace excerpt:
recvmsg(3, {msg_name(16)={sa_family=AF_INET, sin_port=htons(68), sin_addr=inet_addr("0.0.0.0")}, msg_iov(1)=[{"\1\1\6\0002\307\270S\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\37\26&"..., 548}], msg_controllen=24, {cmsg_len=24, cmsg_level=SOL_IP, cmsg_type=, ...}, msg_flags=0}, MSG_PEEK) = 300
recvmsg(3, {msg_name(16)={sa_family=AF_INET, sin_port=htons(68), sin_addr=inet_addr("0.0.0.0")}, msg_iov(1)=[{"\1\1\6\0002\307\270S\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\37\26&"..., 548}], msg_controllen=24, {cmsg_len=24, cmsg_level=SOL_IP, cmsg_type=, ...}, msg_flags=0}, 0) = 300
ioctl(3, SIOCGIFNAME, {ifr_index=14, ifr_name="int103"}) = 0
ioctl(3, SIOCGIFADDR, {ifr_name="int103", ???}) = -1 EADDRNOTAVAIL (Cannot assign requested address)
recvmsg(3, {msg_name(16)={sa_family=AF_INET, sin_port=htons(68), sin_addr=inet_addr("0.0.0.0")}, msg_iov(1)=[{"\1\1\6\0002\307\270S\0\3\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\37\26&"..., 548}], msg_controllen=24, {cmsg_len=24, cmsg_level=SOL_IP, cmsg_type=, ...}, msg_flags=0}, MSG_PEEK) = 300
recvmsg(3, {msg_name(16)={sa_family=AF_INET, sin_port=htons(68), sin_addr=inet_addr("0.0.0.0")}, msg_iov(1)=[{"\1\1\6\0002\307\270S\0\3\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\37\26&"..., 548}], msg_controllen=24, {cmsg_len=24, cmsg_level=SOL_IP, cmsg_type=, ...}, msg_flags=0}, 0) = 300
ioctl(3, SIOCGIFNAME, {ifr_index=14, ifr_name="int103"}) = 0
ioctl(3, SIOCGIFADDR, {ifr_name="int103", ???}) = -1 EADDRNOTAVAIL (Cannot assign requested address)

Calling dhcp-helper with -i int103:67fe8 instead if -i int103 doesn't
hellp. Removing the label from the interface (ip addr del dev int103
10.1.103.254/24; ip addr add dev int103 10.1.103.254/24) does.

dhcp-helper should properly handle interfaces with labels.

Greetings
Marc

#617264#10
Date:
2014-02-04 14:53:06 UTC
From:
To:
Hi Marc,

i just tried to confirm your bug but it seems to be not a problem with labels in general.

I tried with success:

ip addr add dev eth0 1.2.3.4/24 brd + label eth0:67fe8

and dhcp-helper can bind without problems.

I'm using Version 1.0-1.

Stefan