Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Cause:
ipcalc did not know about rfc3021
Consequence:
Broadcast address was not computed correctly
Fix:
We have taught ipcalc that rfc3021 exists.
Result:
Broadcast address should be now correct.
Description of problem:
Broadcast address is wrong for /31 networks, this will cause misconfiguration of ethernet devices.
Version-Release number of selected component (if applicable):
initscripts-9.03.38-1.el6.centos.1.i686
How reproducible: Always
Steps to Reproduce:
ipcalc -b 10.10.10.10/31
Actual results:
BROADCAST=10.10.10.11
Expected results:
BROADCAST=255.255.255.255
Additional info:
[root@fmc ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE="eth1"
BOOTPROTO="static"
HWADDR="00:0C:29:2F:92:7C"
IPV6INIT="no"
MTU="1500"
NM_CONTROLLED="no"
TYPE="Ethernet"
ONBOOT=yes
IPADDR=10.81.81.81
NETMASK=255.255.255.254
Note that "BROADCAST=255.255.255.255" needs to be manually inserted if you want your ethernet configured correctly, actually it should not require that because the correct result is well defined already.
[root@fmc ~]# strace -o /tmp/fff -f /sbin/ifup eth1
[root@fmc ~]# fgrep ipcalc /tmp/fff
9100 execve("/bin/ipcalc", ["/bin/ipcalc", "--prefix", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0
9101 execve("/bin/ipcalc", ["/bin/ipcalc", "--broadcast", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0
9106 execve("/bin/ipcalc", ["/bin/ipcalc", "--network", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0
You can see the script depends on ipcalc to get the answer right... and so it should get the answer right.
I replied to the Bugzilla email, but does not seem to have updated...
Yes the above patch worked for me (I tested by rebuilding SRPM). May I suggest a one-line comment in the source code mentioning RFC3021 (so people can find a reference explaining why it works that way, also in case anyone in future greps out the code looking for the RFC number) ?
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://rhn.redhat.com/errata/RHBA-2015-1380.html
Description of problem: Broadcast address is wrong for /31 networks, this will cause misconfiguration of ethernet devices. Version-Release number of selected component (if applicable): initscripts-9.03.38-1.el6.centos.1.i686 How reproducible: Always Steps to Reproduce: ipcalc -b 10.10.10.10/31 Actual results: BROADCAST=10.10.10.11 Expected results: BROADCAST=255.255.255.255 Additional info: [root@fmc ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1 DEVICE="eth1" BOOTPROTO="static" HWADDR="00:0C:29:2F:92:7C" IPV6INIT="no" MTU="1500" NM_CONTROLLED="no" TYPE="Ethernet" ONBOOT=yes IPADDR=10.81.81.81 NETMASK=255.255.255.254 Note that "BROADCAST=255.255.255.255" needs to be manually inserted if you want your ethernet configured correctly, actually it should not require that because the correct result is well defined already. [root@fmc ~]# strace -o /tmp/fff -f /sbin/ifup eth1 [root@fmc ~]# fgrep ipcalc /tmp/fff 9100 execve("/bin/ipcalc", ["/bin/ipcalc", "--prefix", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0 9101 execve("/bin/ipcalc", ["/bin/ipcalc", "--broadcast", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0 9106 execve("/bin/ipcalc", ["/bin/ipcalc", "--network", "10.81.81.81", "255.255.255.254"], [/* 18 vars */]) = 0 You can see the script depends on ipcalc to get the answer right... and so it should get the answer right.