Bug 1182982

Summary: oo-admin-move failed if the NIC eth0 has no ip address
Product: OpenShift Container Platform Reporter: Josep 'Pep' Turro Mauri <pep>
Component: NodeAssignee: Luke Meyer <lmeyer>
Status: CLOSED ERRATA QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: high    
Version: 2.2.0CC: abhgupta, adellape, anli, bleanhar, erich, jokerman, libra-bugs, libra-onpremise-devel, mmccomas, pep, pruan, yudhi.widyatama
Target Milestone: ---Keywords: Upstream
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: rubygem-openshift-origin-msg-broker-mcollective-1.32.1.1-1.el6op, openshift-origin-msg-node-mcollective-1.29.2.1-1.el6op Doc Type: Bug Fix
Doc Text:
When using the oo-admin-move tool, attempting to move a gear failed and the operation was rolled back if the network interface eth0 on the node did not have an IP address. This bug fix updates Facter on nodes to ensure the interface specified in the EXTERNAL_ETH_DEV parameter in the /etc/openshift/node.conf file is identified as the active interface. As a result, gears are able to move successfully.
Story Points: ---
Clone Of: 1147116 Environment:
Last Closed: 2015-04-06 17:06:10 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:
Embargoed:
Bug Depends On: 1147116    
Bug Blocks:    

Description Josep 'Pep' Turro Mauri 2015-01-16 11:27:12 UTC
+++ This bug was initially created as a clone of Bug #1147116 +++

Description of problem:
oo-admin-move failed if the network interface eth0 in the node has no ip address.


Version-Release number of selected component (if applicable):
OpenShift Enterprise 2.2
rubygem-openshift-origin-msg-broker-mcollective-1.31.1.1-1.el6op.noarch

How reproducible:
Always on the nodes where eth0 is inactive

Steps to Reproduce:
1. Install OSE with 2 or more node hosts with eth1 as the active interface, or with eth0 being part of a bonded interface.
2. create application 
3. move application using oo-admin-move

Actual results:
Move failed with this error :

DEBUG: Moving content for app '<redacted>', gear '<redacted>' to <redacted>
Identity added: /etc/openshift/rsync_id_rsa (/etc/openshift/rsync_id_rsa)
ssh: Could not resolve hostname : Name or service not known
Agent pid 31683
unset SSH_AUTH_SOCK;
unset SSH_AGENT_PID;
echo Agent pid 31683 killed;
DEBUG: Moving failed.  Rolling back gear '<redacted>' in '<redacted>' with delete on '<redacted>'
Error moving app '<redacted>',platform 'linux', gear '<redacted>' from <redacted> to <redacted>


Expected results:
Gear moved successfully.

Additional info:
Ref : 
https://github.com/openshift/origin-server/blob/master/plugins/msg-broker/mcollective/lib/openshift/mcollective_application_container_proxy.rb#L703

The function get_ip_address hard-codes eth0 as the NIC.

Comment 3 Luke Meyer 2015-02-02 18:47:30 UTC
Should evaluate the PR - seems like a quick fix.

Comment 4 Luke Meyer 2015-02-16 19:57:52 UTC
Brenton and jolamb looked at this and had the PR merged upstream (I should disavow all actual involvement as I forgot about it). Hopefully QE gets a chance to look at it there or we'll need to wait until the enterprise merge for them to test it.

Comment 9 Anping Li 2015-03-17 08:34:12 UTC
Verified and pass on puddle-2-2-2015-03-16
Gears can be moved from node NIC=eth0 to node NIC=eth1.  After move, applications work

1) setup multiple nodes environment, set node2 eth1 as the NIC.
ip addr |grep "scope global"
    inet 192.168.0.233/24 brd 192.168.0.255 scope global eth1
2) create application and move application between node1 and node2
3) check applications works

Comment 13 errata-xmlrpc 2015-04-06 17:06:10 UTC
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-0779.html