My name is Hussain with over 12 years of experience in IT field within Network Infrastructure, virtualization and datacenter operation. I'm a MCSA with Security, VCP3, VCP4, VCP5 and ITIL.

Homepage: http://dailyvmtech.wordpress.com

Migrating Veeam Backup to another Physical Server

Migrating Veeam Backup to another Physical Server

 I’m not going to make this post so complicated by explaining the bits and bytes of every step, but I’m listing below the steps in a very easy way;

  • Perform configuration backup on Veeam Server.
  • Install Veeam on the new physical server from scratch.
  • Import configuration that has been backed in step 1.
  • If you are using Veeam Backup to Backup Symantec Enterprise Vault, then you will have to install the Symantec EV Console on the new server in order to continue backing up Symantec Enterprise Vault. If not, you can ignore this step.
  • Move the scripts that run the Backup Jobs to the new Server, Export & Import.
      • Task Scheduler for all Backup Jobs Scripts;
        • Export & Import Tasks
        • Change Scripts path accordingly.
        • Re-enable the task scheduler in the new server.
        • Upgrade PowerShell to the latest version 3.0 WMI
        • Re-attach the Repository LUNs to the new server, and scan the Repositories to map the Backup Jobs.

, , ,

Leave a comment

Solution for Symantec Enterprise Vault when Unable to see the EV Toolbar in MS Outlook

Solution for Symantec Enterprise Vault when Unable to see the EV Toolbar in MS Outlook


Unable to see the EV Toolbar in the Outlook after the Mailbox moved within Exchange Database Findings & Cause: -Found Event ID 3357 This mailbox cannot be processed until the Exchange provisioning task has processed the corresponding user’s details. Ensure that a provisioning group includes this user and run the provisioning task. To disable these warnings, set the ‘HideMissingPolicyInfoErrors’ registry value to 1.

–It appears Hidden message is corrupted in the Mailbox


- EV server Version 9.0.2

- Zaped user mailbox as per articlehttp://www.symantec.com/docs/TECH35614

[Directory] DirectoryComputerName = evserver.Domain.com Sitename =  EV Site [Mailbox] DistinguishedName =  /o=OrganizationName/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=MailBoxName [Folder] Name = Mailboxroot Zap = True

Run the EVPM tool in the command prompt.

Run Enterprise Vault Policy Manager (EVPM) from \Program Files\Enterprise Vault (or \Program Files (x86)\Enterprise Vault) on the EV server logged on as the Vault Service Account (VSA). The syntax for EVPM follows:

Symantec EVPM2

  • - Enabled Mailbox to be provisioned for Archiving.
  • - EV tool bar is appears now but VC sync button not available
  • -Checked Mailbox log, Mailbox is running in online mode not cached mode
  • -Enabled Mailbox Cache Mode [pre-request for Vault Cache]
  • -Restarted Outlook, Sync button appears now.

, , , , , , , ,

Leave a comment

Operation failed, diagnostics report: iScsi Adapter in unbound status, adding Static Target can not be done.


You might see error in VMWare ESXi when LUN is created in EMC VNX3150 and you grant access to hosts that added to the VNXe3150.

Operation failed, diagnostics report: iScsi Adapter in unbound status, adding Static Target can not be done.

VNXe3150 Error in ESXi
This error is generated because EMC VNXe3150 try’s to add the iSCSI Servers/Targets that configured in the EMC VNX to each ESX that granted access to the LUNs. While the iSCSI Targets already added in the Dynamic/Static iSCSI Targets tab, this error is generated.

I think EMC should introduce some logic into the EMC VNXe3150 SAN Storage to initially check the Host if the iSCSI Targets already added, adding iSCSI targets via EMC should be ignored.

Or, VNXe3150 should loop through the storage pools/LUNs where it finds LUNs already presented to ESX hosts from the same Array, adding iSCSI Targets through EMC VNXe3150 should be ignored. Otherwise this fake error will keep presenting itself.

, , , ,

Leave a comment

