opscode-cookbooks/nova — pull request #1 by pedrojimenez (2012-11-13 12:33:15+00:00)
Title: Changes in template "nova.conf.erb" for specifying nova-wrapper config file.

I am testing "nova cookbook" trying to install a compute node for multihost configuration. When applying the recipes "network" i got some problems and I couldn't start the service "network".

ERROR:
=======
2012-11-12 15:28:57 DEBUG nova.utils [-] Got file lock "iptables" for method "_apply"... from (pid=8060) inner /usr/lib/python2.7/dist-packages/nova/utils.py:743
2012-11-12 15:28:57 WARNING nova.common.deprecated [-] Deprecated Config: The root_helper option (which lets you specify a root wrapper different from nova-rootwrap, and defaults to using sudo) is now deprecated. You should use the rootwrap_config option instead.
2012-11-12 15:28:57 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap iptables-save -c -t filter from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-12 15:28:57 DEBUG nova.utils [-] El resultado fue 97 from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191
2012-11-12 15:28:57 DEBUG nova.utils [-] ['sudo', 'nova-rootwrap', 'iptables-save', '-c', '-t', 'filter'] falló. Reintentando. from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:204
2012-11-12 15:28:59 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap iptables-save -c -t filter from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-12 15:28:59 DEBUG nova.utils [-] El resultado fue 97 from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191
2012-11-12 15:28:59 DEBUG nova.utils [-] ['sudo', 'nova-rootwrap', 'iptables-save', '-c', '-t', 'filter'] falló. Reintentando. from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:204
2012-11-12 15:28:59 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap iptables-save -c -t filter from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-12 15:28:59 DEBUG nova.utils [-] El resultado fue 97 from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191
2012-11-12 15:28:59 DEBUG nova.utils [-] ['sudo', 'nova-rootwrap', 'iptables-save', '-c', '-t', 'filter'] falló. Reintentando. from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:204
2012-11-12 15:29:01 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap iptables-save -c -t filter from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-12 15:29:01 DEBUG nova.utils [-] El resultado fue 97 from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191
2012-11-12 15:29:01 DEBUG nova.utils [-] ['sudo', 'nova-rootwrap', 'iptables-save', '-c', '-t', 'filter'] falló. Reintentando. from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:204
2012-11-12 15:29:03 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap iptables-save -c -t filter from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-12 15:29:03 DEBUG nova.utils [-] El resultado fue 97 from (pid=8060) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191

- The nova rootwrap returned a value different from success (0). I have looked for some info and have identified the point of failure. At the moment of the calling ... nova-rootwrap doesn't have a config file associated and it fails with the commands iptables-save/iptables-restore.

- Added the line to insert the "rootwrap config file" and finally the iptables-save/restore finished and nova-network started (font: http://wiki.openstack.org/Nova/Rootwrap ).

NEW LOG:
========
2012-11-13 12:35:44 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap /etc/nova/rootwrap.conf iptables-save -c -t filter from (pid=29130) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-13 12:35:44 DEBUG nova.utils [-] El resultado fue 0 from (pid=29130) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191
2012-11-13 12:35:44 DEBUG nova.utils [-] Ejecutando cmd (subprocesos): sudo nova-rootwrap /etc/nova/rootwrap.conf iptables-restore -c from (pid=29130) execute /usr/lib/python2.7/dist-packages/nova/utils.py:176
2012-11-13 12:35:44 DEBUG nova.utils [-] El resultado fue 0 from (pid=29130) execute /usr/lib/python2.7/dist-packages/nova/utils.py:191

nova-compute compute01 nova enabled :-) 2012-11-13 12:32:41
nova-network compute01 nova enabled :-) 2012-11-13 12:32:40

Regards.