Hide Forgot
Description of problem: We provide an answer file for hosted-engine setup but it is not used like other products. User should be able to specify local answer file for non-interactive installation: hosted-engine --deploy --answer-file=my_answerfile.txt This conforms to other product installation workflows such as RH Satellite and packstack. The answerfile should be in the ini style format: [network] BRIDGE=none FQDN=rhevm.example.com ... [storage] DATACENTER_NAME=hosted_datacenter ... [VDSM] CONSOLE_TYPE=vnc ... Presumably the generated answerfile would be saved for future deployments as /etc/ovirt-hosted-engine/answers.conf Version-Release number of selected component (if applicable): 3.3
Closing as not a bug, since hosted-engine --deploy already accept an answer file. You can specify it using: hosted-engine --deploy --config-append=file See man ovirt-hosted-engine-setup: FILES /etc/ovirt-hosted-engine/answers.conf Default location for generated answer file. The file must be used on additional hosts using the option --config-append EXAMPLE This is an answers.conf example file: [environment:default] OVEHOSTED_NETWORK/bridgeIf=none:None OVEHOSTED_NETWORK/fqdn=str:ovirt.home OVEHOSTED_NETWORK/bridgeName=str:ovirtmgmt OVEHOSTED_NETWORK/firewallManager=str:firewalld OVEHOSTED_NETWORK/gateway=str:192.168.1.1 OVEHOSTED_STORAGE/storageDatacenterName=str:hosted_datacenter OVEHOSTED_STORAGE/storageDomainName=str:hosted_storage OVEHOSTED_STORAGE/hostID=int:1 OVEHOSTED_STORAGE/storageType=none:None OVEHOSTED_STORAGE/volUUID=str:272b4067-1ae4-4755-b2e3-96bb600006e7 OVEHOSTED_STORAGE/domainType=str:nfs OVEHOSTED_STORAGE/imgSizeGB=str:25 OVEHOSTED_STORAGE/storageDomainConnection=str:server.home:/home/images OVEHOSTED_STORAGE/connectionUUID=str:ca50f16a-23ab-465c-914b-b132f07a7151 OVEHOSTED_STORAGE/spUUID=str:8018650a-4c64-48fb-a98e-5602bba3086e OVEHOSTED_STORAGE/imgUUID=str:c7d69e7a-d934-423c-93d6-ca45c5882806 OVEHOSTED_STORAGE/sdUUID=str:1d6f6bca-467e-4890-b220-dd2d9b204ab5 OVEHOSTED_VM/vmVCpus=str:2 OVEHOSTED_VDSM/consoleType=str:vnc OVEHOSTED_VM/vmBoot=str:pxe OVEHOSTED_VM/vmMemSizeMB=str:4096 OVEHOSTED_VM/vmUUID=str:ab35151c-7661-475e-aeaf-adc6fb45e399 OVEHOSTED_VM/vmMACAddr=str:00:16:3e:1b:d7:61 OVEHOSTED_VM/vmCDRom=none:None OVEHOSTED_VM/ovfArchive=none:None OVEHOSTED_VDSM/spicePkiSubject=str:O=home, CN=server.home OVEHOSTED_VDSM/pkiSubject=str:/C=EN/L=Test/O=Test/CN=Test
This bug touches on several issues so I'm happy to break these out into separate bz's if needed. Here's the basic use case: edit answer file, run 'hosted-engine --deploy' on initial host without being prompted. * I don't understand how the current implementation provides unattended, non-interactive install. From what I've seen the initial host deploy only uses these values as the defaults but the user is still prompted. How is that unattended? * I don't understand how using the --config-append option relates to unattended install of the first host. Per the man page it is only to be used for subsequent hosts. If this option provides the functionality I'm looking for then it needs to be renamed and its use explained in the man page. * The answerfile syntax is too complex to be edited by a human. People are bound to get the '/', '=' and ':' delimiters messed up, also mixing upper-case and camel-case. Part of this RFE is to simplify so it conforms to the ini-style format other products use, e.g. satellite, packstack.
(In reply to Aaron Weitekamp from comment #2) > This bug touches on several issues so I'm happy to break these out into > separate bz's if needed. This would be great. > > Here's the basic use case: edit answer file, run 'hosted-engine --deploy' on > initial host without being prompted. > > > * I don't understand how the current implementation provides unattended, > non-interactive install. From what I've seen the initial host deploy only > uses these values as the defaults but the user is still prompted. How is > that unattended? Well, IIRC if you use an answer file generated by a previous execution, the only prompted question should be root password. Root password is not stored in the answer file because we don't want to save it in clear text in a config file. For unattended execution you still can add the password to the answer file. If you see other question prompted (except the one needed to confirm OS has been successfully installed which we can also make answerable by the answer file but I'm not sure on it's utility in such case) please list here the questions still prompted when using an answer file. > * I don't understand how using the --config-append option relates to > unattended install of the first host. Per the man page it is only to be used > for subsequent hosts. If this option provides the functionality I'm looking > for then it needs to be renamed and its use explained in the man page. Maybe the man page is not clear enough. You can use --config-append also on first host but you need to create it by hand since it's created only after validation stage by hosted-engine --deploy. Can you open a bug for this, maybe suggesting a better text for the man page? > > * The answerfile syntax is too complex to be edited by a human. People are > bound to get the '/', '=' and ':' delimiters messed up, also mixing > upper-case and camel-case. Part of this RFE is to simplify so it conforms to > the ini-style format other products use, e.g. satellite, packstack. The answerfile syntax is in the format understood by otopi. So it's the same format used by engine-setup, engine-cleanup and any other otopi based tool. If you think the format is not human usable, please open a bug against otopi about it.