Setting up & Configuring EMC VNXe3150 iSCSI SAN Storage with High.

Setting up EMC VNXe3150 iSCSI SAN Storage

Finally, the EMC VNXe3150 got installed and configured and almost ready to start transition from old EMC AX4 to the new VNXe3150. In the initial stage, found a bit difficulties to get it configured correctly as every EMC documentation speaks about something else specially when it comes to iSCSI High Availability, they mix between NFS HA and iSCSI HA. In reality, both Storage HA of NFS and iSCSI differ from each other. Simply, NFS uses Link Aggregations with LAG/LACP and iSCSI is not.


  • VNXe 3150 with dual storage processors with software version
  • Two Dell Stackable 6224 – 24 port Gigabit switches configured with Jumbo frames for iSCSI and Flow Control Enabled.
  • One – ESXi VMware ESXi 5.1.0 build-799733 host with 6 Gig pNIC’s two pNICs used for iSCSI connectivity only

Configuration on the VNXe

The configuration part is a bit of dilemma when it comes to iSCSI connectivity. In VNXe I set up two iSCSI Servers, one for Storage Processor A and one for Storage Processor B. Each SP has two IP Addresses configured for each Ethernet Interfaces, eth2 & eth3

iSCSI Server Settings-1

iSCSI Server Settings-2

iSCSI Server Settings-3








All the Ethernet Interfaces are configured with 9000 mtu size for Jumbo Frame;

MTU Config SPB

MTU Config SPB-eth3








Storage Resources Configuration

Storage Elements iSCSI Server Port IP Address MAC Address pSwitch Port VMKernel iSCSI PortGroup
iSCSI-A iSCSI_ServerA eth2 8:0:1b:57:71:3e 2/g1 iSCSI-01 vmk1
eth3 8:0:1b:82:78:dd 1/g1 iSCSI-02 vmk2
iSCSI-B iSCSI_ServerB eth2 8:0:1b:58:59:0f 2/g2 iSCSI-01 vmk1
eth3 8:0:1b:cd:f3:26 1/g2 iSCSI-02 vmk2

As you can see in the above screen shot and configuration table, each storage process have two Ethernet ports, each Ethernet port is connected to iSCSI pSwitch, eth2 in SPA matched eth2 in SPB. So since both of these interfaces are connected to the same pSwitch and same IP subnet is configured on both, single iSCSI VMkernel PortGroup on the same subnet can reach to both Storage Processors through single physical adapter “vmnic”

VNXe Connectivity Diagram

 VNXe Network Diagram










iSCSI Switches Configuration

Both network switches are configured as master and slave stackable switches, basically for this type of configuration you will not require to stack the switches as each of pair SP Ethernet are connected to the same switch. i;e SPA-Eth2 in pSwitch1 & SPB-Eth2 in pSwitch1. But with NFS configuration you will require to stack the Switches as you will need to configure LAG/LACP for true High Availability

Set up Jumbo Frames on the two iSCSI gig switches so that all the ports are using support Jumbo Frames. Below commands will let you configure all the ports with mtu size 9000

Console(config)#Interface range ethernet all

Console(config-if)#mtu 9000

ESXi host configuration

Each of the Gigs port in ESXi host is connected to the Physical iSCSI Switches. Two VMKernel PortGroups created in vSwitch1. Each of the iSCSI Kernels is mapped to the physical interface in ESXi.

Switch Name      Num Ports   Used Ports  Configured Ports  MTU     Uplinks

vSwitch1         128         8           128               9000    vmnic2,vmnic6

PortGroup Name        VLAN ID  Used Ports  Uplinks

iSCSI-02              0        1           vmnic6

iSCSI-01              0        1           vmnic2

vmk1       iSCSI-01            IPv4     00:50:56:6e:ea:87 9000    65535     true    STA                                  TIC

vmk2       iSCSI-02            IPv4    00:50:56:64:c0:6d 9000    65535

iSCSI vSwitch Ports

