Saturday, 20 September 2014

Configuring SMTP Relay on Office365 for a LOB Application

You are required to configure a LOB Application (in this case a Telephony PBX) to send e-mails using SMTP from Outlook365. TechNet (http://technet.microsoft.com/en-us/library/dn554323(v=exchg.150).aspx) provides a fairly decent guide but I thought I would document it myself as I got lost by some of the out of date steps.
To make this configuration change you must have the public IP address that the LOB Application is using to connect to the internet, this is how Office365 authenticates the application. It also mitigates against Office365 becoming an open relay.
The first stage is to create a new Exchange Inbound Connector this is done by connecting up to the Office365/Exchange ECP control panel. You can use the following address https://outlook.office365.com/ecp with your Office365 administrator credentials.

When you have logged into the Exchange ECP click Mail Flow and Connectors use the + symbol to create a new inbound connector.

Give the connector a descriptive name, ensure Enable Inbound Connector is selected. In this instance I have selected On-Premises, for good practice I also entered a description. From the Sender Domains section use the + symbol and configure it with an asterisk. This will allow mail to be sent to any domain.

Now under the Sender IP Addresses use the + symbol again and enter the public IP address the LOB Application is using to connect out to the internet. When this is done click Save.

You then use the MX Record configured for the domain as the SMTP Relay server for your LOB Application, you can find this from Office365 but I prefer Mx Toolbox.

Now reconfigure the LOB Application to point to the MX Record Hostname, on port 25.

Wednesday, 17 September 2014

VMware ESXi 5.5 Host Purple Screen with "Exception 14 in World 63445:vmm1:VMNAME IP"

The same ESXi 5.5 host has purple'd screen today returning the same error for two different Virtual Machines.


According to the following VMware link;
http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2059053 this is a known issue related to using the E1000/E1000E Virtual Network adapter. Although in a production deployment I alwasy use VMNET3 (VMware Tools req'd) for Windows Server 2012 R2 Servers as this was only a lab server I never paid much attention to the network adapter when I created my first template.
VMXNET 3: The VMXNET 3 adapter is the next generation of a paravirtualized NIC designed for performance, and is not related to VMXNET or VMXNET 2. It offers all the features available in VMXNET 2, and adds several new features like multiqueue support (also known as Receive Side Scaling in Windows), IPv6 offloads, and MSI/MSI-X interrupt delivery. For information about the performance of VMXNET 3, see Performance Evaluation of VMXNET3 Virtual Network Device. Because operating system vendors do not provide built-in drivers for this card, you must install VMware Tools to have a driver for the VMXNET 3 network adapter available.
VMXNET 3 is supported only for virtual machines version 7 and later, with a limited set of guest operating systems:
·         32- and 64-bit versions of Microsoft Windows 7, 8, XP, 2003, 2003 R2, 2008, 2008 R2, Server 2012 and Server 2012 R2
·         32- and 64-bit versions of Red Hat Enterprise Linux 5.0 and later
·         32- and 64-bit versions of SUSE Linux Enterprise Server 10 and later
·         32- and 64-bit versions of Asianux 3 and later
·         32- and 64-bit versions of Debian 4
·         32- and 64-bit versions of Debian 5
·         32- and 64-bit versions of Debian 6
·         32- and 64-bit versions of Ubuntu 7.04 and later
·         32- and 64-bit versions of Sun Solaris 10 and later
·         32- and 64-bit versions of Oracle Linux 4.9 and later
I change all of the Windows Server 2012 R2 vmnic's to use VMET3, and so far so good there has been no purple screens. Obviously in a production environment you would maybe go to the effort of patching the server.
The other thing that was clear to check was the build of ESXi 5.5 that was installed on the server, the physical hardware is a HP ProLiant. Therefore it should have a HP opptomized build of ESXi, with all the integrated driver for that hardware. http://www8.hp.com/us/en/products/servers/solutions.html?compURI=1499005#tab=TAB4 it turns out in this case it was a base ESXi 5.5 install, therefore I also reinstalled ESXi to ensure the HP build supplied all the correct drivers.

Tuesday, 16 September 2014

Configuring HP MSA2000 Storage Appliance Management Interfaces

I was recently asked to reconfigure a HP MSA 2000 Storage Appliance for a Lab Environment. The MSA 2000 had been used before but nobody had recorded the Management IP or the login credentials. After trying to connect directly to one of the Ethernet ports using the network 10.0.0.1/24 (the default for the Management interface on an MSA2000 is 10.0.0.1/24) I could not browse to the web interface, this was probably because the Management interface had been configured with a different address.
The next challenge was to find a mini-Serial cable to get console access to the Storage Appliance, personally this is the second time I have had to do this kind of thing to an MSA and it is also the second time I have had trouble getting the mini-Serial cable. Why did HP not just use the standard Cisco console cable? Every Data Center I have been in has hundreds of them!



In the end I found the cable I needed, the next stage was to create a console connection to the device using Putty. Open Putty click Serial, set the COM interface (in my example its COM4), and change the Speed/BAUD Rate to 115200. If you do not change the BAUD Rate the console screen will just return nonsense.
When you get connected the screen may appear blank, if so enter help and hit return this will list the example commands that can be issued to the device.
create user rbetts


set user rbetts level manage
set user rbetts type advanced


set network-parameter ip 172.16.0.34 netmask 255.255.255.0


Now that I had set an IP and Netmask on the interface I then configured my laptops interface on the same network and browsed to it via Google Chrome.I used my new login credentials.

From inside the web GUI Virtual Disks, LUN's, volumes etc can be created and advertised to VMware ESXi hosts.

Exchange PowerShell Cheat Sheet

 My plan it to add to this as I go, with any useful Exchange PowerShell commands.

This shows all of the Mailbox database copies for a database called “MBX Name”
Get-MailboxDatabase “MBX Name” | Format-List DatabaseCopies

This shows the dedicated DAG replication network.
Get-DatabaseAvailabilityGroupNetwork

This begins a mailbox move for “User” to a database called “MBX Name”
New-MoveRequest “User” –TargetDatabase “MBX Name”

This moves all of the users listed in C:\MyMigration to a database called “MBX Database”
Get-Content C:\MyMigration | New-MoveRequest –TargetDatabase “MBX Database”

This lists the progress of the mailbox migration for users listed in C:\MyMigration
Get-Content C:\MyMigration | Get-MailboxStatistics

I recently used this simple command to find where a generic e-mail account resided within Exchange.

Get-MailboxStatistics –Identity “Mailbox”

Exchange 2013 Reconfiguring the Default E-Mail Maximum Size (including Attachments)

If you want to increase the maximum size an e-mail can be that is accepted as inbound mail by Exchange it can be done using the ECP, you must navigate to Mail Flow > Receive Connectors and use the .... button to expose the Organization Transport Settings option.

From the Limits tab, you can increase the Maximum Receive Message Size (MB): I changed mine to 25 MB's, while I was in here I also changed the outbound limit to 25MB.

The following PowerShell command can be used to check the ECP has made the configuration change properly.

Get-TransportConfig | ft MaxSendSize, MaxReceiveSize



Saturday, 13 September 2014

Microsoft Exchange PST Capture Tool to aid an Exchange Migration

When I heard of the Microsoft PST Capture tool http://technet.microsoft.com/en-us/library/hh781036(v=exchg.141).aspx I thought how useful it would have been for a project I was doing a few years ago. Around 3 years ago I was migrating to Exchange 2010 from Exchange 2003, and the real difficulty was all of the mail data was stored locally as PST files on all of the client workstations. The migration ended up being a very long weekend of manually importing PST files into new Exchange mailboxes.

I am using a Windows 7 PC as the PST Capture Workstation, if you are using Windows 7 you must install PowerShell 3.0.




A PST Capture Agent must be installed on any devices that PST Capture is polling for rogue PST files. Luckily it is compiled into an MSI file, therefore it can be deployed using a Software Installation Group Policy Object if you do not have Configuration Manager in your environment. When installing the agent you must point to the PST Capture Workstation.

Once the installation completes launch the PST Capture Console and click on the New PST Search...

Select the Domain you want to search and browse the Organisation Units (OU) for endpoint workstations. Clients that do not have the PST Capture Agent installed will have a red icon, if the agent is detected it will be green. Click Next.

On the next pane, select which locations on the workstations you want to search for PST's, I personally left it to All (Not including network or external drives). Click Next.

Select No Schedule (Run Manually) and click Next.

PST Capture will browse through the workstations and find any PST files.

On my test PC it found a number of PST's. I selected one of them, and click on the New Import List.... and from the drop down click On Premise.

From the Destination Mailbox section, click and select the target mailbox you want the PST imported into, click Import All Now.

The PST Capture Console will be importing the PST file into the Exchange mailbox.

Thursday, 11 September 2014

Downloading, Licensing and Base Configuration of a Citrix NetScaler Virtual Appliance (VPX)

I have recently been asked to learn the Citrix NetScaler platform and get the Citrix Certified Professional (CCP) credentials. My first port of call was to download the virtual appliance of the NetScaler to get some expsoure to it. If you have a Citrix account you can download a free 90 day trial. You must choose which hypervisor the appliance is going to run on to ensure you get the correct download. I am using VMware Workstation, and the ESXi edition seems to work fine.

When you have it downloaded extract the zip file, an in this instance as I am using VMware the appliance is in the form of an OVF file, right click on the OVF and select Open with VMware Workstation.

When the appliance has been imported it will appear like any other Virtual Machine in Workstation, it is initally provisioned with the following virtual resources.

Boot the VM and let it POST and then you will be prompted with the inital configuration screen, you set an IP at this screen to allow remote management of the NetScaler with a web browser.

Once you have saved the settings browse to the IP via any Java enabled web browser. By default the root credentials are nsroot/nsroot.

Next you have to convert the code you received when the appliance was downloaded into a Citrix License File, highlight and copy the License Code from the following screen.

Login to the My Citrix website and select All Licensing Tools, click the Activate and Allocate Licenses tab. If you do not see any available licenses listed click Don't see you product?

Then copy the License Code into the website and click Continue.

You will get a warning about the Host Name/ID the Citrix NetScaler is tied to the MAC Address of the Virtual Appliance, I found this misleading at first as it references Host ID which you would think meant the hostname. Click Continue.


To get the MAC Address of the Citrix NetScaler Appliance I used ping on my Domain Controller and then viewed the ARP cache on the machine to view the Layer 2 address of the NetScaler.


Move back over to the Citrix website and populate the Host ID field with the MAC Address, it should be in the following format 000c29d7e7a9 with no dashes or colons.

If the Citix website accepts the license code it will give you the following prompt. Click OK.

Click the Download button to save a local copy of the LIC file.

Browse to the management IP of the NetScaler and login with the nsroot account, from the Welcome screen you will be prompted to Update Licenses. Click the Browse button and select the downloaded license file.

The appliance will accept the license file if the MAC Address matches the hash contained within the file, please note if you remove the VM's network adapter and readd a new one the MAC Address will change and you will break your licensing. 

Click  Continue and the NetScaler will infom that it requires a reboot, click Yes.

When the appliance reboots log back in using nsroot and click on the Configuration tab, if you click on the Show Unlicenses Features link, it will show nothing is unlicensed this is due to it being a trial.
Expand System and click on Settings, from here click Configure Basic Features.

For my next post I will be using NetScaler to Load Balance Exchange 2013 Client Access Server's, so I enabled the Load Balancing feature.

Now configure NTP by clicking on the NTP Servers link, use the Add button. I personally have pointed my NetScaler to one of my Domain Controllers to synchronize time.

Friday, 5 September 2014

New VMware VCP-NV Credential: Learning VMware NSX

For the past week or two I have started learning VMware's new NSX Network Virtualization platform, as I am planning on getting the VMware Certified Professional (VCP) in Network Virtualization credential. As always VMware have their "training requirements" before you can get authorized to take the exam. Luckily if you are already a VMware Certified Professional (VCP) in Data Center Virtualization you can take the exam without any formal training. It also appears until February 2015 if you are a Cisco CCNA/CCNP in Data Center or Routing and Switching you can also request authorization without the formal course requirement.

The overview and blueprint is available from VMware(https://mylearn.vmware.com/mgrReg/plan.cfm?plan=51111&ui=www_cert) and as always the exam objectives are not defined in depth. I have requested authorization for the VCP-NV exam, and have it booked for the end of October, because of the mess my Pearson Vue account(s) are in it authorized me based on my CCNA Data Center credential, and not VCP-DCV. The exam is set to cost $175, which is the same as the traditional VCP exam.

I have already read through all of the VMware documentation for NSX but have to give it a second read when I start to provision NSX into my lab (https://www.vmware.com/support/pubs/nsx_pubs.html). I am currently building a clean vSphere 5.5 lab to accommodate VMware NSX, the required hardware for the NSX Manager seems a bit on the extreme side especially when only in a lab therefore I am hoping to get away with much less than it states is required.

Thursday, 4 September 2014

Exchange 2010 SP3 Users Experiencing Issues with ActiveSync Device (iPhone) "Event 10031 : A folder view which previously experienced consistency issues has been deleted and will be rebuilt the next time it is needed. "

After an unexpected power outage and some "Dirty Shutdown" repairs last week a number of users are having problem connectivity to Exchange via ActiveSync. New messages were being delivered to the device but message being sent out were returning errors. On investigation of the Event Log "Event 10031 : A folder view which previously experienced consistency issues has been deleted and will be rebuilt the next time it is needed. " was populating the Events. One of the problem users was also listed in the Event.

According to the following Microsoft article http://support.microsoft.com/kb/2548246/en-us the work around is to create a new Mailbox Database and simply create a New Local Move Request to that new database. Although I can do this, I would imagine some environments would not have that flexibility.
I created the New Mailbox Database using the Exchange Management Console, this can be done by clicking Organization Configuration\Mailbox and right clicking on the white space selecting New Mailbox Database.


On this particular Exchange deployment the Mailbox Databases and the Transaction Logs are separated on to different partitions, I reconfigured the paths to reflect this.


Exchange successfully create the new databases, I also selected the option Mount this Database so the wizard also automatically done this.

I then right clicked on the new Mailbox Database "MailDB2" and selected Properties and then Limits this was to reconfigure the Database Wide Quota's. I set these to 5GB.

I then click on Recipient Configuration\Mailbox, selected one of the problem users and right clicked on them. I then chose New Local Move Request from the drop down.

From the New Local Move Request window I then pointed to the new Mailbox Database and clicked Next.
As I was sure some items in the user's mailbox were corrupt I clicked Skip the Corrupted Messages and set the value to 50. This ensured the move request would not completely fail should a few e-mails be corrupt. Click Next.

The move request completed, but with a warning that some items may not be moved if they are considered corrupt. I clicked Finish.

From the Exchange Management Shell I then used the following PowerShell command to check on the progress of the move request.
Get-MoveRequestStatistics “Username”


I then checked in the Event Logs to see if the Warnings had stopped, there was a number of errors relating to the move request. It advised a number of e-mails were considered corrupt and would not be moved.


I gave the move request about 10 minutes to complete and I used the Move Request section inside the Exchange Management Console to view the details of the move itself. 


I right clicked on the Move Request and selected Properties and this confirmed the move had completed, with 6 corrupt messages. This particular mailbox had 30,000 e-mails so I thought 6 was not a bad result.


I asked the user to reset their device and try again and it worked as excepted.