Condividi tramite


Cmdlets and Commands used in SCR Blogcast

One of my colleagues at work suggested that I post the cmdlets and other commands I used in my SCR blogcast.  Here they are, organized according to which part in the blogcast they were used:

Part 2

  • Enable-StorageGroupCopy e2k7\sg1 -StandbyMachine e2k7dr -ReplayLagTime 0.0:0:0
  • Get-StorageGroupCopyStatus e2k7\sg1 -StandbyMachine e2k7dr

Part 3

  • New-StorageGroup -Server e2k7dr -name SG1Port -LogFolderPath C:\SG1Port -SystemFolderPath C:\SG1Port
  • New-MailboxDatabase -StorageGroup e2k7dr\sg1port -Name MBX1Port -EdbFilePath C:\SG1Port\MBX1Port.edb
  • Mount-Database MBX1Port
  • Dismount-Database MBX1Port -Confirm:$False
  • Del C:\SG1Port\*.*

Part 4

  • Dismount-Database e2k7\sg1\mbx1 -Confirm:$False
  • Restore-StorageGroupCopy e2k7\sg1 -StandbyMachine e2k7dr
  • Eseutil /mh C:\SG1\MBX1.edb | findstr State
  • Eseutil /r E01
  • Eseutil /mh C:\SG1\MBX1.edb | findstr State
  • Move-StorageGroupPath e2k7dr\sg1port -SystemFolderPath C:\SG1 -LogFolderPath C:\SG1 -ConfigurationOnly -Confirm:$False
  • Move-DatabasePath e2k7dr\sg1port\mbx1port -EdbFilePath C:\SG1\MBX1.edb -ConfigurationOnly -Confirm:$False
  • Set-MailboxDatabase e2k7dr\sg1port\mbx1port -AllowFileRestore:$true
  • Mount-MailboxDatabase MBX1Port\

Part 5

  • Get-Mailbox -Database e2k7\sg1\mbx1 |where {$_.ObjectClass -NotMatch '(SystemAttendantMailbox|ExOleDbSystemMailbox)'} | Move-Mailbox -ConfigurationOnly -TargetDatabase e2k7dr\sg1port\mbx1port -Confirm:$False

Comments