Auto Provisioning ignoring IP-Range of a subnet

Hi all,

I'm new to foreman and running into the following problem.

All BareMetal hosts will be discovered in a special IP-Range
(10.100.44.X/24).
During the Provisioning i change the Interface Subnet to a different one
(10.100.46.X/24, IPAM:InternalDB, Bootmode:static, With Start and End of
IP-Rage defined)

When i provision the host manually i change the subnet and have to click
"suggest new", new ip will be picked from the range. All things works well.
But when i create discovery rules, set the subnet and all the other stuff,
and run Auto Provision the new subnet will be showed but the old ip address
from 10.100.44.x will be used for the interface. In this step i can't use
"suggest new" to generate the right IP.

I try already many things but nothing worked.

More Details:
Foreman (1.10.0 and 1.10.1 tested)
Foreman-discovery (4.1.2)

Discovery Rule (search:model ~ "PRIMERGY", HostGroup:test, Hostname:
Server-1-<%= @host.ip.split('.').last %>)
HostGroup test(Subnet:Static(10.100.46.0/24), Domain:HostDomain,OS:…)
SubNet Static(NetworkAddress:10.100.46.0, Networkmask: 255.255.255.0,…,
IPAM:InternalDB, Bootmode:static, With Start and End of IP-Rage defined, )

The AutoProvisioned Host
Server-1-11:
Domain: HostDomain
HostGroup: test
Interface: Subnet Static(10.100.46.0/24) IP-Address:10.11.44.11

Best regards

Susanne

> I try already many things but nothing worked.

Unfortunately, this is a feature we don't yet have.

Upvote Feature #13847: Auto-provisioning custom scripts for NIC configurations - Discovery - Foreman

··· -- Later, Lukas #lzap Zapletal

Hi Lukas,

thanks for the Feature request and the fast reply.
Going mad the last few days trying to find a solution. Even try to delete
the ipaddresses in the facts… But the discovery_ip was still there…

Regards
Susanne

··· On Tuesday, February 23, 2016 at 2:07:00 PM UTC+1, Lukas Zapletal wrote: > > > I try already many things but nothing worked. > > Unfortunately, this is a feature we don't yet have. > > Upvote http://projects.theforeman.org/issues/13847 > > -- > Later, > Lukas #lzap Zapletal >