Hello,

autoprovisioning has completely different code flow, the support is not
there yet. It simply ignores all NICs there and leave them untouched.

LZ

On Wed, Oct 25, 2017 at 11:58 PM, No1 <[email protected]> wrote:

> *Hi Lukas,*
>
> *That's really bad news. and I am wondering whether I conveyed my issue or
> not ! The PR that you stated above is basically using  ' unused_ip ' where
> my issue is it is not only out of range for PXE but also a different
> SUBNET. *
>
> *I am only seeing the issue only when I do the "Auto provision / Quick
> Create button "  from the discovered hosts page. However, If provision
> manually, then I don't have any issue. (please see the below screenshot). *
> *Here, I selected the Subnet manually, After I click on the "provision"
> button under the discovered hosts.* *The question is when we can able to
> do that manually, what is the issue that it is preventing to do the same
> thing from the Auto-provision? (pardon me, If I understood it completely
> wrong.!)*
>
>
> <https://lh3.googleusercontent.com/-_2of8Gr-87c/WfEIbZbK70I/AAAAAAAAAFU/RYYXSq6w6XA38oLSJq4WtjlD68QB9AT4ACLcBGAs/s1600/3.png>
>
>
>
>
> <https://lh3.googleusercontent.com/-0kifxZbRyaI/WfEHx9VlCRI/AAAAAAAAAFM/WczGZjTR21IxqCjx1SroBxO5mh9wriSewCLcBGAs/s1600/4.png>
>
>
>
>
>
> Thanks.
>
>
>
>
>
>
> On Wednesday, October 25, 2017 at 7:32:50 AM UTC-5, Lukas Zapletal wrote:
>>
>> Hello, you did a great job of explaining what you do. Now, I have some
>> bad news for you - discovery does always keep the IP address which was
>> assigned by DHCP server. It's a bug/feature and it needs to be tackled but
>> we are not there yet. There is a PR pending but it is still some work:
>>
>> https://github.com/theforeman/foreman_discovery/pull/306
>>
>> Despite the PR name, this patch really adds unused_ip call into the
>> workflow which will fix your issue.
>>
>> There is no workaround unfortunately, if you can't wait just grab my
>> patch and get it done if you can. I will definitely not be able to work on
>> this at least this year :-(
>>
>> LZ
>>
>> On Wed, Oct 25, 2017 at 4:36 AM, No1 <[email protected]> wrote:
>>
>>> *Hi,*
>>>
>>> *I am using Foreman-Discovery Image to discover the server initially
>>> over a PXE network (ex: my network is on 10.7.19.0/24
>>> <http://10.7.19.0/24>). I have no issues in discovering the host into
>>> Foreman over the PXE network.*
>>>
>>>
>>>
>>>
>>> <https://lh3.googleusercontent.com/-_qHsQttz-EI/We_1TS6oduI/AAAAAAAAAEY/mseBY37GtyQ7dqCfjx6Z1Z4bIZI3UhHDACLcBGAs/s1600/11111.png>
>>>
>>>
>>>
>>>
>>> <https://lh3.googleusercontent.com/-SVbT76ElBi8/We_1jbBt1TI/AAAAAAAAAEc/CvztAeyaZ0QUXQjGjPz_5rZ1EpAdopFWwCLcBGAs/s1600/2222.png>
>>>
>>>
>>>
>>>
>>>
>>> *Now, I created a host group to deploy an operating system under a
>>> different management subnet (10.7.29.0/24 <http://10.7.29.0/24>) network
>>> which is different from the PXE network (of course!). I am planning to
>>> install ESXi on the discovered hosts. And I expect the host to be deployed
>>> using the subnet that I provided in the HostGroup (which is not true. Maybe
>>> I am assuming in a wrong way!).*
>>>
>>>
>>>
>>>
>>>
>>> <https://lh3.googleusercontent.com/-Vz-7d6tphSg/We_2gpHuKuI/AAAAAAAAAEo/kcQ4ZCe1iWMnnHeP-A2ITWtRc7VAIrtMwCLcBGAs/s1600/333.png>
>>>
>>>
>>>
>>> *ESXi kick start installation supports a command line parameter to
>>> provide the –vlanid (for the same physical NIC interface.)*
>>>
>>> *And a snippet from my template is as follows:*
>>>
>>>> <% mgmt_ip = ["10.7.29", 
>>>> @host.facts['ipmi_1_ipaddress'].split(".").last].join('.')
>>>> %>
>>>> <% esxi_hostname = [ @host.facts['lldp_neighbor_sys
>>>> name_enp65s0f1'].split("202").first, "c",
>>>> @host.facts['lldp_neighbor_portid_enp65s0f1'].split("/").last].join()
>>>> %>
>>>> <% mgmt_vlan = "104" %>
>>>> <% def_gateway = "10.7.29.1" %>
>>>> vmaccepteula
>>>>
>>>> # Set the root password
>>>> rootpw --iscrypted <%= root_pass %>
>>>>
>>>> # Install ESX
>>>> <%= @host.diskLayout %>
>>>> <% subnet = @host.subnet -%>
>>>> network --bootproto=static --ip=<%= mgmt_ip -%> --gateway=<%=
>>>> def_gateway -%> --nameserver=<%= subnet.dns_primary  -%> --netmask=<%=
>>>> subnet.mask -%> --hostname=<%= esxi_hostname -%> --device=vmnic2 
>>>> --vlanid=<%=
>>>> mgmt_vlan -%>  --addvmportgroup=0
>>>
>>>
>>>
>>> *So, when I click on the Auto Provision (under discovered hosts), it
>>> will install the Operating system without any issues, I mean ESXi will have
>>> all the hostnames and Management IP address from the template (as I am not
>>> picking them from the GUI parameters).*
>>>
>>>
>>> *However, after the installation, my host on the foreman still have the
>>> PXE network showing as assigned IP? How can I update the IP address?
>>> [Actual host will have the management IP as I am hard-coding that value
>>> through provisioning template because I don’t know How to change that using
>>> auto provision?]*
>>>
>>>
>>> *I am wondering, how does auto provision picks IP address from the PXE
>>> even after I assigned the subnet for my host group as a different subnet
>>> (logically, it should pick the subnet from the host group isn’t?). If
>>> that’s not possible, how do I update the host details once the installation
>>> is finished?*
>>>
>>>
>>>
>>>
>>> <https://lh3.googleusercontent.com/-YTW_YuAxApw/We_4bjUw90I/AAAAAAAAAE4/kgRDWLzHq4USg0Pi48OpW4XEInhqtLr9ACLcBGAs/s1600/444.png>
>>>
>>>
>>>
>>>
>>>
>>> <https://lh3.googleusercontent.com/-NPMvjqApYFU/We_4iDagdnI/AAAAAAAAAE8/yYMZv2lihyAB4gpIA18NC3kYr5XZ2d4EwCLcBGAs/s1600/555.png>
>>>
>>>
>>>
>>> Thanks,
>>>
>>> Naren.
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Foreman users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to [email protected].
>>> To post to this group, send email to [email protected].
>>> Visit this group at https://groups.google.com/group/foreman-users.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> Later,
>>   Lukas @lzap Zapletal
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Foreman users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/foreman-users.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Later,
  Lukas @lzap Zapletal

-- 
You received this message because you are subscribed to the Google Groups 
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to