Author Archive

PowerShell Script to E-Mail User Mailbox Storage Limit Status

A storage status of “NoChecking” means they do not have a mailbox limit.

To schedule the script. Through Windows Scheduler “PowerShell.exe -PSConsoleFile "C:\Program Files\Microsoft\Exchange Server\Bin\ExShell.psc1" -Command “C:\Script.ps1"

Save as a .ps1 file

________________________________________________

$FromAddress=MailboxReport@domain.com

$ToAddress=ExampleUser@domain.com

$MessageSubject="Mailbox Report"

$MessageBody="User Mailbox Storage Limit Status"

$SendingServer="emailserver.domain.com"

$file="C:\Mailboxes.txt"

Get-MailboxStatistics | Sort-Object StorageLimitStatus | ft DisplayName, StorageLimitStatus, ItemCount > $file

$SMTPMessage = New-Object System.Net.Mail.MailMessage $FromAddress, $ToAddress, $MessageSubject, $MessageBody

$Attachment = new-object System.Net.Mail.Attachment $file

$SMTPMessage.Attachments.Add($Attachment)

$SMTPClient=New-Object System.Net.Mail.SMTPClient $SendingServer

$SMTPClient.Send($SMTPMessage)


Exchange 2010 Requires Client Encryption – Outlook 2003 Encryption Disabled by Default

Solution:

 

1. Enable Encryption in the Outlook 2003 Profile.

image

2. Create a GPO to enable Encryption for Outlook 2003 clients.

http://support.microsoft.com/kb/2006508

 

3. Disable the Encryption requirement on the Exchange 2010 server.

From PowerShell on the Exchange server: Set-RpcClientAccess -Server:ExchangeServerName -EncryptionRequired:$False



Migration From Exchange 2003 to Exchange 2010 on Windows Server 2008 R2

Prerequisites:

  • Existing Exchange 2007 Servers must have SP2 installed.
  • Existing Exchange 2003 Servers must have SP2 installed.
  • Exchange Organization is set to Native Mode.
  • At least one Global Catalog in each AD site must be Server 2003 with SP2.
  • Active Directory Forest Functionality must be at least Windows Server 2003.
  • Exchange 2010 cannot be installed on a RODC.
  • Verify the existing Exchange 2003 Server does not have a SMTP Smart Host configured.
  • Verify network with Exchange Pre-Deployment Analyzer.
  • Possible Got Ya’s: Exchange 2010 requires client encryption and Outlook 2003 slow to delete email messages.

Required Software:

  • From PowerShell on the server where Exchange will be installed.
  • Set-ExecutionPolicy RemoteSigned – This will allow PowerShell scripts created on the server to be run on the server.
  • Import-Module servermanager
  • Save the command below to a .PS1 file extension. (Command below needs to be on a single line)
  • add-WindowsFeature Net-Framework,RSAT-ADDS,Web-Server,WEB-ISAPI-Ext,Web-Metabase,Web-Lgcy-Mgmt-Console,Web-Basic-Auth,Web-Digest-Auth,Web-Windows-Auth,Web-Dyn-Compression,NET-HTTP-Activation,RPC-over-HTTP-Proxy -Restart
  • Change to the directory of the PowerShell script you just created.
  • Enter .\SriptName.ps1
  • After the Reboot, configure Net.TCP port sharing service.  Enter – Set-Service NetTcpPortSharing -StartupType Automatic

(continue reading…)


Build a 2008/2008 R2 Template

http://jeremywaldrop.wordpress.com/2008/10/28/how-to-build-a-windows-2008-vmware-esx-vm-template/

 

NOTE – VMware Virtual Center 2.5 Update 4 or vCenter 4 is required to use Guest Customizations with Windows 2008.

1. Use an ISO for faster OS setup.

2. Build a new VM that has at least 1 GB RAM and a 20 GB drive.

3. Attach the Windows 2008 ISO to the CD/DVD drive and set it to connect at power on.

(continue reading…)


vSphere Jumbo Frames vDS and Multi-Pathing

Original post on Mike’s SysAdmin Blog

