Script to mount exchange 2007 database

Posted on 2016-10-11
Last Modified: 2016-10-16
Hello Experts

I need a script that I can schedule to mount an Exchange 2007 database (on a Windows 2008  server)
Can you please point me in the right direction.

Thank you

Question by:Alexandre Michel
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
LVL 16

Assisted Solution

by:Todd Nelson
Todd Nelson earned 250 total points
ID: 41839477
Are you looking for something like this to create a scheduled task to run an Exchange script?

In the PS1, you could have "Mount-Database -Identity "Mailbox Database"".

Author Comment

by:Alexandre Michel
ID: 41839506

That would be step 2 of the project: how to schedule running the script

The 1st step is the actual content of the script... How do I mount an Exchange database using Powershell or other scripting language

LVL 26

Accepted Solution

-MAS earned 250 total points
ID: 41839627
Create a batch file by copying the below command and save as .bat. You can change as per your location
powershell -command "&{C:\scripts\mountdatabase.ps1}"

Open in new window

Create a powershell script using the below command and save it
Get-MailboxDatabase -Server SERVERNAME | Mount-Database -Confirm:$False

Open in new window

Create a windows schedule task to run the batch file created above.


Author Comment

by:Alexandre Michel
ID: 41845867

Thanks for that.
At the end I did not try your solution as I found that simple restarting the Exchnage IS service acheived the same result.


Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lotus Notes – formerly IBM Notes – is an email client application, while IBM Domino (earlier Lotus Domino) is an email server. The client possesses a set of features that are even more advanced as compared to that of Outlook. Likewise, IBM Domino is…
Read this checklist to learn more about the 15 things you should never include in an email signature.
This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

690 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