Project

General

Profile

Actions

Bug #11829

closed

hammer host create does not send correct compute-attributes information which breaks a condition on the server side

Added by Og Maciel over 8 years ago. Updated over 8 years ago.

Status:
Duplicate
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Difficulty:
Triaged:
Team Backlog:
Fixed in Releases:
Found in Releases:
In Kanboard:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1263332
Description of problem:

I'm trying to create Hosts via the hammer host create command, but once the host is created, it does not have the correct networking and compute attributes as specified in the compute profile used during creation.

Talking to @Tomáš Strachota on irc, he said:

10:21:32 tstrachota: omaciel, it looks like a bug. Hammer sends :compute_attributes => {:volumes_attribute => {}} by default which breaks a 'compute_attributes.empty?' condition on the server side and therefore the compute profile is not applied

My setup is as follows:

  • libvirt compute resource with compute profiles associated and configured to use my virtual network device (named 'foreman')
  • hostgroup is associated with libvirt compute resource (and therefore, the compute profile named "2-Medium") and real RHEL 7.1 content

The following command was used to create a host:

hammer -u "${ADMIN_USER}" -p "${ADMIN_PASSWORD}" -v -d host create --name="rhel-7-server-64-08" --mac="eb:42:17:15:71:0e" --medium-id="${RHEL_7_SERVER_64_MEDIUM_ID}" --root-pass="abracadabra" --organization="${ORG}" --location="${LOCATION}" --architecture-id="${ARCH_64}" --operatingsystem-id="${RHEL7_OS_ID}" --environment-id="${RHEL_7_SERVER_64_ENV_ID}" --domain-id="${DOMAIN_ID}" --puppet-proxy-id="${CAPSULE_ID}" --partition-table-id="${KICKSTART_TEMPLATE_ID}" --compute-resource="local_libvirt" --hostgroup="RHEL 7 Server 64-bit HG" --compute-profile="2-Medium" --interface="network='foreman',network-type='Virtual (NAT)'"

In theory I should be able to pass the host group information and the compute profile, network interface, etc, etc, should be automatically fetched by hammer, but I decided to explicitly pass as many arguments as I could.

The host gets created and can be seen in the web ui, but it cannot be powered on. Upon inspection of said host via the web ui, one can see that the networking device is set to 'physical' and not the virtual one as specified by the compute profile.

Version-Release number of selected component (if applicable):

  • Satellite 6.1.2 running on RHEL 7.1

How reproducible:

Steps to Reproduce:
1. See the summary above
2.
3.

Actual results:

Host is created but does not have correct networking devices and attributes (CPUs, memory, etc)

Expected results:

Additional info:


Related issues 1 (0 open1 closed)

Is duplicate of Foreman - Bug #6342: Compute profile should be used when empty volumes and interfaces passed in compute_attributesClosedTomáš Strachota06/23/2014Actions
Actions #1

Updated by Dominic Cleal over 8 years ago

  • Is duplicate of Bug #6342: Compute profile should be used when empty volumes and interfaces passed in compute_attributes added
Actions #2

Updated by Dominic Cleal over 8 years ago

  • Status changed from New to Duplicate

Appears identical to #6342.

Actions

Also available in: Atom PDF