for /f "skip=1 eol=; tokens=1-9 delims=, " %a in (C:User.csv) do dsadd user cn=%a,OU=test,dc=domain,dc=com -upn %b@sdeer.com -samid %c -pwd %d -company %e -dept %f -mustchpwd no -disabled no黄色部门进行修改,第一处,员工信息表存放路径,第二处,所在 OUUser.csv 模板如下批量启用Exchange邮箱账户打开 Exchange Powershellget-user –OrganizationalUnit service | where-object{$_.RecipientType –eq “User”}目标 OU 需要修改,查看目标路径是否正确get-user – OrganizationalUnit service | where-object{$_.RecipientType – eq “User” } | Enable-Mailbox – Database “services” | get-mailbox | select name,windowsemailaddress,database
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)