I am having issues with some custom properties that i have added to the MDT database for scripting Out Of Band management.
They have been successfully added to the database, the view has been refreshed and from the MDT management workbench i am also able to see the custom properties.
I have also successfully injected values from my prestaging script as can also be seen from the screenshot.
The issue is, when i try to fetch the values from the database, they return blank.
In my customsettings.ini i have also added the properties:
[Settings]
Priority=CSettings, CRoles, RSettings, TaskSequenceID, Default
Properties=OOBIPAddress, OOBSubnetmask, OOBGateway, OOBPassword
The script i am using to try to fetch the properties looks as follows
if($MDTIntegration -eq "YES"){ $OOBIPAddress = $tsenv.Value("OOBIPAddress") $OOBSubnetmask = $tsenv.Value("OOBSubnetmask") $OOBGateway = $tsenv.Value("OOBGateway") Write-Output "$ScriptName - IP Address: $OOBIPAddress" Write-Output "$ScriptName - Subnet Prefix Length: $OOBSubnetmask" Write-Output "$ScriptName - Gateway: $OOBGateway"}
If i use the same script for some of the built-in properties, they return just fine and as expected:
if($MDTIntegration -eq "YES"){ $IPAddress = $tsenv.Value("OSDAdapter0IPAddressList") $Subnetmask = $tsenv.Value("OSDAdapter0SubnetMask") $Gateway = $tsenv.Value("OSDAdapter0Gateways") Write-Output "$ScriptName - IP Address: $IPAddress" Write-Output "$ScriptName - Subnet Prefix Length: $Subnetmask" Write-Output "$ScriptName - Gateway: $Gateway"}
Both scripts are making use of the $tsenv = New-Object -COMObject Microsoft.SMS.TSEnvironment. So it has something to do with the properties in some way.
I am totally puzzled and have used so many hours to find out why - on the edge of giving up.
Maybe it is something simple - i really hope you guys have an answer - 'cause i'm tearing out my hair!
Findings:
Although I have refreshed the view as suggested in many articles that describe adding custom values, i do not see the new values in the actual updated view. Here in stead is a long list of properties specified. But not those added. Could this have something
to do with it?