Solved

Exchange 2007 sp1 cmdlet

Posted on 2009-05-08
1
721 Views
Last Modified: 2012-05-06
i use the below command to take backup from exchange management shell
Get-Mailbox  -Database 'mbx\BusinessSG1\example2' | Export-Mailbox -excludeFolders '\deleted items','\Junk E-mail' -pstfolderpath E:\Backup\BS2 -confirm:$false

this cmdlets saves the mailbox backup in form of AlaisName.pst.
But There are few conflicts in alias names as we have couple of domain configured on same
exchange server.

Question.
Is there a way i can fetch the User Principal Name from Get-mailbox cmdlet of all mailbox users and then pass it on to export-mailbox command and then it can save it in format      UPN.pst
0
Comment
Question by:Raman_Goswami
1 Comment
 
LVL 49

Accepted Solution

by:
Akhater earned 500 total points
ID: 24347523
well that shouldn't be hard to do but you will have to do some tests


from the top of my head try this but it should be close


Get-Mailbox  -Database 'mbx\BusinessSG1\example2'| foreach { $PSTPath = "E:\Backup\BS2\" + $_.UserPrincipalName +".pst"; Export-Mailbox -excludeFolders '\deleted items','\Junk E-mail' -pstfolderpath $PSTPath -confirm:$false}

Open in new window

0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Easy CSR creation in Exchange 2007,2010 and 2013
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
In this video we show how to create a mailbox database in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Servers >> Data…
To show how to create a transport rule in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Rules tab.:  To cr…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now