[ZBXNEXT-1262] nested host groups Created: 2012 Jun 13 Updated: 2022 Jul 05 Resolved: 2017 Feb 14 |
|
Status: | Closed |
Project: | ZABBIX FEATURE REQUESTS |
Component/s: | API (A), Documentation (D), Frontend (F), Installation (I), Server (S) |
Affects Version/s: | None |
Fix Version/s: | 3.2.0 |
Type: | New Feature Request | Priority: | Minor |
Reporter: | richlv | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 93 |
Labels: | flexibility, grouping, nested | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Attachments: | 14_zabbix-2.0.6-frontend_group-groups-2.patch after.png before.png error.png incorrect-alignent.png ms_search_results.png multiselect.png permissions.png zbx_nested_hostgroup.png | ||||||||||||||||||||
Issue Links: |
|
||||||||||||||||||||
Team: | Team A | ||||||||||||||||||||
Sprint: | Sprint 1 |
Description |
It should be possible to nest host groups. open questions : Should groups be able to contain both groups and hosts ? open questions, large areas : Permissions (general, global scripts, maintenance, actions...) forum threads : http://www.zabbix.com/forum/showthread.php?t=11425 |
Comments |
Comment by Henrik Johansen [ 2012 Jun 13 ] |
Since this is a rather fundamental change of the way people currently interact with the ZBX front-end I would envision that this need to be done in smaller steps. Perhaps we should simply introduce a new type of Host Group (a "Host Group Container"?) that Host Groups can be flagged as - the flag would enforce that a Host Group Container only Permissions and action conditions/ targets are our primary headache right now - a simple inheritance model from top to bottom would most likely we the simplest solution and would scratch our particular itch well. After that, network map display is the next major issue where nesting should be supported in our use case. |
Comment by Vitaly Nikolaev [ 2013 Jan 03 ] |
I like how groups done in Cisco ACS: GroupA.GroupB.GroupC Each subgroup (to the right), inherit security settings from parent group. If I let SysadminA read permission on In GUI for example if I look hosts in "GroupB" il get summary host list form GroupA.GroupB, GroupA.GroupB.GroupC, GroupA.GroupB.GroupE groups Any group can have hosts, As for making change compatible with current system ? It is compatible, current Groups will become root Groups. |
Comment by Stefan [ 2013 Aug 21 ] |
any news about that? will it exist in zabbix 2.2? |
Comment by Stefan [ 2013 Nov 28 ] |
why you dont add a column something like 'parent(NULL)' otherwise you can use ltree |
Comment by Ghozlane TOUMI [ 2014 Jan 03 ] |
As a workaround, I have a patch that adds a 1 level grouping for groups, maps and screens. |
Comment by Marc [ 2014 Jan 03 ] |
ghoz, why not attaching the patch/images to this ticket? |
Comment by Ghozlane TOUMI [ 2014 Jan 03 ] |
Meh.. the patch doesn't really answer the feature request, it's just a cosmetic / usability improvement... |
Comment by Adail Horst [ 2014 Jan 04 ] |
Yeap.... the patch is only a cosmetic. to solve this is required change the database + API. Because the relation between groups is not so "named logical". |
Comment by Marc [ 2014 Jan 04 ] |
Sure. Anyhow, I think it addresses the issue and might for some be beneficial in comparison to have nothing. |
Comment by Adail Horst [ 2014 Jan 04 ] |
Yeap. Is a good temporary soluction for a specific cenario. |
Comment by Dawid van Wyngaard [ 2014 Mar 27 ] |
Zabbix Dev Team, Any indication when this feature / fix will be implemented in a next release? Zabbix 2.4? If so, what is the time frame for this feature enhancement / request to be released? Thanks, Dawid |
Comment by richlv [ 2014 Mar 27 ] |
this is currently not on the roadmap |
Comment by jj [ 2015 Mar 20 ] |
this would be great |
Comment by James Vajoumounien [ 2015 Nov 02 ] |
+1 |
Comment by Marc [ 2015 Nov 06 ] |
as richlv already said, it's not on the roadmap yet. |
Comment by J. van Stijn [ 2015 Dec 13 ] |
+1 for me! This would be so helpful! |
Comment by Oleg Egorov (Inactive) [ 2016 Aug 17 ] |
(1) [A] Possible to create host group with name "test//test" RESOLVED IN r61767 iivs Possible to create "test/test/" with ending slash. REOPENED gunarspujats RESOLVED in r61896 iivs CLOSED |
Comment by Oleg Egorov (Inactive) [ 2016 Aug 18 ] |
(2) [F] I have groups: Issues:
Only if searching by "///*" multiselect return correct result. Function naming for multiselect, removeSubgroupPostfix and hasSubgroupPostfix please change to removeSubGroupPostfix and hasSubGroupPostfix gunarspujats RESOLVED in r61788 iivs The order of host groups is incorrect when child is added first and parent is added afterwards. REOPENED gunarspujats As discussed with sasha it's not a regression. WON'T FIX. |
Comment by Ivo Kurzemnieks [ 2016 Aug 19 ] |
(3) [F] I have a host group named "A". Type "A" in multiselect. See many choices to choose from. It looks for also "a" in any name. Choose something else using mouse and click. The group "A" gets selected anyway. gunarspujats RESOLVED in r61815 iivs Seems to work, but now there is a different problem. Let's say we start typing "Latvia" and navigate with arrow key down to "Latvia/Riga", but I change my mind and click with mouse "Latvia/Venstpils" instead. The name "Latvia/Riga" is cleared, but "Latvia/Venstpils" was not chosen. This problem appears on FF. Chome, Opera and latest IE works fine. REOPENED gunarspujats RESOLVED in r61870 iivs CLOSED |
Comment by Ivo Kurzemnieks [ 2016 Aug 19 ] |
(4) [F] Translation string changes.
Strings deleted:
gunarspujats CLOSED |
Comment by Oleg Egorov (Inactive) [ 2016 Aug 22 ] |
(5) [F] Error after adding new element via multiselect in user group permission tab. Trying to add permissions for user group "Zabbix Administrators".
oleg.egorov & iivs RESOLVED IN r61813 iivs Problem was due to PHP < v5.6 function array_fill() works a bit differently. |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(7) [F] Controls are not properly aligned
PavelA RESOLVED in r61827 iivs Older IEs had problems with radio buttons displayed at the bottom. sasha RESOLVED in r61895, r61901 iivs CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(8) [F] Cannot add permissions to a Group/* 1. Open Permissions tab in "Zabbix administrators" user group oleg.egorov Don't work numeric host group in User group permission tab iivs No, it's not a numeric problem. The groups with default permissions "None" were not displayed and all other groups had same permissions. The problem was with groups that have no parent and the "all permissions are the same" was not calculated properly for them. sasha CLOSED |
Comment by Andris Zeila [ 2016 Aug 22 ] |
(9) [I] Create database patch to increase groups.name and group_prototype.name fields to 255 characters. sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(10) [F] The length of host group name and host group prototype name must be increased to 255 chars iivs The limit is increased to host group names. Host group prototype names are generated by macros. sasha The length of these fields are not updated:
REOPENED iivs RESOLVED in r61828 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(11) [F] usrgrps.php: these input parameters are not used and can be removed users, new_right, right_to_del, group_users_to_del, register, del_user_group, del_user_media, del_group_user, change_password, cancel iivs RESOLVED in r61826 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(12) [F] Checkboxes always unchecked now in User group form iivs RESOLVED in r61835 sasha Second checkbox (debug_mode) also always unchecked REOPENED iivs RESOLVED in r61843 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(13) [F] Already deleted users appears in the user list when error occurred while updating user group iivs RESOLVED in r61836 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(14) frontends/php/usergrps.php:390 $dbUsers = DBselect( 'SELECT DISTINCT u.userid '. ' FROM users u,users_groups ug '. ' WHERE u.userid=ug.userid '. ' AND ug.usrgrpid='.zbx_dbstr($data['usrgrpid']) ); while ($dbUser = DBfetch($dbUsers)) { $data['group_users'][$dbUser['userid']] = $dbUser['userid']; } if (hasRequest('form_refresh')) { $data['group_users'] = getRequest('group_users', []); }
iivs RESOLVED in r61844, r61846
REOPENED iivs RESOLVED in r61849 sasha when create new user group Undefined index: group_users [usergrps.php:610 → CView->render() → include() in include/views/administration.usergroups.edit.php:51] REOPENED iivs RESOLVED in r61854 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(15) [F] frontends/php/usergrps.php:404 $db_rights = DBselect( 'SELECT r.rightid,r.permission,r.groupid AS user_groupid,g.groupid AS host_groupid,g.name'. ' FROM groups g'. ' LEFT JOIN rights r ON r.id=g.groupid AND r.groupid='.zbx_dbstr($data['usrgrpid']) ); while ($db_right = DBfetch($db_rights)) { $data['group_rights'][$db_right['name']] = [ 'rights' => ($db_right['rightid'] == 0) ? PERM_NONE : $db_right['permission'], 'name' => $db_right['name'], 'host_groupid' => $db_right['host_groupid'] ]; } $data['group_rights'] = getRequest('group_rights', $data['group_rights']);
iivs RESOLVED in r61847 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(16) [F] Why one entity has several names?
sasha RESOLVED in r61866 iivs CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 22 ] |
(17) [F] frontends/php/usergrps.php:449
if ($ms_ids) { $new_permissions = array_fill(0, count($ms_ids), $data['new_permission']); $ms_ids = array_combine($ms_ids, $new_permissions); } if ($ms_groupids) { $new_permissions_groups = array_fill(0, count($ms_groupids), $data['new_permission']); $ms_groupids = array_combine($ms_groupids, $new_permissions_groups); } iivs RESOLVED in r61848 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 23 ] |
(18) [F] $data['usrgrp'] is not used in the view. It can be rewritten using a local variable. iivs RESOLVED in r61850 sasha CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 23 ] |
(19) [F] implemented alternative solution to manage user group permissions. Тhe code was reduced by 143 lines. RESOLVED in r61866 iivs Group list gets corrupted and undefined indexes appear in host group form upon error. REOPENED sasha RESOLVED in r61868 iivs The alternative solution works a bit differently now. A child group that has permissions "NONE" and no direct parent, is displayed in the list.
REOPENED sasha Thanks! RESOLVED in r61891 iivs Nice work. |
Comment by Oleg Egorov (Inactive) [ 2016 Aug 23 ] |
(20) [F] Multiselect in host mass update form suggest new elements.
gunarspujats As discussed with sasha hostgroup name validation is done on API side. |
Comment by Alexander Vladishev [ 2016 Aug 23 ] |
(21) [F] Added new function getMultiselectGroupIds(). Old function findParentAndChildsForUpdate() must be removed. gunarspujats RESOLVED in r61878 sasha TESTED Have a look at my changes in r61894 iivs CLOSED |
Comment by Andris Zeila [ 2016 Aug 24 ] |
(22) [S] Groups created by server during low level host discovery must inherit permissions from their direct parents. sasha CLOSED with small fix in r61927 |
Comment by Alexander Vladishev [ 2016 Aug 24 ] |
(23) [S] syntax of the new groups must be validated RESOLVED in r61922 sasha CLOSED |
Comment by Ivo Kurzemnieks [ 2016 Aug 25 ] |
(24) [F] Is it supposed to be like this? sasha RESOLVED in r61944 iivs Thanks! CLOSED |
Comment by Alexander Vladishev [ 2016 Aug 25 ] |
Server side was successfully tested! |
Comment by Ivo Kurzemnieks [ 2016 Aug 25 ] |
Frontend tested |
Comment by Alexander Vladishev [ 2016 Aug 25 ] |
Available in pre-3.2.0beta1 r61951. |
Comment by Ivo Kurzemnieks [ 2016 Aug 26 ] |
(25) [D] API documentation added gunarspujats CLOSED |
Comment by Filipe Paternot [ 2016 Aug 30 ] |
Question: a calculated item works on toplevel group and includes all items below it? |
Comment by richlv [ 2016 Aug 30 ] |
fpaternot, did you mean an aggregate item ? |
Comment by Filipe Paternot [ 2016 Aug 30 ] |
Yes @richlv. Aggregate checks using group functions like grpsum/grpavg... Just to be accurate now, https://www.zabbix.com/documentation/3.0/manual/config/items/itemtypes/aggregate |
Comment by richlv [ 2016 Aug 30 ] |
that's a good question which one might or might not have been able to find out in the specification |
Comment by Dimitri Bellini [ 2016 Sep 12 ] |
Hi, i have now checked on zabbix 3.2.0rc1 but i don't understand how dos it work. from my test this flow is not possible, is correct? The only way to work seems to assign the single host to both "host Group", one called "Linux" and another one called "Prod/Linux" but i do not understand what benefit we have to the old implementation, may be using through API? |
Comment by Dimitri Bellini [ 2016 Sep 12 ] |
Nested Host Group View |
Comment by Ivo Kurzemnieks [ 2016 Sep 12 ] |
Hello, dimitri.bellini! No, hosts are not inherited. The inheritance works for permissions and only forward. Meaning that first a parent group must be created. Then, when creating a child group, it will inherit permissions from parent group. If a child group was created first, and then the parent group, permissions to parent group are not inherited from child group. And for example, let's say that a parent group "Prod" has read permissions and a group "Prod/Linux" has read-write permissions. Then creating, a new group "Prod/Windows" this group will gain read permissions from parent. And so will the hosts in this group. Changing permissions to "Prod" we have option to overwrite permissions to all child groups or only the parent group. Which means that future child groups will have different permissions. Hosts, however, can be assigned to multiple groups just like before. And only highest permission from all groups is taken into account. No changes there. |
Comment by Dimitri Bellini [ 2016 Sep 12 ] |
Hi Ivo, PS: At the conference on Alexei's speech, i have supposed he talked to a real Nested Host Group solutions |
Comment by richlv [ 2016 Sep 12 ] |
i'm a bit concerned about this part :
how transparent is this ? it seems that user would have no indication on what's going on there. regarding host membership, i'd have to agree with dimitri.bellini - if actual membership is not included in this issue, that prevents aggregate items, unsupported item count items and a few more features from working as expected. it should be clearly documented. in this case, a specification would have helped to set the expectations right. |
Comment by Martins Valkovskis [ 2016 Sep 13 ] |
(27) [D] Documentation for this feature has been clarified: RESOLVED sasha Excellent! But information about new possibilities of a filtration is missing. I.e. in multiselects we can select group with all subgroups. For example: Latvia/* or Latvia/Riga/*. Scope: REOPENED martins-v Updated sections:
RESOLVED iivs Looks good to me. |
Comment by Dimitri Bellini [ 2016 Sep 13 ] |
Hi Martins, |
Comment by Martins Valkovskis [ 2016 Sep 13 ] |
Dimitri, |
Comment by Dimitri Bellini [ 2016 Sep 13 ] |
Hi Martin, |
Comment by richlv [ 2016 Sep 19 ] |
looks like "Fix Version/s" has not been set for this issue, and it is still in an "open" state. |
Comment by richlv [ 2016 Sep 19 ] |
this introduced a typo in a variable name : |
Comment by Dimitri Bellini [ 2016 Sep 21 ] |
As discussed with Alexei Vladishev, this new feature is the real implementation of the "Nested Host Group" and is not only limited to "permissions". So i hope in a new implementation for the Web Frontend (better user experience) maybe on zabbix 3.2.1 or 3.4. |
Comment by Aleksandrs Saveljevs [ 2016 Sep 21 ] |
Not sure, but maybe |
Comment by Dimitri Bellini [ 2016 Sep 21 ] |
Yes it is another Web Frontend handicap of the actual implementation but for example is not possible to disable/enable all hosts of a main HostGroup A. Below example Main Group : Production From Zabbix Configuration->Host Group i will supposed to view all hosts belong to "Production" provided by the two subgroup "Linux" and "Windows" for a total of 15 hosts. Actually we see a void "Production" hostgroup and other two host group. So a better Web Frontend implementation is need for the User, this my personal opinion |
Comment by Mehmet Ali Buyukkarakas [ 2017 Mar 14 ] |
Personally I have also opinions and feelings about the nested groups. Its very usefull and one of the biggest tactical things about managing lots of hosts and objects. But not that way. 'Nesting' means for me also grouping and filtering. When I saw the results of this issue, first I didnt understood the reason. Today either.... Thank you for your effort but we need a real and working nested group design. Best regards. |
Comment by J. van Stijn [ 2017 Apr 28 ] |
Ok, so I just finished my long postponed upgrade to 3.2.5 I was wondering why the "nested groups" thing wasn't working as I was expecting. It's a bit strange that the current item is closed because the implementation doesn't fit the original description at all. Oh well. At least it's a step in the right direction. Can't wait for some real nested (intuitive) group feature. |