Bug #11251
closed
Unable to save host due to 'some of the interfaces are invalid' error
Added by Josh Baird over 9 years ago.
Updated almost 9 years ago.
Description
I have a number of managed hosts that were provisioned prior to the networking changes in 1.8. When I attempt to edit one of them (to add a puppet class or whatnot), I get an error:
Some of the interfaces are invalid. Please check the table below.
These hosts all have a combination of physical and virtual interfaces (bonds). I have uploaded images from two different examples. In one, it is showing two eth0 interfaces (and no eth4 interface). In each of these cases, the IP addresses are assigned to bond0. When I try to manually fix the errors, and re-save the form, the form reverts to it's original state and the same error is displayed. I'm unable to save any changes to these hosts.
I have also uploaded the facts from each of the hosts.
Files
As a quick workaround you can edit/destroy duplicated interfaces using API. The UI validates interfaces and fails since you're already in inconsistent state. If reimporting the facts causes adding invalid interfaces again, you can turn it off by setting ignore_puppet_facs_for_provisioning setting to true, this will disable all interface changes based on incoming facts.
- Related to Bug #11034: network/interfaces validation checks the removed interfaces added
- Status changed from New to Need more information
- Assignee set to Marek Hulán
I tried to import the provided facts which created interfaces correctly. The reason why you see duplicated IPs is because when you provisioned the host, eth0 got some IP and then you enabled bond on the host. Then facts came in and created bond with the same IP. We sadly don't obey validations there, maybe we should finally fix this. Anyway once you get into inconsistent state, UI won't let you fix it easily. In your case you can set IP to be blank, save the host and then get back and set the right IP just on the bond. Tested with host created by facts_2. Please let us know if it helps.
- Related to Refactor #11442: When host is created from facts we don't trigger validations added
I have tested this workaround and it seems to be fine.
- Status changed from Need more information to Resolved
Thank you, I'm changing this to be resolved and to prevent the original cause, I opened #11442. Thank you for the report and quick response. If similar issue will be reported we would need to reimplement the IP validation since the one from Rails can not handle this situation.
Also available in: Atom
PDF