To check the connectivity is mapped correctly for each iSCSI PortGroup to reach the correct Ethernet Interface in the Storage Processor; vmkping with –I will allow you to specify the source interface to reach the destination iSCSI target; as this will test the whole path end-to-end from VNXe Storage, ESXi Hosts to Physical iSCSI Switches to make sure connectivity can flow with jumbo frame.

iSCSI Adapter Port Binding

Both iSCSI VMKernel portgroups has to be enabled for port bindings in the iSCSI Initiator adapter of ESXi.

iSCSI Port Bindings




Connectivity Results

# vmkping -I  vmk1 -c 50 -s 9000

PING ( 9000 data bytes

9008 bytes from icmp_seq=0 ttl=255 time=0.596 ms

9008 bytes from icmp_seq=1 ttl=255 time=0.575 ms

9008 bytes from icmp_seq=2 ttl=255 time=0.548 ms

— ping statistics —

3 packets transmitted, 3 packets received, 0% packet loss

round-trip min/avg/max = 0.548/0.573/0.596 ms

# vmkping -I vmk1 -c 50 -s 9000

PING ( 9000 data bytes

9008 bytes from icmp_seq=0 ttl=255 time=0.591 ms

9008 bytes from icmp_seq=1 ttl=255 time=0.617 ms

9008 bytes from icmp_seq=2 ttl=255 time=0.603 ms

# vmkping -I vmk2 -c 50 -s 9000

PING ( 9000 data bytes

9008 bytes from icmp_seq=0 ttl=255 time=0.634 ms

9008 bytes from icmp_seq=1 ttl=255 time=0.661 ms

9008 bytes from icmp_seq=2 ttl=255 time=0.642 ms

— ping statistics —

5 packets transmitted, 5 packets received, 0% packet loss

round-trip min/avg/max = 0.634/0.661/0.708 ms

# vmkping -I vmk2 -c 50 -s 9000

PING ( 9000 data bytes

9008 bytes from icmp_seq=0 ttl=255 time=0.694 ms

9008 bytes from icmp_seq=1 ttl=255 time=0.658 ms

9008 bytes from icmp_seq=2 ttl=255 time=0.690 ms

Add ESXi hosts to VNXe

Setup the ESXi hosts to access VNXe iSCSI SAN Storage. This can be done by browsing into the VNXe > Hosts > VMWare will allow you to find ESX hosts either by typing in the IP Address of the vCenter or the management network of the ESXi itself. Then create VMFS datastore on the VNXe and make sure you are assigning permission to the ESXi host to access the newly created LUN.

After the LUN is presented to the ESXi host and formatted with VMFS now it’s time to change the path selection through from default Fixed to Round Robin and change the Round Robin default IOPS limit in ESXi from 1000 to 1 which will allow you to utilize all the iSCSI paths.

esxcli storage nmp psp roundrobin deviceconfig set –type=iops –iops 1  –device=naa.6006048c2fb691695617fc52e06065a2

Once it’s change you will see all the paths with Active(I/O) for each LUN that changed from Fixed to Round Robin.

Path Round Robin




Failover – Failback Testing Scenarios

For the failover testing I have presented 500 GB LUN and created two Virtual Machines, and installed Windows 2008 R2 Enterprise Edition. Roles installed on this guest machine;

  • Microsoft Active Directory Role Services
  • Microsoft DNS Server Services
  • Exchange Server 2010 with all the Roles.

The second Virtual Machines are a Windows 7 Professional client with Microsoft Outlook 2010 connected to the Exchange 2010 MAPI profile. Sending and receive emails internally is operational in normal mode.

Testing Networking

I have tested failover with network issues scenarios by disconnecting one pNic “vmnic2” from the vSwitch1 that mapped to iSCSI-01 portgroup and at the same time vmkping –I vmk1 was running against both VNXe iSCSI Target IP’s SPA-Eth1 “” & SPB-Eth2 “” and ping continues well.  If a Storage Processor (SPA) fails/rebooted on VNXe, the working Storage Processor (SPB) picked up the workload that was handled by SPA.

Testing Networking-1

  • As you can see in the above screen shots, Virtual Machines Windows 7 Client continued pinging the Exchange Server and Exchange Server continued to ping Windows 7 Client.
  • Vmk1 = iSCSI-01 which mapped to vmnic2 stopped pinging to the SPA-Eth2 & SPB-Eth2.
  • LUN Paths both links mapped to vmnic2 subnet 10.90.8.x dead and 10.100.8.x paths mapped to vmnic6 ‘vmk2’ “iSCSI-02” are live and Active(I/O).

Path Round Robin-Failuer






Ping  “vmnic6” via vmk2 to &

# vmkping  -I vmk2

PING ( 56 data bytes

64 bytes from icmp_seq=0 ttl=255 time=0.229 ms

64 bytes from icmp_seq=1 ttl=255 time=0.192 ms

64 bytes from icmp_seq=2 ttl=255 time=0.238 ms

— ping statistics —

3 packets transmitted, 3 packets received, 0% packet loss

round-trip min/avg/max = 0.192/0.220/0.238 ms

~ # vmkping  -I vmk2

PING ( 56 data bytes

64 bytes from icmp_seq=0 ttl=255 time=0.235 ms

64 bytes from icmp_seq=1 ttl=255 time=0.245 ms

— ping statistics —

2 packets transmitted, 2 packets received, 0% packet loss

round-trip min/avg/max = 0.235/0.240/0.245 ms

Relink vmnic2 to vSwitch1 and ping resumed back to SPA-Eth2 & SPB-Eth2

ReLink vmnic2 vSwitch1









LUN paths resumed

Path Round Robin-Path Resumed







Testing Power Failure of VNXe Storage Processors-A & Storage Processor-B

The second test was done by removing the physical power from Storage Processor-B and initiate vmkping to both Ethernet Interface of SPB from both VMKernel vmk1 & vmk2, as a result vmkping continues as the traffic routed peer SP port.

Testing Power Failure







Result of ping after

Below result shows that Exchange VM continues to ping the Client VM during Storage Processor-B shutdown.

Result of Ping after SP-B Power Failure




Did the same with Storage Processor-A and initiated ping to both Ethernet Interfaces of SPA. Ping continues to both Ethernet Interfaces as well as pings inside each VM “Exchange Server to Client” and vice versa continues as well and Exchange Server VM didn’t give any freeze / errors in event viewer.


The VNXe3150 high availability feature at storage level and networking level ensures data protection against any single component failure in Storage Level and Networking Level.

, , , , , , , , , , ,

Leave a comment

Configuring NTP for VMWare vSphere Environment

NTP is a critical component in every network environment, especially when it comes to Virtualization. Because the entire Virtual Machines are relaying on the host to get the time. When the Domain Controller itself running as a Virtual Machine, cares must be taken of time synchronization between hosts, Virtualized Domain Controllers and other Virtual Machines.

In my environment, since the server vLAN has got access to the Public Internet, this wasn’t a big issue to get the synchronization done properly to the Domain Controllers.

Luckily, I have got two Domain Controllers one running as a Physical Server (PDC) and the second running as a Virtual Machine (ADC). In the initial stage, all the FSMO roles was configured on the Virtual Domain Controller, so the Virtual DC it’s holding the PDC emulator which is responsible for the domain hierarchy which means it’s responsible of the time service as well.

To get this done without the hassle of Time Protocols errors, below is the entire configuration.

  1. Backed up the Virtual DC with Veeam Backup & Replication”.
  2. Transferred the FSMO Roles from the Virtual DC to the Physical DC
  3. Configured the Physical DC to be responsible for the time service as per the MS article http://support.microsoft.com/kb/816042
  4. Configured the Virtual DC to obtain time from Physical DC.
  5. Now, since the majority of our servers are virtual running on VMWare vSphere the ESX configured to obtain the time from the same Physical DC
  6. In vSphere Client, configured the ESX with the Physical Domain Controller as NTP Server.
  7. Ran the ntpdate -q in ESX Server against the Physical Domain Controller
  8. Restart the ESX NTP Service ” service ntpd restart”
  9. Then watch “ntpq -p” to watch time drift in ESX Console.
  10. Domain Members Virtual Machines has been configured not to obtain the time from ESX host, but it’s configured on other VMs that are not member of the Domain.
  11. The time is probably synchronized from the Internet to our Virtual and Physical Servers.

, , , , , , ,

Leave a comment

Steps to Upgrade Veeam Backup & Replication v6.1.x to v6.5.0.109


I don’t want to go through a step by step procedure to upgrade from your current version of Veeam Backup & Replication to the latest version, but I would like to go through the procedure that I have followed in my environment and hope you will be benefit.

1. Stop Veeam Services.
2. Backup SQL Database
3. Upgrade SQL Express 2005 to SQL Express 2008 R2 by initiating this in the CMD SQLEXPR_x64_ENU.exe /action=upgrade
4. Once it’s done, start veeam Services.
5. Upgrade Enterprise Manager first if you are using it.
6. Upgrade Veeam Backup & Replication.
7. Launch Veeam Console and you will be prompt it with agent upgrade to upgrade the Repository Servers and Proxy Servers.
8. Just make sure everything is back to normal, jobs, logs, configuration run a job test to make sure everything is fine.

, , , ,

Leave a comment

Cannot add Windows PowerShell snap-in VeeamPSSnapin

You may encounter an error Cannot add Windows PowerShell snap-in VeeamPSSnapin when you run PowerShell scripts on Veeam Backup & Replication to start Backup Jobs after an upgrade from Veeam  Backup v6.x to v6.5


  • PowerShell Scripts scheduled via Task Scheduler doesn’t start automatically.
  • If you run the script manually via Veeam PowerShell snap-in VeeamPSSnapin, you will receive an error. Cannot add Windows PowerShell snap-in VeeamPSSnapin. But the job will start.


Upgrade to PowerShell 3.0 by installing Windows Management Framework 3.0 (http://www.microsoft.com/en-us/download … x?id=34595) which supports .Net 4.0 natively.

, , , , , , , ,

Leave a comment

Backup job failed. Cannot create a shadow copy of the volumes containing Exchange writer’s data.

Been facing the Exchange VSS Writer issue  when I backup my Exchange Server 2007 with Veeam Backup & Replication for quite sometime, and the only way to clear this out is by rebooting the Exchange Server or sometime it will pass through from the second or third job retry.

Last Friday 16th Nov, 2012 my Veeam Backup jobs suppose to run as Full Active Backup as per my configuration, Backup went fine for all the Backup Jobs, except the Backup Job which contains the Exchange Mailbox Server, it gives the usual error;

11/16/2012 8:43:20 PM :: Unable to release guest. Error: Unfreeze error: [Backup job failed.
Cannot create a shadow copy of the volumes containing writer's data.
A VSS critical writer has failed. Writer name: [Microsoft Exchange Writer]. Class ID: [{76fe1ac4-15f7-4bcd-987e-8e1acb462fb7}]. Instance ID: [{8ea7190d-337c-448f-b264-3401303b586b}]. Writer's state: [VSS_WS_FAILED_AT_FREEZE]. Error code: [0x800423f2].]

I have reboot it, and retry the job but no joy it didn’t help. I rebooted second and third time, but no joy The error is persistent.

I searched and searched for a solution but the usual result showed up, either reboot the server to clear the VSS writer Timed Out or restart the Microsoft Information Store which will clear the VSS Timed Out. I have done, both but without any luck.

I fed up from troubleshooting during my holiday and I left home for fishing. While I’m at the sea, my mind triggered out that why don’t you Exclude the C:\Drive of the Exchange VM and select only those drives which contains the Exchange Database?

Hummm, it seems it’s a brilliant idea. As soon as I reached home, I immideltly, logged in remotely again and I Excluded the C:\Drive VMDK SCSI (0:0) from the job and selected only those which contains the Exchange Database, “the disks are vRDM”;

SCSI (0:1)
SCSI (0:2)
SCSI (0:3)
SCSI (0:4)
SCSI (0:5)
SCSI (0:6)
SCSI (0:8)
SCSI (0:9)
SCSI (0:10)
SCSI (0:11)
SCSI (0:12)
SCSI (0:13)
SCSI (0:14)
SCSI (0:15)
SCSI (1:0)
SCSI (1:1)
SCSI (1:2)
SCSI (1:3)
SCSI (1:4)
SCSI (1:5)
SCSI (1:6)
SCSI (1:8)

Imagine, the Job passed the Snapshot Process so fast and I’m surprised that the job is started reading :) and the Exchange Database has been put in Backup Mode and the backup Speed is a bit faster 1.6 TB finished in 4 Hours :)

Why Excluding the SCSI (0:0) which is the C:\SystemDrive of the Exchange 2007 Virtual Machine and Including only the vRDM SCSI Drives the process will pass successfully without VSS Error or Timed Out?

What is the restoration impact of Backing up only the those drives where the Exchange Database resides without the the C:\Drive SCSI (0:0).

Will it be possible configuring another job against the Exchange VM to backup only the C:\Drive SCSI (0:0) without the rest of other drives? And when I want to restore it, I have to restore the Job which contains the C:\Drives and followed by the other Job which backed up the Database Drives?

I can confirm that, I have Selected All Disks to process under the Disk Exclusions and the job Failed. But I have amended the Selection and I included SCSI (0:0) which contains the Virtual Machine System Drive and the backup successful.
I think the reason why it didn’t work when the All Disks radio button is selected but it does when the SCSI Disks are selected including the SCSI (0:0) which includes the System Drive.

The Virtual Machine is limited to 60 Virtual SCSI Controllers/Targets and when Veeam Backup is initiating job to process the Backup, it creates a Loop within the SCSI Controllers selected in the VM. If any drives / SCSI Controller is presented, it will be added for the Backup. While Exchange is a bit sensitive to wait for the entire process of Veeam Backup Job to go from SCSI (0:0) till SCSI (3:15) which is the last SCSI Controller, it failed because VSS Snapshot it didn’t pass within the time frame that specified by Veeam.
But by selecting the correct SCSI Controller/Disks which are presented within the Virtual Machine, I think Veeam Intelligent enough to pickup only those SCSI Disks which are presented/Selected.

, , , , , , , , , , , ,

1 Comment

How to Power-Off / Shutdown Virtual Machine on VMWare ESXi5

How to Power-Off / Shutdown Virtual Machine on VMWare ESXi5



You are experiencing these issues:

  • You cannot power off an ESXi hosted virtual machine.
  • A virtual machine is not responsive and cannot be stopped or killed.
  • You cannot power off an ESXi because it’s hanged with lots of SCSI Storage I/Os

You can start by obtaining the <VMID> and you can run the power action against the VMID generated by the below command;

vim-cmd vmsvc/getallvms – list all VMs registered on the host

vim-cmd vmsvc/power.getstate <vmid> – show power state of a VM
vim-cmd vmsvc/power.shutdown  <vmid>  – shutdown a VM (shutdown guest)
vim-cmd vmsvc/power.reset  <vmid>  – reset a VM
vim-cmd vmsvc/power.off <vmid>  – power off a VM
vim-cmd vmsvc/power.on <vmid> - power on a VM
vim-cmd vmsvc/power.reboot <vmid> - reboot a VM
vim-cmd vmsvc/get.summary  <vmid>  – get summary information for a VM
vim-cmd vmsvc/unregister  <vmid>  – unregister a VM from a host


# vim-cmd vmsvc/getallvms

Vmid   Name             File                  Guest OS       Version   Annotation

2      VM01   [vESXi5-01] VM01/VM01.vmx   winLonghornGuest   vmx-08

~ # vim-cmd vmsvc/power.getstat 2

Retrieved runtime info

Powered on

~ # vim-cmd vmsvc/power.shutdown 2

(vim.fault.ToolsUnavailable) {

dynamicType = <unset>,

faultCause = (vmodl.MethodFault) null,

msg = “Cannot complete operation because VMware Tools is not running in this virtual machine.”,}

In the above example, it gives me an error that cannot Shutdown the VM as the VMWare Tools is not running.

But by running the command to forcibly power off the VM with Power.Off command, it’s immediately powered off the named VM ID. (2)

~ # vim-cmd vmsvc/power.off 2

Powering off VM:

~ # vim-cmd vmsvc/power.getstat 2

Retrieved runtime info

Powered off

~ #

Commands available under vmsvc/:

~ # vim-cmd vmsvc/
Commands available under vmsvc/:
acquiremksticket                 get.spaceNeededForConsolidation
acquireticket                    get.summary
connect                          get.tasklist
convert.toTemplate               getallvms
convert.toVm                     gethostconstraints
createdummyvm                    login
destroy                          logout
device.connection                message
device.connusbdev                power.getstate
device.disconnusbdev             power.hibernate
device.diskadd                   power.off
device.diskaddexisting           power.on
device.diskremove                power.reboot
device.getdevices                power.reset
device.toolsSyncSet              power.shutdown
device.vmiadd                    power.suspend
device.vmiremove                 power.suspendResume
devices.createnic                queryftcompat
get.capability                   reload
get.config                       setscreenres
get.config.cpuidmask             snapshot.create
get.configoption                 snapshot.dumpoption
get.datastores                   snapshot.get
get.disabledmethods              snapshot.remove
get.environment                  snapshot.removeall
get.filelayout                   snapshot.revert
get.filelayoutex                 snapshot.setoption
get.guest                        tools.cancelinstall
get.guestheartbeatStatus         tools.install
get.managedentitystatus          tools.upgrade
get.networks                     unregister
get.runtime                      upgrade
~ #

, , , , , , , , , ,

Leave a comment

View Mailboxes in Exchange Server 2007 who Exceed Quota Limit

Mailbox quotas help control the size of mailboxes, For example, would you like to know which mailboxes have reached their prohibit send receive quota, Or view the mailbox size and quota status of a specific mailbox?

You can do all that with the Get-Mailbox and Get-MailboxStatistics Exchange PowerShell cmdlets.
Get-Mailbox -ResultSize Unlimited | Get-MailboxStatistics | where {$_.StorageLimitStatus -notlike "BelowLimit*"} | select DisplayName,LegacyDN,DatabaseName,StorageLimitStatus|Export-Csv c:\ExceedQuota.csv

The above script will loop through each Mailboxes and will get each Mailbox Statistics where their StorageLimitStatus not BelowLimit.

The Get-MailboxStatistics has a property where you can fetch each a property with Where statement and braces bracket {} to get the StorageLimitStatus Property.

The result of the above script is the below table;

DisplayName LegacyDN DatabaseName StorageLimitStatus
Full Display Name /O=Organization/OU=FIRST ADMINISTRATIVE GROUP/CN=RECIPIENTS/CN=Alias Students-DB10 ProhibitSend

Manual work has to be done to remove the LegacyDN and keep only the Alias CTRL+H find what and Replace All is a good to delete the entire LegacyDN name and keep only the Alias.

You can use another script to move the mailbox from one Database which has got a quota limited quota to a higher Database which has higher quota.

In order to move the Mailbox to higher quota Database, you need to know the Database Storage Limit Size. You can achieve this by running the Get-MailboxDatabase cmdlet in Exchange PowerShell and pipe it with the property of ProhibitSendReceiveQuota
 Get-MailboxDatabase | select Name, StorageGroup, ProhibitSendReceiveQuta | Export-CSV C:\DBQuota.csv

Name StorageGroup ProhibitSendReceiveQuota
Staff-DB1-H MAILSERVER\Staff-SG 2355MB
Staff-DB2-N MAILSERVER\Staff-SG 1111520KB
Staff-DB3-L MAILSERVER\Staff-SG 515520KB
Students-DB1 MAILSERVER\Students-SG 1000MB
Students-DB2 MAILSERVER\Students-SG 100MB
Students-DB3 MAILSERVER\Students-SG 200MB
Students-DB4 MAILSERVER\Students-SG 311999KB
Students-DB5 MAILSERVER\Students-SG 1300000KB
Students-DB6 MAILSERVER\Students-SG2 400MB
Students-DB7 MAILSERVER\Students-SG2 522000KB
Students-DB8 MAILSERVER\Students-SG2 800MB
Students-DB9 MAILSERVER\Students-SG2 919200KB
Students-DB10 MAILSERVER\Students-SG2 1024160KB
Staff-DB4-O MAILSERVER\Staff-SG 5000MB
Students-DB11 MAILSERVER\Students-SG3 200MB
Students-DB12 MAILSERVER\Students-SG3 200MB
Students-DB13 MAILSERVER\Students-SG3 200MB
Students-DB14 MAILSERVER\Students-SG3 200MB

Now it’s time to move the Mailboxes from their current Database where has got limited quota to the higher Databases which has higher quota.

In order to move the require users from one Database to another, you need to put their Alias/EmailID into a text file to be called by another script and start moving the mailbox to the target Database.

You can filter the first CSV export by Database Column to get all the users in the limited quota database, copy only the  Alias/EmailID to a text file and use the below script to move them to the target Database;

# Move-Multiple-Mailbox.ps1 #
# Created By Assaf Miron #
# Date : 06/11/07 #


function IsHelpRequest
return ($argument -eq "-?" -or $argument -eq "-help");

# Function that displays the help related to this script following
# the same format provided by get-help or -?
Function Usage

`tMove-Multiple-Mailbox.ps1 [-FileToOpen][-TargetDB]

`tMoves a list of mailboxes listed in an Excel File to
`ta specific Database.

`t`t[ -FileToOpen ]
`t`t[ -TargetDB ]
`t`t[ -ValidateOnly [True/False] ]

`t-FileToOpen (required)
`t`tAn Text File wich Contains Principle Names of Users to Move
`t-TagretDB (required)
`t`tTarget Databse Name
`t-ValidateOnly (optional)
`t`tDoesn't move the mailboxes but checks if they can move to the target DB

`t-------------------------- EXAMPLE 1 --------------------------

C:\PS> .\Move-Multiple-Mailbox.ps1 -FileToOpen "C:\UsersToMove.txt" -TargetDB "Students-DB6"

`t-------------------------- EXAMPLE 2 --------------------------

C:\PS> .\Move-Multiple-Mailbox.ps1 -FileToOpen "C:\UsersToMove.txt" -TargetDB "Students-DB6" -ValidateOnly $true

`tThe Move Mailbox accours with the Max threads Parameter
`tit will not move mailboxes that have errors
`tor mailboxes that need to preserve thier size.


# Script starts here

# Check for Usage Statement Request
$args | foreach { if (IsHelpRequest $_) { Usage; exit; } }

$arrMailboxes = @()

# Validate the parameters
If ($TargetDB -eq "") { Usage; exit; }
Else {
If ($FileToOpen -eq "") { Usage; exit; }
Else {
write-host $FileToOpen

$arrMailboxes = Get-Content $FileToOpen

Write-Host "About to move"$arrMailboxes.Count"Mailboxes to"$TargetDB
$Ans = Read-Host "is This information Correct ? `n[Yes,No]`nDefault(Yes)"
If ($Ans.Contains("n")) { exit; }
If ($ValidateOnly -eq $True)
$arrMailboxes | Move-Mailbox -TargetDatabase $TargetDB -MaxThreads 16 -ValidateOnly
$arrMailboxes | Move-Mailbox -TargetDatabase $TargetDB -MaxThreads 16

, , , , , , , ,

Leave a comment


Get every new post delivered to your Inbox.