Error: Must pass domain_name to Class[Cobbler] on node

Asked by bruce trvalik

I'm trying to install OpenStack Havana on Ubuntu 12.04LTS using the puppet_openstack_builder on UCS hadware. I'm doing an all_in_one configuration. My first attempt, failed rather quickly since I did not have SELInux installed. After installing it, I'm getting much further but it ultimately fails with the following error:

Error: Must pass domain_name to Class[Cobbler] on node < mynode.mydomain.com>

prior to the error I get serveral warning like:

Warning: You cannot collect exported resources without storeconfigs being set; the collection will be ignored on line 47 in file /etc/puppet/modules/naginator/manifests/init.pp
Warning: You cannot collect exported resources without storeconfigs being set; the collection will be ignored on line 52 in file /etc/puppet/modules/naginator/manifests/init.pp
Warning: You cannot collect exported resources without storeconfigs being set; the collection will be ignored on line 56 in file /etc/puppet/modules/naginator/manifests/init.pp
Debug: importing '/etc/puppet/modules/naginator/manifests/compute_target.pp' in environment production
Warning: You cannot collect without storeconfigs being set on line 17 in file /etc/puppet/modules/naginator/manifests/compute_target.pp
Debug: Automatically imported naginator::compute_target from naginator/compute_target into production
Debug: importing '/etc/puppet/modules/naginator/manifests/common_target.pp' in environment production
Warning: You cannot collect without storeconfigs being set on line 28 in file /etc/puppet/modules/naginator/manifests/common_target.pp
Warning: You cannot collect without storeconfigs being set on line 39 in file /etc/puppet/modules/naginator/manifests/common_target.pp
Warning: You cannot collect without storeconfigs being set on line 50 in file /etc/puppet/modules/naginator/manifests/common_target.pp
Warning: You cannot collect without storeconfigs being set on line 61 in file /etc/puppet/modules/naginator/manifests/common_target.pp
Warning: You cannot collect without storeconfigs being set on line 72 in file /etc/puppet/modules/naginator/manifests/common_target.pp

