Bug #4008
closedDisable 'build mode' unsuccessful
Description
We have a foreman instance runnning with puppet on a debian host with following versions:
Foreman from packages VersionĀ : 1.3.1-1
Puppet from packages VersionĀ : 2.7.23-1~deb7u1
We had to change some items name for functional purpose. We updated name of hostgroup, templates, classes ...
Since this name update we are not able to disable 'build mode' on all hosts. Gui returns an error message like 'Failed to cancel pending build for <hostname>'.
In error log this message is related to the following extract:
Started GET "/hosts/<hostname>.localdomain/cancelBuild" for <myIpAddr> at 2014-01-14 07:30:41 +0000 Processing by HostsController#cancelBuild as HTML Parameters: {"id"=>"<hostname>.localdomain"} Add the TFTP configuration for <hostname>.localdomain Failed to generate PXELinux template: undefined method `template' for nil:NilClass Delete the autosign entry for <hostname>.localdomain Rolling back due to a problem: [] Adding autosign entry for <hostname>.localdomain Delete the TFTP configuration for <hostname>.localdomain Failed to save: Failed to generate PXELinux template: undefined method `template' for nil:NilClass Redirected to https://foreman/hosts/<hostname>.localdomain Completed 302 Found in 702.1ms (ActiveRecord: 17.2ms)
As we gave Foreman an important role in our production system, this issue is really relevant to us and is not compatible with production system.
Please check this issue as soon as possible as it really matters to us.
For any further informations, let me know.
Updated by Dominic Cleal over 10 years ago
- Translation missing: en.field_release deleted (
1)
Updated by Dominic Cleal over 10 years ago
- Is duplicate of Bug #2792: If you delete "PXE Localboot Default" cancel build fails added
Updated by Dominic Cleal over 10 years ago
- Status changed from New to Feedback
This error suggests to me the PXELinux localboot template can't be resolved for the host. The name of these is important as Foreman searches for them in order to rewrite the menu on the TFTP server, but it will let you rename them, even though you shouldn't.
Please rename the localboot template(s) back to the original name and that should resolve the issue.
Updated by Thomas Linck over 10 years ago
Thank you Dominic for your help.
I think I never had this template, the one used for built host (localboot) seems to be named : "PXE Default File".
It's the only template I have remaining from default installation I think.
This template was not anymore of 'Kind' 'PXELinux' so I set it back to 'PXELinux'(empty before), didn't solve the issue.
Should I add "the PXELinux localboot template"? I mean, with this exact name? Rename "PXE Default File" to "PXELinux localboot" ?
Updated by Dominic Cleal over 10 years ago
The PXE default file is used as the global default, not for local booting when build mode is disabled, so leave that one along.
You can copy the one here and add it with the name "PXE Localboot Default":
https://github.com/theforeman/community-templates/blob/master/pxe/PXELinux_local.erb
Updated by Thomas Linck over 10 years ago
Perfectly solved the issue.
I can't update issue status but for me it can be closed.
Thank's again.
Updated by Dominic Cleal over 10 years ago
- Status changed from Feedback to Duplicate
Good to hear, thanks.