Alex, host-add will add a host of the specified personality (e.g. controller, worker, experimental edgeworker ...) to the system/cluster. The host may also be detected automatically and added to inventory when it attempts to pxeboot. The added host will attempt to pxeboot the active image, which may be served from the controller; or in the case of edgeworker, the image would need to be already installed. After a host has been added, it is possible to reinstall the host, however, this will lead to the host's disk being wiped. host-reinstall is required only for certain exceptional host configuration changes as specified here: https://docs.starlingx.io/deploy_install_guides/r5_release/bare_metal/reinst... https://docs.starlingx.io/cli_ref/system.html#host-configuration Thus, 'system host-reinstall' will trigger the reinstall of the host (sets the HAS_REINSTALLING state). Otherwise, a regular host-lock/unlock/reboot will boot from disk the already installed load (from the host-add). Experimentally, there is also an 'edgeworker' personality where the host OS is not installed/reinstalled by the controller: https://docs.starlingx.io/deploy/deploy-edgeworker-nodes.html regards, John ----------------------------------------------------------------------------------------- Message: 2 Date: Wed, 14 Jul 2021 20:52:52 +0000 From: "Williams, Alexander" <Alexander.Williams@commscope.com<mailto:Alexander.Williams@commscope.com>> To: "starlingx-discuss@lists.starlingx.io<mailto:starlingx-discuss@lists.starlingx.io>" <starlingx-discuss@lists.starlingx.io<mailto:starlingx-discuss@lists.starlingx.io>> Subject: [Starlingx-discuss] Modifying host-add for bare metal edge cloud Message-ID: <BYAPR14MB247055786D33259D8E125DC599139@BYAPR14MB2470.namprd14.prod.outlook.com<mailto:BYAPR14MB247055786D33259D8E125DC599139@BYAPR14MB2470.namprd14.prod.outlook.com>> Content-Type: text/plain; charset="utf-8" Hi all, I'm looking into modifying the host add endpoint for personal use, and wanted to ask a few clarifying questions: If I understand it correctly, the POST v1/ihosts endpoint is how hosts are added, and corresponds to the post/ _do_post commands in this file: https://github.com/starlingx-staging/stx-config/blob/master/sysinv/sysinv/sy... Related to this particular file: * When the host is set to action state HAS_REINSTALLING, is this to reinstall the base .iso (unconfigured, but of the correct kind)? If not, what is this responsible for doing? If so, when does this trigger on the added host? * Where can I find this file/other API related files in the filesystem? JK> This ihost.py file is installed in the filesystem under /usr/lib64/python2.7/site-packages/sysinv/api/controllers/v1/ . More generally: * If I'm adding controller-1 on an edge cloud, the pxeboot step handles both unconfigured .iso installation, followed immediately by the bootstrap (using the same overrides as controller-0(?)). Are these two separate in any way, or handled by a single config? Is this different from the central cloud, since the bootstrap override file isn't ever present on an edge cloud machine JK> Additional configuration would be required for controller-1. E.g. https://docs.starlingx.io/deploy_install_guides/r5_release/virtual/aio_duple... * Is there a mechanism to avoid pxe-booting while still having a host as part of the inventory (is this just host-add)? JK> the host-add will typically enable the host for pxeboot based on the mgmt_mac address; unless it is an edgeworker personality. * Is there a way to run the bootstrap on the second host without pxebooting/ reinstalling the base .iso in the process? JK> There is an experimental feature for 'edgeworker' personality, where the OS of the node is not installed by the StarlingX controller; currently supports only Ubuntu: https://docs.starlingx.io/deploy/deploy-edgeworker-nodes.html I'm aware that this is not supported/ tested, but any help on any of the above questions would be greatly appreciated. (I am also aware of the INSTALL_UUID potentially presenting an issue, but if any of the above are possible that would be great to know.) Thanks! Best, Alex