_start_console provides wrong ipmi command for socat console

Bug #1611285 reported by Andrey Shestakov
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Ironic
Fix Released
Medium
Galyna Zholtkevych

Bug Description

_start_console method makes command for run SOL in shellinabox format:
"/:%(uid)s:%(gid)s:HOME:ipmitool ..."

But socat is not support these variables in command line and fails to establish client connection with error:
2016/08/09 08:42:45 socat[11439] E "EXEC:": wrong number of parameters (5 instead of 1)

Revision history for this message
Mathieu Mitchell (mat128) wrote :

Upon investigation, it seems the common code (https://github.com/openstack/ironic/blob/master/ironic/drivers/modules/ipmitool.py#L1192) provides an ipmi_cmd in the format the shellinabox expects (uid/git/cwd). Manpage for shellinaboxd supports this theory. Additionally, socat does not support this syntax. This is what the reporter is encountering. Removing extraneous parameters allows reporter to correctly launch socat.

Changed in ironic:
assignee: nobody → Andrey Shestakov (ashestakov)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (master)

Fix proposed to branch: master
Review: https://review.openstack.org/363647

Changed in ironic:
status: New → In Progress
Changed in ironic:
assignee: Andrey Shestakov (ashestakov) → Galyna Zholtkevych (gzholtkevych)
Changed in ironic:
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (master)

Reviewed: https://review.openstack.org/363647
Committed: https://git.openstack.org/cgit/openstack/ironic/commit/?id=0acbf378bb543a3428856d80036d4de9c5d133a7
Submitter: Jenkins
Branch: master

commit 0acbf378bb543a3428856d80036d4de9c5d133a7
Author: Andrey Shestakov <email address hidden>
Date: Wed Aug 31 16:16:45 2016 +0300

    IPMI command should depend on console type

    This change implements _get_impi_cmd method for
    IPMI consoles. Depends on type of console,
    ipmi command should contain different arguments.

    Change-Id: I55e712a1a91aed3d533f636e519f0bae1f9be2d4
    Closes-bug: #1611285

Changed in ironic:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (stable/newton)

Fix proposed to branch: stable/newton
Review: https://review.openstack.org/393746

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/newton)

Reviewed: https://review.openstack.org/393746
Committed: https://git.openstack.org/cgit/openstack/ironic/commit/?id=232ecfe6f242db861d30e46524a16f3f4a3a9c8b
Submitter: Jenkins
Branch: stable/newton

commit 232ecfe6f242db861d30e46524a16f3f4a3a9c8b
Author: Andrey Shestakov <email address hidden>
Date: Wed Aug 31 16:16:45 2016 +0300

    IPMI command should depend on console type

    This change implements _get_impi_cmd method for
    IPMI consoles. Depends on type of console,
    ipmi command should contain different arguments.

    Change-Id: I55e712a1a91aed3d533f636e519f0bae1f9be2d4
    Closes-bug: #1611285
    (cherry picked from commit 0acbf378bb543a3428856d80036d4de9c5d133a7)

tags: added: in-stable-newton
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 6.2.2

This issue was fixed in the openstack/ironic 6.2.2 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 7.0.0

This issue was fixed in the openstack/ironic 7.0.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.