I have used this script several times to bulk import users into AD, but now it seems to slow down considerably. It works fine as the information is correct. I am typically importing around 300-400 users. Is there a way to speed up my bulk
import of AD users? Example of script below:
cd \Create-Users
Import-Module *active*
$adusers = Import-csv c:\Create-Users\adusers.csv
foreach ($user in $adusers)
{
$username = $user.username
$password = $user.password
$firstname = $user.firstname
$userprinicpalname = $user.firstname + "@xxx.xxx.com"
$description = $user.description
new-aduser -samaccountname $username -UserPrincipalName $userprinicpalname -DisplayName $firstname -Description $description -name $firstname -givenname $firstname -enabled $true -accountpassword (convertto-securestring
$password -asplaintext -force) -PasswordNeverExpires $true
}