Project

General

Profile

Actions

Feature #22485

open

Ability to leave IP address field empty when creating new host

Added by Daniel Lobato Garcia over 6 years ago. Updated about 5 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Network
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1511416

Description of problem:
In some environments, Foreman is used to provision new hosts, but DHCP is not running on Foreman/Smart Proxy, but already exist (e.g. from AD) and is not known to the Foreman.

In this situation, when creating a new host, it is not known what IP the host will get from the DHCP, but you still have to provide an IP (which will be set in the Foreman but ignored by the DHCP) in the Interfaces tab under Hosts -> New Host.

This makes no sense and creates confusion for customers, since that IP is not used anyway.

Version-Release number of selected component (if applicable): 6.2.12

How reproducible:
Always

Steps to Reproduce:
1. Setup a Foreman and Smart Proxy (or use the internal Smart Proxy on the Foreman) in a subnet where DNS and DHCP is provided by another party (e.g. AD).
2. Start the TFTP service on the Smart Proxy
3. Make sure the existing DHCP has configured the Smart Proxy as next-server
4. Create a subnet declaration for the subnet in the Foreman. Since you don't have DHCP running on the Smart Proxy the only sensible choice (to me) is to set "IPAM: None"
5. Under Smart Proxys, choose the Smart Proxy as TFTP Smart Proxy and leave the others to None, since neither of the other features are enabled on the Smart Proxy.
6. Now create a new host (Hosts -> New Hosts). When you choose the subnet in the Interfaces tab, you have to manually input an IP (which you don't know at this stage). Otherwise you can't create the host. You can input whatever IP you want that is in the range of the subnet, it does not matter.
7. Press Submit and the host is created and built with an IP assigned by the DHCP.

Actual results:
You have to input a random IP since you don't know what IP the DHCP will provide, in order to be able to create the host.

Expected results:
Alternative 1: If you choose "IPAM: None" in your subnet declaration, you should be able to leave the IP field empty.

Alternative 2: Add another option to the IPAM field that allows you to create a host without providing an IP address.

Additional info:
I have seen this with multiple customers that have an existing network they want to use where they have these components in place. I know that the Smart Proxy can integrate with different providers, but IIRC AD DHCP is not one of them (yet).

One workaround is to set "IPAM: Internal DB" and set start and end of IP range to e.g. the first IP in the DHCP range. Then the Foreman will suggest the same IP every time even if it is not the one the host will get in the end.

It is also possible to make sure that the Foreman updates to the correct IP after build is complete with the following setting: Administer -> Settings -> Provisioning -> Update IP from built request.

Actions

Also available in: Atom PDF