SOLVED Only one computer in group


  • Sorry, I don’t know how to put a screenshot. A Show create table is better

    CREATE TABLE `groupMembers` (
     `gmID` int(11) NOT NULL AUTO_INCREMENT,
     `gmHostID` int(11) NOT NULL,
     `gmGroupID` int(11) NOT NULL,
     PRIMARY KEY (`gmID`),
     UNIQUE KEY `gmHostID` (`gmGroupID`),
     UNIQUE KEY `gmHostID_2` (`gmHostID`,`gmGroupID`),
     KEY `gmHostID_3` (`gmHostID`)
    ) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
    

    This index seems to be wrong: UNIQUE KEY gmHostID (gmGroupID)

    Is it the problem? I can remove it and test it but I wait your answer.

    Thanks,

    Zaza.


  • I’m moving this post to FOG Problems as this is not a bug.

    My guess @Zaarin, your going to find your groupMembers table has a few either: gmID = 0, or gmGroupID = 0.


  • @Zaarin There’s probably something in your DB that is breaking the process then. If you can use something like HeidiSQL or phpMyAdmin to put eyes on the actual data, maybe you’ll find something strange?


  • Hi,

    Maybe this can help you. I tried again and same problem. This time, I took only two computers and tried from the HostManagement.

    160510 14:38:33   179 Change user       root@localhost on
                      179 Query     SET NAMES utf8
                      179 Init DB   fog
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT `vValue` FROM `schemaVersion`
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`hosts`.`hostID`) AS `total` FROM `hosts` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SET SESSION group_concat_max_len=(1024 * 10)
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'fog' AND ENGINE != 'MyISAM'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `plugins`  WHERE `plugins`.`pInstalled`='1' AND `plugins`.`pState`='1'  ORDER BY LOWER(`plugins`.`pName`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_VIEW_DEFAULT_SCREEN'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_FTP_IMAGE_SIZE'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`hosts`.`hostID`) AS `total` FROM `hosts`WHERE `hosts`.`hostPending`='1' LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`hostMAC`.`hmID`) AS `total` FROM `hostMAC`WHERE `hostMAC`.`hmPending`='1' LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_DATA_RETURNED'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`users`.`uId`) AS `total` FROM `users` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`groups`.`groupID`) AS `total` FROM `groups` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`images`.`imageID`) AS `total` FROM `images` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`snapins`.`sID`) AS `total` FROM `snapins` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT COUNT(`printers`.`pID`) AS `total` FROM `printers` LIMIT 1
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_HOST_LOOKUP'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_MEMORY_LIMIT'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_FORMAT_FLAG_IN_GUI'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_SNAPINDIR'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_REPORT_DIR'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_TZ_INFO'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_TZ_INFO'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM users  WHERE uId='1'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_INACTIVITY_TIMEOUT'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_REGENERATE_TIMEOUT'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_ALWAYS_LOGGED_IN'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_THEME'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `globalSettings`  WHERE `globalSettings`.`settingKey`='FOG_PLUGINSYS_ENABLED'  ORDER BY LOWER(`globalSettings`.`settingKey`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM taskTypes  WHERE ttID='2'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM taskTypes  WHERE ttID='1'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM taskTypes  WHERE ttID='8'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM groups  WHERE groupID='1'
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `groupMembers`  WHERE `groupMembers`.`gmGroupID`='1'  ORDER BY `groupMembers`.`gmID` ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     INSERT INTO groups (`groupID`,`groupName`,`groupDesc`,`groupCreateBy`,`groupDateTime`,`groupBuilding`,`groupKernel`,`groupKernelArgs`,`groupPrimaryDisk`) VALUES ('1','Deploy Don Vista FR','','fog','2016-05-10 07:38:27','0','','','') ON DUPLICATE KEY UPDATE `groupID`='1',`groupName`='Deploy Don Vista FR',`groupDesc`='',`groupCreateBy`='fog',`groupDateTime`='2016-05-10 07:38:27',`groupBuilding`='0',`groupKernel`='',`groupKernelArgs`='',`groupPrimaryDisk`=''
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `groupMembers`  WHERE `groupMembers`.`gmGroupID`='1'  ORDER BY `groupMembers`.`gmID` ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `hosts`  LEFT OUTER JOIN `hostMAC` ON `hostMAC`.`hmHostID`=`hosts`.`hostID`  LEFT OUTER JOIN `images` ON `images`.`imageID`=`hosts`.`hostImage`   WHERE `hostMAC`.`hmPrimary` = '1' ORDER BY LOWER(`hosts`.`hostName`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `groupMembers`  WHERE `groupMembers`.`gmGroupID`='1'  ORDER BY `groupMembers`.`gmID` ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     SELECT * FROM `hosts`  LEFT OUTER JOIN `hostMAC` ON `hostMAC`.`hmHostID`=`hosts`.`hostID`  LEFT OUTER JOIN `images` ON `images`.`imageID`=`hosts`.`hostImage`  WHERE `hosts`.`hostID` IN ('3') AND `hostMAC`.`hmPrimary` = '1' ORDER BY LOWER(`hosts`.`hostName`) ASC
                      179 Query     SET SESSION sql_mode=''
                      179 Query     INSERT INTO groupMembers (`gmHostID`,`gmGroupID`) VALUES ('3','1') ON DUPLICATE KEY UPDATE `gmHostID`='3',`gmGroupID`='1'
    

  • Unable to replicate. I went to Group->List All->Choose any group->Membership. Checked the hosts I wanted to add, all added successfully and were able to be removed and re-added and removed, just in case.

    I also went to Host->List All->Select hosts I want in group->Choose group to “process group changes” and updated. All hosts I selected were able to be added successfully.

306
Online

10.1k
Users

16.3k
Topics

149.5k
Posts