Jump to content


bastiitsab

Established Members
  • Posts

    3
  • Joined

  • Last visited

Everything posted by bastiitsab

  1. The challenge was to move the Computers in the correct OU. The Computer naming convention are: XXX000 (3 Letters for City Code, 3 enumerating digits). So the PS Script identifies the OU of the first 3 characters. The LDAP String is hardcoded for the selected OU and is set as TS Variable "OSDJoinDomainOUName" So this is the PowerShell Script, $myComputername = $env:computername $myComputernameShort = $myComputername.Substring(0,3) switch ($myComputernameShort) { "FRA" {$LDAPValue = "LDAP://OU=Computers,OU=Frankfurt,DC=company,DC=de"} "BER" {$LDAPValue = "LDAP://OU=Computers,OU=Berlin,DC=company,DC=de"} "HAM" {$LDAPValue = "LDAP://OU=Computers,OU=Hamburg,DC=company,DC=de"} default {$LDAPValue = ""} } $tsenv = New-Object -COMObject Microsoft.SMS.TSEnvironment $tsenv.Value("OSDJoinDomainOUName") = $LDAPValue With this TS Variable, you can now set the OU to this Varialbe. And your Clients join in the given OU! Hope this will help you!
  2. Hi, I havent solved the problem with this script. I have created a new Powershell script to do this for me. If you are interested in this solution I can post it here...
  3. Hi, i'm very frustraded with my SCCM OSD Task Sequence (win 8.1). Im working with the MoveToOu VBscript from the Coretech guys. http://blog.coretech.dk/jgs/vbscript-move-computer-object-to-another-ou-via-command-line-parameter/ But it isnt working. I have googled for hours, or days now. I hope you can help me out of this... I have tested many solutions found in the web. Testing various orders from TS Doing Restart before or After the Script Running the Script with a Batch file Nothing worked for me. After the OSD i can manually run the script with the given Domain account. Here are serveral Errors from the smsts.log.. Cscript-Fehler: Skriptmodul "VBScript" fr Skript "C:_SMSTaskSequence\Packages\P010002b\MoveOu.vbs" wurde nicht gefunden. (Csript-Error: Scriptmodule "VBScript" for Script "..." was not found) failed to get the linked token information. It may not be available. Error 1312 Thanks in advance
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.