1.
啟用Lync : 單一用戶(以LyncUser1為例)
Enable-CsUser -Identity "LyncUser1" -RegistrarPool pool.lync.com -SipAddress sip:lyncuser1l@lync.com
Enable-CsUser -Identity "LyncUser1" -RegistrarPool pool.lync.com -SipAddress sip:lyncuser1l@lync.com
2.
啟用Lync : 以OU整批啟用
Get-CsAdUser -OU "ou=demo,dc=lync,dc=com" | Enable-CsUser -RegistrarPool " pool.lync.com " -SipAddressType EmailAddress -SipDomain lync.com
Get-CsAdUser -OU "ou=demo,dc=lync,dc=com" | Enable-CsUser -RegistrarPool " pool.lync.com " -SipAddressType EmailAddress -SipDomain lync.com
3. 啟用LyncUser1的 Enterprise Voice
Set-CsUser -Identity "CN=lyncuser1,OU=demo,dc=lync,dc=com"
-EnterpriseVoiceEnabled $True -LineURI tel:+80014. 整批啟用Enterprise Voice, 試了很久, 最簡單的方式是用PowerShell:
需有一個Shell script : 例如: demo.ps1
匯入資料: 例如: user.csv
輸出結果到執行目錄上: AssignLineUri-yyyy-mm-dd-xxxx.txt 型式
a.將下列資訊存成: demo.ps1
param( [string] $importfile = $(Read-Host -prompt "Please enter a file name"))
$importedusers = Import-Csv $importfile
$transcriptname = "AssignLineUri-" + (Get-Date -Format s).replace(":","-") +".txt"
Start-Transcript $transcriptname
foreach ($importeduser in $importedusers)
{
$UserDN = "CN=" + $importeduser.SIPUser + ",OU=demo,dc=lync,dc=com"
Set-CsUser -identity $UserDN -EnterpriseVoiceEnabled $True -LineUri $importeduser.LineUri –Verbose
}
Stop-Transcript
b.將使用者資訊及話機號碼設成: User.csv
SIPUser,LineUri
lyncuser1,tel:+8001
lyncuser2,tel:+8002
c. 操作方式:
於Start =>Lync Server management shell => <shell directory>\demo.ps1
輸入: user.csv
查看結果
其他簡體的啟用範例:
http://bbs.winos.cn/archiver/tid-117393.html
PowerShell 的啟用範例:
http://blogs.technet.com/b/csps/archive/2010/06/10/scriptmoveusers.aspx
http://blogs.technet.com/b/csps/archive/2010/06/10/scriptassignlineuris.aspx
沒有留言:
張貼留言