| Summary: | ifdown on lo alias does not work | |||
|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | Jonathan Maxwell <jmaxwell> | |
| Component: | initscripts | Assignee: | David Kaspar // Dee'Kej <deekej> | |
| Status: | CLOSED ERRATA | QA Contact: | Jan Ščotka <jscotka> | |
| Severity: | urgent | Docs Contact: | Mirek Jahoda <mjahoda> | |
| Priority: | urgent | |||
| Version: | 6.7 | CC: | ashish, deekej, fkrska, joedward, lnykryn, mkolaja, psklenar, ptalbert, sroza | |
| Target Milestone: | rc | Keywords: | FastFix, Patch, Reproducer, ZStream | |
| Target Release: | --- | |||
| Hardware: | x86_64 | |||
| OS: | Linux | |||
| Whiteboard: | ||||
| Fixed In Version: | initscripts-9.03.54-1 | Doc Type: | Bug Fix | |
| Doc Text: |
"ifdown" on a loopback device now works properly
In Red Hat Enterprise Linux version 6.7 and 6.8, executing the "ifdown" command on a local loopback device failed to remove the device. A patch has been applied, and the removal of an existing loopback device using "ifdown" now succeeds.
|
Story Points: | --- | |
| Clone Of: | ||||
| : | 1398678 1420052 1420053 (view as bug list) | Environment: | ||
| Last Closed: | 2017-03-21 11:52:32 UTC | Type: | Bug | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Bug Depends On: | ||||
| Bug Blocks: | 1269194, 1356056, 1359260, 1370193, 1398678, 1420052, 1420053 | |||
Unfortunately running flush on lo devices with scope global brings other problems https://bugzilla.redhat.com/show_bug.cgi?id=1072967 I wonder why flushing lo with global hangs in the bz_1072967 case? I don't see that behaviour on my LAB system. It shutdowns and boots up fine with this change. "fixed" in upstream rhel6 branch -> https://git.fedorahosted.org/cgit/initscripts.git/commit/?h=rhel6-branch&id=d59202d1d37c23126e17f8bc05d8a05d059b72a0 -> post This bug is present in CentOS 7 as well - https://bugs.centos.org/view.php?id=10980. Can the upstream fix be ported over for the rhel7-branch as well? Apologies, ignore Comment 14. Commit was accepted: https://github.com/fedora-sysv/initscripts/commit/d59202d1d37c23126e17f8bc 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-2017-0786.html |
Description of problem: when executing ifdown lo:0, it does not report an error but fails to remove the device. This worked on RHEL6.6 but fails on RHEL6.7. Replacing RHEL6.7 /etc/sysconfig/ifdown-eth with a RHEL6.6 fixed the problem. Version-Release number of selected component (if applicable): RHEL6.7 # rpm -qa |grep initscr initscripts-9.03.49-1.el6.x86_64 How reproducible: Always Steps to Reproduce: 1. Install RHEL6.7 and make sure above initscript version is installed. 2. Create the following /etc/sysconfig/network-scripts/ifcfg-lo:0 file: DEVICE=lo:0 IPADDR=192.55.1.1 NETMASK=255.255.255.255 ONBOOT=yes NAME=loopback ARP=no 3. Bring the device up: # ifup lo:0 4. Now ifdown: # ifdown lo:0 The device is still there: # ifconfig . . lo:0 Link encap:Local Loopback inet addr:192.55.38.53 Mask:255.255.255.255 UP LOOPBACK RUNNING NOARP MTU:65536 Metric:1 Actual results: The lo:0 device is not removed. Expected results: The lo:0 device should be removed. Additional info: I add the following patch: https://git.fedorahosted.org/cgit/initscripts.git/commit/?h=rhel6-branch&id=78cbc202ad90ffc9256bfd3b45c423eeff0e97b5 However the problem remained. Then I changed the following: if [ "${REALDEVICE}" = "lo" ]; then ip addr flush dev ${REALDEVICE} ${LABEL} scope host 2>/dev/null to ip addr flush dev ${REALDEVICE} ${LABEL} scope global 2>/dev/null Here is the diff: # diff -Naur /etc/sysconfig/network-scripts/ifdown-eth ifdown-eth.fix --- /etc/sysconfig/network-scripts/ifdown-eth 2016-02-24 22:35:42.092750956 -0500 +++ ifdown-eth.fix 2016-02-24 22:35:07.495844305 -0500 @@ -111,7 +111,7 @@ LABEL="label ${DEVICE}" fi if [ "${REALDEVICE}" = "lo" ]; then - ip addr flush dev ${REALDEVICE} ${LABEL} scope host 2>/dev/null + ip addr flush dev ${REALDEVICE} ${LABEL} scope global 2>/dev/null else ip addr flush dev ${REALDEVICE} ${LABEL} scope global 2>/dev/null ip -4 addr flush dev ${REALDEVICE} ${LABEL} scope host 2>/dev/null and that fixed the problem.