...
Disable the "User Server Resource Discoverer"
I cannot rely on my Active Directory for importing
...
Users and need to import using the CMDB Import functionality
Whilst this problem has been acknowledged by Symantec development there is still no current fix to the issue.
There are ways to get around the issue however if the CMDB import populates the "Global Windows User" dataclass with the domain name and user id of the user being imported.
The Arellia suggests that the following three sql scripts will assist with the User Resource import without Resource Keys being populated issue:, and should check with your Symantec Support Representative before testing or applying any changes.
Code Block |
---|
lang | sql |
---|
title | Detect Imported Users that are a duplicate |
---|
lang | sql |
---|
|
selectSELECT \* fromFROM Inv_Global_Windows_Users GWU
WHERE EXISTS (
(selectSELECT 1 fromFROM ResourceKey RK JOIN Inv_Global_Windows_Users GWU2 ON RK where.ResourceGuid = GWU2._ResourceGuid
WHERE RK.KeyName = 'name.domain' and
AND RK.KeyValue= (UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain))
and AND RK.ResourceGuid != GWU._ResourceGuid
) |
Code Block |
---|
lang | sql |
---|
title | Detects Users populated with domain details that should have a resource key populated |
---|
lang | sql |
---|
|
selectSELECT \* fromFROM Inv_Global_Windows_Users GWU
WHERE NOT EXISTS (select (
SELECT 1 fromFROM ResourceKey RK JOIN Inv_Global_Windows_Users GWU2 ON RK where.ResourceGuid = GWU2._ResourceGuid
WHERE RK.KeyName = 'name.domain' and
AND RK.KeyValue= (UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain))
) AND UserId IS NOT NULL |
Code Block |
---|
title | Detects Users populated with domain details that have a Resource Key that does not match the correct calculated KeyValue |
---|
lang | sql |
---|
|
select GWU._ResourceGuid, 'name.domain', upper(GWU.UserId) + '.' + upper(GWU.Domain) AS KeyValue, RK.KeyValue as CurrentKeyValue
from Inv_Global_Windows_Users GWU
INNER JOIN ResourceKey RK ON RK.ResourceGuid = GWU._ResourceGuid AND RK.KeyName = 'name.domain'
WHERE
RK.KeyValue <> (upper(GWU.UserId) + '.' + upper(GWU.Domain)) |
Code Block |
---|
title | Inserts ResourceKeys for Users that have Domain details populated, but no corresponding resource Key exists |
---|
lang | sql |
---|
|
INSERT INTO ResourceKey(ResourceGuid, KeyName, KeyValue)
selectSELECT GWU._ResourceGuid, 'name.domain', UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain)
fromFROM Inv_Global_Windows_Users GWU
WHERE NOT EXISTS (select
SELECT 1 fromFROM ResourceKey RK where
WHERE RK.KeyName = 'name.domain' andAND RK.KeyValue = (UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain))
) AND UserId IS NOT NULL |
Code Block |
---|
title | Updates ResourceKeys for Users that have Resource Key that do not match the upper case domain details |
---|
lang | sql |
---|
|
UPDATE ResourceKey SET KeyValue = UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain)
FROM Inv_Global_Windows_Users GWU
WHERE
GWU._ResourceGuid = ResourceKey.ResourceGuid AND
KeyName = 'name.domain' AND
KeyValue <> (UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain))
AND NOT EXISTS (
SELECT 1 FROM ResourceKey RKC
WHERE RKC.ResourceGuid = ResourceKey.ResourceGuid
AND KeyValue = UPPER(GWU.UserId) + '.' + UPPER(GWU.Domain)
)
|