vSphere: Software iSCSI, Jumbo Frames, Distributed Virtual Switches and Multi-Pathing (MPIO)

    With the release of vSphere Update 1, we can now take advantage of Software iSCSI MPIO using the new DvSwitch functionality in vSphere.  Before now, we were limited to only being able to do MPIO on a standard vSwitch.  Using a DvSwitch is a little more involved, here are the steps to set-up the DvSwitch, MPIO and Jumbo Frames: (Please let me know if anything is unclear or incorrect!).

    1. Create a new DvSwitch.  We called ours “Storage_dvSwitch”.
    2. After creating your new DvSwitch, Edit the settings and change the Max MTU to 9000 to support Jumbo frames.

    3. Now create 2 (or however many you want) new Port Groups.  Nothing special here, we named ours iSCSI1 and iSCSI2.  VLAN configuration may vary depending on network configurations.
    4. This part is important – we need to set-up the pNIC fail-over settings properly.  You should have ONE active dvUplink per iSCSI port-group, NO standby NICs and the remaining NICs should be Unused.  Each port-group should get a different dvUplink. This can be changed in the port-group settings page.
    5. This concludes the vCenter specific configuration.  The following steps will apply to EACH host that you plan to use with Jumbo frames.
    6. If you haven’t already, you will need to add the Host’s physical NIC’s to the new DvSwitch we created. You can do this from the ‘Add Host’ link on the DvSwitch summary page.
    7. Now we need to create 1 VMkernel port for each Port-Group we created. This is done in the HOST configuration tab, in the Networking section. Select the ‘Distributed Virtual Switch’ view and click the ‘Manage Virtual Adapters…’ link.
    8. Click ‘Add’ and add one VMkernel port to each iSCSI port-group you created on the storage DvSwitch.  There may be some benefits to over-subscription here (many VMkernel ports on 1 port-group), but that will vary by environment.  When you are done, your Port-Groups should look something like this:
    9. Now we need to find the Port number assigned to each vmk port.  You can either click the ‘i’ icons next to each vmk port or by running “esxcfg-vswitch -l” from the CLI.  In this example, vmk1 has a port ID of 1, and vmk2 has a port ID of 129.
    10. Now, from the CLI, delete the VMkernel ports you just created in the GUI (Awesome, isn’t it?) by running “esxcfg-vmknic -d -s ‘<your dv switch name>’ -v <dv port number>”.  You will need to run this for each VMkernel port you created.  So in our example, it would be:
      • esxcfg-vmknic -d -s ‘Storage_dvSwitch’ -v 1
      • esxcfg-vmknic -d -s ‘Storage_dvSwitch’ -v 129
    11. Now re-add the VMkernel ports (using the port numbers you just deleted) with jumbo frames enabled by running: “esxcfg-vmknic -a -s ‘<your dv switch name>’ -i <ip addr> -n <subnet> -m 9000 -v <dv port number>”.  So in our example:
      • esxcfg-vmknic -a -s ‘Storage_dvSwitch’ -i 10.255.38.151 -n 255.255.255.0 -m 9000 -v 1
      • esxcfg-vmknic -a -s ‘Storage_dvSwitch’ -i 10.255.38.201 -n 255.255.255.0 -m 9000 -v 129
    12. Enable the software iSCSI initiator if you haven’t already and find the vmhba number assigned to it.  In our example, it is vmhba35:
    13. Now bind the new VMkernel ports to the iSCSI HBA: “esxcli swiscsi nic add -n vmkx -d vmhba35″  Adjust the vmkernel name (vmk0, vmk1, etc) and the iSCSI initiator HBA number (vmhba33, vmhba35, etc) to fit your environment.  Do this for each VMkernel port you will be using for MPIO.  For this example, we run:
      • esxcli swiscsi nic add -n vmk1 -d vmhba35
      • esxcli swiscsi nic add -n vmk2 -d vmhba35
    14. You can verify that your vmk ports were successfully added to the pNIC’s by running “esxcli swiscsi nic list -d vmhbaxx” (in our case, esxcli swiscsi nic list -d vmhba35).  Each vmk port should be listed and should be assigned ONE pNIC.


    New vSphere Project

    The Hardware:

    3 – Dell R710 Servers with 2-Quad Core Xeon CPUs, 32GB RAM, 3-SAS HDs, and 8 NIC ports.

    2 – Cisco 2960G Switches.

    1 – Dell Equallogic PS6000x 7.2TB with 16 SAS Drives and Dual Controllers.

    The Software:

    VMware vSphere vCenter Standard

    VMware vSphere ESX Enterprise Plus

    Initial Server Configuration:

    Enable Intel Virtual Technology in Dell BIOS.

    Configure Power Management for High Performance.

    Configure Dell DRAC username, password, and IP.

    Configure local RAID for RAID 1 + 1 Hot Spare.

    (continue reading…)


    vSphere ‘Health status changed’ alarm activates every few hours and sends an email notification

    This alarm monitors the vCenter Services, but per VMware there is a known issue that will cause the alarm status to go from Green to Yellow. This is caused by vCenter Storage Management syncs. The current fix is to remove the email address from the Actions tab.

    http://communities.vmware.com/message/1385495

    image


    Using The ESX Host Update Utility

    Back Up the ESX Host Configuration

    Back up the files in the /etc/passwd, /etc/groups, /etc/shadow, and /etc/gshadow directories.
    The /etc/shadow and /etc/gshadow files might not be present on all installations.
    Back up .vmx files.

    Back Up the ESXi Host Configuration

    Install the vSphere CLI. 
    In the vSphere CLI, run the vicfg-cfgbackup command with the -s flag to save the host configuration to
    a specified backup filename.

    vicfg-cfgbackup –server <ESXi-host-ip> –portnumber <port_number> –protocol
    <protocol_type> –username username –password <password> -s <backup-filename>

    (continue reading…)


    Configure a GPO WMI Filter for Office 2000, XP, or 2003

    SELECT * FROM Win32_Product WHERE Caption LIKE “Microsoft Office%2003%” OR Caption LIKE “Microsoft Office%2000%” OR Caption LIKE “Microsoft Office%XP%”


  1. Archives

  2. Copyright © 1996-2010 My-Technet. All rights reserved.
    iDream theme by Templates Next | Powered by WordPress
    WordPress Appliance - Powered by TurnKey Linux