Share via


Can't export mailbox - Permission is denied

Question

Monday, October 28, 2019 1:50 PM

I moved my mailbox export archive from a freenas to a windows file server and now I am not able to do a New-MailboxExportRequest I get "Unable to open PST file \Fileserver\Mail Repository\User Mailboxes\Discontinued users\user.pst Error details: access to the path \Fileserver\Mail Repository\User Mailboxes\Discontinued users\user.pst is denied.

I have checked and Exchange Trusted Subsystem has full control of the folder as does the domain admins as well as local admin accounts. same as they were on the NAS. I can browse to the folder and read and write to it from explorer, but the power shell will not. Please help.

Jeremy Robertson Network Admin

All replies (12)

Friday, November 1, 2019 11:21 AM ✅Answered

Turns out that I had to add the exchange trusted subsystem read and write privileges to the share and not just the folder.

Jeremy Robertson Network Admin


Monday, October 28, 2019 1:54 PM

Hi.

Maybe this help you, please check permission for computer object "Exchange Server name" for this folder. 

MCITP, MCSE. Regards, Oleg


Monday, October 28, 2019 1:56 PM

? What are you asking me to check?

Jeremy Robertson Network Admin


Monday, October 28, 2019 2:01 PM

Please add permission to this folder for Computer object "Exchange Server name"

MCITP, MCSE. Regards, Oleg


Monday, October 28, 2019 2:21 PM

I added the exchange server computer object to the permissions list but get the same error.

Jeremy Robertson Network Admin


Monday, October 28, 2019 2:33 PM

1. Please check NTFS and Share permissions.

Mailbox imports and exports in Exchange Server

Before you import .pst files to mailboxes, or export mailboxes to .pst files, consider these issues:

You need to use a UNC network share (\ <Server>\ <Share>\ or \ <LocalServerName>\c$). The Exchange Trusted Subsystem security group requires permissions to the network share (Read for imports, Read/Write for exports). If the share doesn't have these permissions, you'll get errors when you try to import or export .pst files

2. Please Run As Administrator Exchange Power Shell

MCITP, MCSE. Regards, Oleg


Monday, October 28, 2019 8:20 PM

New-MailboxExportRequest -Mailbox <user> -FilePath "\<server FQDN>\shared folder name>\PST name>.pst"

This is the command I am using and have always used. I have never had to run as administrator as I am logged in as domain administrator but I tried it any way. Still no dice. same error.

Jeremy Robertson Network Admin


Tuesday, October 29, 2019 9:44 AM

Hi,

Could you open this shared location from your Exchange server with domain administrator privileges?

I would suggest you make sure this location could open successfully from Exchange server, then try to export data to it from EMS.

Regards,

Kyle Xu

Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact [email protected].


Tuesday, October 29, 2019 11:13 AM

Yes I can access the share from the exchange server with admin privileges but I cannot access the share from the exchange power shell

Jeremy Robertson Network Admin


Friday, November 1, 2019 8:25 AM

Did you run this command in EMS? As far as I know, if you could access this file from Exchange server without entry password, you will could read it from EMS.

Regards,

Kyle Xu

Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact [email protected].


Monday, November 4, 2019 1:41 AM

Glad to see that this issue has been solved, here is a summary about it:

Issue Symptom:

Cannot export data to a File server with “New-MailboxExportRequest” command.

(Possible) Cause:

Lack of read/write permissions.

Solution:

Shared this folder with "exchange trusted subsystem" read and write privileges. Because, this command reads/write data from/to a "\" shared location.

Regards,

Kyle Xu

Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact [email protected].


Monday, November 4, 2019 9:43 AM

Hello

1: ASSIGNING READ & WRITE PERMISSIONS
One of the reasons for the access path denied error is that the Exchange Trusted Subsystem does not have enough rights over the folder. You should grant the Exchange Server access to the shared drive (read and write permissions to the Exchange trusted subsystem group).

2: ADDING THE USER ACCOUNT TO A ROLE GROUP WITH MAILBOX IMPORT-EXPORT PERMISSIONS
New-ManagementRoleAssignment -Role "Mailbox Import Export" -User "<user name or alias>"

3:Here is an example of a mailbox export request, which backs up an entire mailbox to a PST file
New-MailboxExportRequest -Mailbox <user> -FilePath \<server FQDN>\shared folder name>\PST name>.pst