Warning: Variable access via 'management_interface' is deprecated. Use '@management_interface' instead. template[/etc/puppet/modules/collectd/templates/collectd.erb]:331
   (at /etc/puppet/modules/collectd/templates/collectd.erb:331:in `result')
Warning: Variable access via 'graphitehost' is deprecated. Use '@graphitehost' instead. template[/etc/puppet/modules/collectd/templates/collectd.erb]:441
   (at /etc/puppet/modules/collectd/templates/collectd.erb:441:in `result')

Warning: Variable access via 'graphitehost' is deprecated. Use '@graphitehost' instead. template[/etc/puppet/modules/collectd/templates/carbon-writer.conf.erb]:12
   (at /etc/puppet/modules/collectd/templates/carbon-writer.conf.erb:12:in `result')

Warning: Variable access via 'allowed_hosts' is deprecated. Use '@allowed_hosts' instead. template[/etc/puppet/modules/naginator/templates/nrpe.erb]:79
   (at /etc/puppet/modules/naginator/templates/nrpe.erb:79:in `result')

Question information

Language:
English Edit question
Status:
Solved
For:
Cisco Openstack Edit question
Assignee:
No assignee Edit question
Solved by:
Chris Ricker
Solved:
Last query:
Last reply:
Revision history for this message
Mark T. Voelker (mvoelker) said :
#1

We think this is related to a change that went in this morning. Stand by and we'll have an update shortly.

Revision history for this message
Mark T. Voelker (mvoelker) said :
#2

Could you also let us know what environmental variables you set?

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#4

scenario=all_in_one
vendor=cisco

Revision history for this message
Chris Ricker (chris-ricker) said :
#5

Did you use the master branch or the coi-development branch?

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#6

I don't relly know.. I was just following the instructions at:

http://docwiki.cisco.com/wiki/Openstack:Havana-Openstack-Installer

This was on top of a fresh install of Ubunut12.04LTS

Revision history for this message
Chris Ricker (chris-ricker) said :
#7

ok, thanks

I've updated the instructions to point to the dev branch (coi-development)

Can you try again? You'll need to reset back to a bare ubuntu and then do

git clone -b coi-development https://github.com/CiscoSystems/puppet_openstack_builder

export vendor=cisco

cd puppet_openstack_builder/install-scripts

./install.sh

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#8

by "reset back to a bare ubuntu" do you mean a clean install or is there away to have puppet clean it up?
Are there any particular options you want during the install?

Revision history for this message
Chris Ricker (chris-ricker) said :
#9

clean install is ideal

If you want to try it before going to the trouble of a new install, this script will probably get you close enough: https://raw.github.com/CiscoSystems/grizzly-manifests/multi-node/manifests/reset_build_node.sh

a minimal server install (so ssh and that's about it) is what we assume as a starting point

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#10

I used the reset build script since I'm remote for the hardware and doing a remote mount of the ISO is rather slow.

Now I get the following error:

Error: Must pass node_subnet to Class[Cobbler] on node openstack2
Error: Must pass node_subnet to Class[Cobbler] on node openstack2

I can wipe the system if you think that will make the difference.. it looking like the reset script did the right thing.

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#11

I re-ran the reset build script and it complained about the following:

dpkg: warning: while removing puppet-common, directory '/var/lib/puppet' not empty so not removed.
dpkg: warning: while removing puppet-common, directory '/etc/puppet/manifests' not empty so not removed.
dpkg: warning: while removing puppet-common, directory '/etc/puppet/templates' not empty so not removed.
dpkg: warning: while removing puppet-common, directory '/etc/puppet/modules' not empty so not removed.

So I removed those directories manual and did another install

Now I get the following error..
I've included the preceding debug info..

Debug: importing '/usr/share/puppet/modules/apache/manifests/mod/prefork.pp' in environment production
Debug: Automatically imported apache::mod::prefork from apache/mod/prefork into production
Debug: importing '/usr/share/puppet/modules/apache/manifests/mod/worker.pp' in environment production
Debug: Automatically imported apache::mod::worker from apache/mod/worker into production
Debug: Scope(Class[Apache::Mod::Prefork]): Retrieving template apache/mod/prefork.conf.erb
Debug: template[/usr/share/puppet/modules/apache/templates/mod/prefork.conf.erb]: Bound template variables for /usr/share/puppet/modules/apache/templates/mod/prefork.conf.erb in 0.00 seconds
Debug: template[/usr/share/puppet/modules/apache/templates/mod/prefork.conf.erb]: Interpolated template /usr/share/puppet/modules/apache/templates/mod/prefork.conf.erb in 0.00 seconds
Debug: importing '/usr/share/puppet/modules/apache/manifests/vhost.pp' in environment production
Debug: Automatically imported apache::vhost from apache/vhost into production
Debug: Scope(Class[Apache::Mod::Proxy]): Retrieving template apache/mod/proxy.conf.erb
Debug: template[/usr/share/puppet/modules/apache/templates/mod/proxy.conf.erb]: Bound template variables for /usr/share/puppet/modules/apache/templates/mod/proxy.conf.erb in 0.00 seconds
Debug: template[/usr/share/puppet/modules/apache/templates/mod/proxy.conf.erb]: Interpolated template /usr/share/puppet/modules/apache/templates/mod/proxy.conf.erb in 0.00 seconds
Error: Must pass ip to Class[Cobbler] on node openstack2
Error: Must pass ip to Class[Cobbler] on node openstack2

Revision history for this message
Michael Chapman (michaeltchapman) said :
#12

Bruce,

I think I've reproduced your issue.

Could you post the contents of /etc/puppet/hiera.yaml?

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#13

/etc/puppet/hiera.yaml

---
:backends:
  - data_mapper
:hierarchy:
  - "hostname/%{hostname}"
  - "client/%{clientcert}"
  - user
  - jenkins
  - user.%{scenario}
  - user.common
  - "vendor/osfamily/cisco_coi_%{osfamily}"
  - "osfamily/%{osfamily}"
  - "enable_ha/%{enable_ha}"
  - "install_tempest/%{install_tempest}"
  - "cinder_backend/%{cinder_backend}"
  - "glance_backend/%{glance_backend}"
  - "rpc_type/%{rpc_type}"
  - "db_type/%{db_type}"
  - "tenant_network_type/%{tenant_network_type}"
  - "network_type/%{network_type}"
  - "network_plugin/%{network_plugin}"
  - "password_management/%{password_management}"
  - "scenario/%{scenario}"
  - grizzly_hack
  - vendor/cisco_coi_common
  - common
:yaml:
   :datadir: /etc/puppet/data/hiera_data
:data_mapper:
   # this should be contained in a module
   :datadir: /etc/puppet/data/data_mappings

Revision history for this message
Chris Ricker (chris-ricker) said :
#14

What's your /root/puppet_openstack_builder/templates/hiera.erb look like?

It should have this line in it:

https://github.com/CiscoSystems/puppet_openstack_builder/blob/coi-development/templates/hiera.erb#L12

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#15

/root/puppet_openstack_builder/templates/hiera.erb

---
:backends:
  - data_mapper
:hierarchy:
  - "hostname/%{hostname}"
  - "client/%{clientcert}"
  - user
  - jenkins
  - user.%{scenario}
  - user.common
<%- if @vendor %> - "vendor/osfamily/<%= @vendor %>_<%= @vendorrepo %>_%{osfamily}"<% end %>
  - "osfamily/%{osfamily}"
  - "enable_ha/%{enable_ha}"
  - "install_tempest/%{install_tempest}"
  - "cinder_backend/%{cinder_backend}"
  - "glance_backend/%{glance_backend}"
  - "rpc_type/%{rpc_type}"
  - "db_type/%{db_type}"
  - "tenant_network_type/%{tenant_network_type}"
  - "network_type/%{network_type}"
  - "network_plugin/%{network_plugin}"
  - "password_management/%{password_management}"
  - "scenario/%{scenario}"
  - grizzly_hack
<%- if @vendor %> - vendor/<%= @vendor %>_<%= @vendorrepo %>_common<% end %>
  - common
:yaml:
   :datadir: /etc/puppet/data/hiera_data
:data_mapper:
   # this should be contained in a module
   :datadir: /etc/puppet/data/data_mappings

Revision history for this message
Chris Ricker (chris-ricker) said :
#16

It looks like you have an older checkout of the development branch that's missing some recent commits

Can you

- run that reset_build_node.sh script

- rm -rf /root/puppet_openstack_builder

- git clone -b coi-development https://github.com/CiscoSystems/puppet_openstack_builder

- compare puppet_openstack_builder/templates/hiera.erb with https://raw.github.com/CiscoSystems/puppet_openstack_builder/coi-development/templates/hiera.erb and make sure they're the same

Assuming they match

- export vendor=cisco

- cd /root/puppet_openstack_builder/install-scripts

- ./install.sh

Because of the commits that are missing some of the hiera data layers you need for various settings to get applied aren't there... This should get you past that

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#17

the scripts are the same.. one thing I'm doing differently is where I run the script from..

I've done my git clone to a user directory off of /home. I've done this as root

Should that cause any problem?

I will unpack this one in /root

Revision history for this message
Best Chris Ricker (chris-ricker) said :
#18

If you do it in root it'll fix

https://github.com/CiscoSystems/puppet_openstack_builder/blob/coi-development/install-scripts/install.sh#L49-52

The install.sh script has a hardcoded assumption that this is being done in /root. Probably not an ideal assumption (as you've shown!) but it's there for a non-vendor common use case of

- tell the user to wget / curl install.sh
- run install.sh and walk away

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#19

The install ran was successfully!

You might just want to update the wiki to instruct the user to run it from /root

now onto configuration

Revision history for this message
bruce trvalik (bruce-trvalik) said :
#20

Thanks Chris Ricker, that solved my question.

Revision history for this message
Chris Ricker (chris-ricker) said :
#21

Thanks for catching that - we'll add it