Project

General

Profile

Actions

Bug #14226

closed

Error when trying to un-associate hostgroup from an organization

Added by Shimon Shtein about 8 years ago. Updated almost 7 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Organizations and Locations
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1243649
To reproduce:

1. Ensure that you have 2 organizations (we'll call them A and B), and a host assigned to organization A with host group A
2. Go to Hosts / All Hosts, tick the host and then go to Select Action / Assign Organization
3. Attempt to move the host to the new organization with "Fix Organization on Mismatch"

This is while host is still in host group A and the host moves successfully without a problem, however, we now have even bigger problems:

Deleting a hostgroup that is refereed by another org (that is not visible to your account) does not error correctly.
In addition to that, it won't actually delete and gives the error:
See Screenshot2

This issue was confirmed as per Bugzilla: 1243276, it was requested that I create a new bugzilla for this issue.

What are the steps to successfully associate(remote) this new hostgroup from the new organization. Without affecting the original organization.

Actions #1

Updated by Shimon Shtein about 8 years ago

Right now the delete message is rejected with a flash message that says which hosts are still connected to it.
I am thinking on adding a more permanent warning message to the edit page, that will warn the user that the hostgroup is used in multiple organizations/locations.

Actions #2

Updated by The Foreman Bot almost 8 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/3490 added
Actions #3

Updated by Dominic Cleal almost 8 years ago

  • Subject changed from Satellite 6.0.8 error when trying to un-associate hostgroup from an organization to Error when trying to un-associate hostgroup from an organization
  • Category set to Organizations and Locations

Please add the claimed error to this bug report, it isn't here.

Actions #4

Updated by Tomer Brisker almost 8 years ago

I think this issue should be marked as resolved.
The original issue was related to an error caused by deleting a hostgroup that is still in use in a different taxonomy, and as far as I understand that issue does not occur in current versions.
Adding a warning to indicate a hostgroup is shared across multiple taxonomies is a bad idea in my opinion for several reasons:
1. Displaying a warning message indicates there is something wrong with sharing across taxonomies. This is a valid use case- for example, a base hostgroup that is used to set some common attributes across several locations.
2. Hostgroups are not unique in this matter. For example, templates can also be shared across multiple taxonomies. If we add warnings, we should add them across all resources that may be shared (which is almost all of them) - causing cluttered UI.
3. If a hostgroup contains taxonomy-specific settings, then it should be scoped only to the relevant taxonomy. If a user mistakenly connects it to other taxonomies, well, I think PEBCAK. If you want to use most of the same settings for another taxonomy - that's what the clone button is for.
4. In some cases this may leak information to a user that they are not supposed to know, i.e. if they only know about one organization they may learn potentially sensitive information about others (for example, that another organization uses the same setup - and possibly root password - they do).

Actions #5

Updated by Dominic Cleal almost 8 years ago

  • Status changed from Ready For Testing to Feedback
  • Pull request deleted (https://github.com/theforeman/foreman/pull/3490)
Actions #6

Updated by Anonymous almost 7 years ago

  • Status changed from Feedback to Resolved
Actions

Also available in: Atom PDF