从 Foreman 中删除主机

从 Foreman 中删除主机

在 Foreman 1.12 中,我从 VMware Web 客户端删除了一个虚拟机,但无法从 Foreman 中删除其记录。

我收到以下错误:

Error: Failed to destroy a compute VMware (VMware) instance
*************: ERF56-4248 [Foreman::FingerprintException]: The remote system presented a public key with hash *********** but we're expecting a different hash. If you are sure the remote system is authentic, go to the compute resource edit page, press the 'Test Connection' or 'Load Datacenters' button and submit

那么,我怎样才能从 foreman 中删除 host 呢?

答案1

根据错误提示,通过以下方式验证与计算资源的连接

计算资源 >>​​ 编辑 CR >> 按“测试连接”或“加载数据中心”按钮并提交

并检查您是否已将 Foreman 公钥(/usr/share/foreman/.ssh/id_rsa.pub)复制到计算资源。

[2] 尝试以下命令。

foreman-rake console
Host.find_by_name("host.example.test").destroy

相关内容