← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1610137] Re: config drive fail to reader network_config template

 

When allow to inject network setup into guest,  config drive makeup
openstack/content/0000 from interface.template, But template fail to
render,  as template's format invalidation. the interfaces
template(/usr/share/nova/interfaces.template) come from rpm(mitaka),  it
will be insteaded  with:

# Injected by Nova on instance boot
#
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback
{% for ifc in interfaces %}

auto {{ ifc.name }}
iface {{ ifc.name }} inet static
    hwaddress ether {{ ifc.hwaddress }}
    address {{ ifc.address }}
    netmask {{ ifc.netmask }}
    broadcast {{ ifc.broadcast }}
{% if ifc.gateway %}
    gateway {{ ifc.gateway }}
{% endif %}
{% if ifc.dns %}
    dns-nameservers {{ ifc.dns }}
{% endif %}
{% if use_ipv6 %}
{% if libvirt_virt_type == 'lxc' %}
{% if ifc.address_v6 %}
    post-up ip -6 addr add {{ ifc.address_v6 }}/{{ifc.netmask_v6 }} dev ${IFACE}
{% endif %}
{% if ifc.gateway_v6 %}
    post-up ip -6 route add default via {{ ifc.gateway_v6 }} dev ${IFACE}
{% endif %}
{% else %}
iface {{ ifc.name }} inet6 static
    hwaddress ether {{ ifc.hwaddress }}
    address {{ ifc.address_v6 }}
    netmask {{ ifc.netmask_v6 }}
{% if ifc.gateway_v6 %}
    gateway {{ ifc.gateway_v6 }}
{% endif %}
{% if ifc.dns_v6 %}
    dns-nameservers {{ ifc.dns_v6 }}
{% endif %}
{% endif %}
{% endif %}
{% endfor %}


# Injected by Nova on instance boot
#
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback
{% for ifc in interfaces %}

auto {{ ifc.name }}
iface {{ ifc.name }} inet static
    hwaddress ether {{ ifc.hwaddress }}
    address {{ ifc.address }}
    netmask {{ ifc.netmask }}
    broadcast {{ ifc.broadcast }}
{% if ifc.gateway %}
    gateway {{ ifc.gateway }}
{% endif %}
{% if ifc.dns %}
    dns-nameservers {{ ifc.dns }}
{% endif %}
{% if use_ipv6 %}
{% if libvirt_virt_type == 'lxc' %}
{% if ifc.address_v6 %}
    post-up ip -6 addr add {{ ifc.address_v6 }}/{{ifc.netmask_v6 }} dev ${IFACE}
{% endif %}
{% if ifc.gateway_v6 %}
    post-up ip -6 route add default via {{ ifc.gateway_v6 }} dev ${IFACE}
{% endif %}
{% else %}
iface {{ ifc.name }} inet6 static
    hwaddress ether {{ ifc.hwaddress }}
    address {{ ifc.address_v6 }}
    netmask {{ ifc.netmask_v6 }}
{% if ifc.gateway_v6 %}
    gateway {{ ifc.gateway_v6 }}
{% endif %}
{% if ifc.dns_v6 %}
    dns-nameservers {{ ifc.dns_v6 }}
{% endif %}
{% endif %}
{% endif %}
{% endfor %}


** Changed in: nova
       Status: In Progress => Invalid

** Changed in: nova
     Assignee: Zhengwei Gao (multi-task) => (unassigned)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1610137

Title:
  config drive fail to reader network_config template

Status in OpenStack Compute (nova):
  Invalid

Bug description:
  instance's openstack/content/0000 fail to config, e.g.

  DEVICE=""
  NM_CONTROLLED="no"
  ONBOOT=yes
  TYPE=Ethernet
  BOOTPROTO=static
  IPADDR=
  NETMASK=
  BROADCAST=
  GATEWAY=
  DNS1=

  #if $use_ipv6
  IPV6INIT=yes
  IPV6ADDR=

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1610137/+subscriptions


References