• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2192
  • Last Modified:

Exchange 2010 toolbox ECP errors

We have an Exchange 2010 environment, upgraded from Exchange 2003 back in April. We removed the exchange 2003 server from the environment and turned it off.

When I attempt to launch Message Tracking, or the RBAC editor from the EMC toolbox, I am receiving the following error

Cannot index into a null array. It was running the command 'Discover-ECPVirtualDirectoryForEMC - CurrentVersion 'Version 14.1 (Build 218.15)' -UseWIA $true'.


Wondering if there could be some sort of IIS issue or something I didn't configure correctly that is not allowing a few of these tools to come up. Maybe ECP?

I can get to "Roles and Auditing" as well as "Delivery Reports" via OWA->Options, but can't access the tools via EMC.

I've been racking my brain for months on this. Anyone have any ideas?
0
HornAlum
Asked:
HornAlum
  • 7
  • 3
1 Solution
 
sirakovCommented:
Have you try to recreate the  ecp v'dir ?
>Get-EcpVirtualDirectory | Remove-EcpVirtualDirectory
and
>New-EcpVirtualDirectory -internalUrl "https://FQDNofYourServer/ecp"
>iisreset

could you post the results of :
Get-EcpVirtualDirectory |fl

Also, is it a new install of Exchange 2010 SP1 ? I'm asking this because it might be a courruption in the cashe file of the mmc itself
navigate here and delete the EMC cashe file:
C:\Users\ivo\AppData\Roaming\Microsoft\MMC

Also, just in case delete the files under :
C:\Windows\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files
0
 
HornAlumAuthor Commented:
I believe I did try to remove the ECP vdirectory, but I'll try it again. It was a fresh install of Exch 2010 SP1

these are the current results of Get-ECPVirtualDirectory




RunspaceId                      : c492aedd-cddd-4c19-852c-2d73fb5a6480
Name                            : ecp (Default Web Site)
InternalAuthenticationMethods   : {Basic}
MetabasePath                    : IIS://SHC-CAS.schoolhealth.com/W3SVC/1/ROOT/ecp
BasicAuthentication             : True
WindowsAuthentication           : False
DigestAuthentication            : False
FormsAuthentication             : False
LiveIdAuthentication            : False
DefaultDomain                   :
GzipLevel                       : High
WebSite                         : Default Web Site
DisplayName                     : ecp
Path                            : C:\Program Files\Microsoft\Exchange Server\V14\ClientAccess\ecp
ExtendedProtectionTokenChecking : None
ExtendedProtectionFlags         : {}
ExtendedProtectionSPNList       : {}
Server                          : SHC-CAS
InternalUrl                     : https://shc-cas.schoolhealth.com/ecp
ExternalUrl                     : https://mail.schoolhealth.com/ecp
ExternalAuthenticationMethods   : {Fba}
AdminDisplayName                :
ExchangeVersion                 : 0.10 (14.0.100.0)
DistinguishedName               : CN=ecp (Default Web Site),CN=HTTP,CN=Protocols,CN=SHC-CAS,CN=Servers,CN=Exchange Admi
                                  nistrative Group (FYDIBOHF23SPDLT),CN=Administrative Groups,CN=SchoolHealth,CN=Micros
                                  oft Exchange,CN=Services,CN=Configuration,DC=schoolhealth,DC=com
Identity                        : SHC-CAS\ecp (Default Web Site)
Guid                            : 0ef50f0b-0e06-4030-bd9a-55af2b8e29c2
ObjectCategory                  : schoolhealth.com/Configuration/Schema/ms-Exch-ECP-Virtual-Directory
ObjectClass                     : {top, msExchVirtualDirectory, msExchECPVirtualDirectory}
WhenChanged                     : 3/27/2012 1:04:05 PM
WhenCreated                     : 3/23/2012 8:17:55 AM
WhenChangedUTC                  : 3/27/2012 6:04:05 PM
WhenCreatedUTC                  : 3/23/2012 1:17:55 PM
OrganizationId                  :
OriginatingServer               : shcadmin.schoolhealth.com
IsValid                         : True

0
 
HornAlumAuthor Commented:
if i run the Discover-EcpVirtualDirectoryForEmc at the shell, i get this (you see the point of error marked by the "<<<<" in the "if" command

Discover-EcpVirtualDirectoryForEmc
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
sirakovCommented:
Ok, I had a look based on the error you got .
The function discover-EcpVirtualDirectoryForEcm look for a sub-function called _GetSites() and there it is actually failing.

function _GetSites()
{
	$localSite=[System.DirectoryServices.ActiveDirectory.ActiveDirectorySite]::GetComputerSite()
	if ($localSite -eq $null)
	{
		return #no site - no auto discovery
	}
	$siteDN=$localSite.GetDirectoryEntry().DistinguishedName
	$siteList = New-Object System.Collections.ArrayList
	if ($siteDN -ne $null)
	{
		[void] $SiteList.Add($siteDN)
	}
	# DCR 231555: TAp DCR:Respect site-link costs with remote powershell.
	# Now go one level to find adjacent sites based on site link and add them in the site list
	if ($localSite.SiteLinks -ne $null)
	{
		foreach ($siteLink in $localSite.SiteLinks)
		{
			$siteDN = $null
			# block going backwords
			if (($siteLink.Sites[0] -ne $null) -and ($siteLink.Sites[0].Name -ne $localSite.Name))
			{
				$siteDN = $siteLink.Sites[0].GetDirectoryEntry().DistinguishedName
			}
			elseif ($siteLink.Sites[1] -ne $null)
			{
				$siteDN = $siteLink.Sites[1].GetDirectoryEntry().DistinguishedName
			}
			if ($siteDN -ne $null)
			{ 
				[void] $SiteList.Add($siteDN)
			}
		}
	}
	# When no exchange server will be found in the current site or adjacent sites, then we should search in all sites
	[void] $SiteList.Add("*")
	$siteList
}

Open in new window

     

There is an issue with your site(s) and/or site link .... for some reason it returns nothing.
If I were you I would go through each step from the above script and check why it fails here  >>>> if (($siteLink.Sites[0] -ne $null) -and ($siteLink.Sites[0].Name -ne $localSite.Name))

So try like this :
Open exchange power shell and start like in the script above :
>$localSite=[System.DirectoryServices.ActiveDirectory.ActiveDirectorySite]::GetComputerSite()
>$localSite
It should give the your site name ... etc
_GetSites
0
 
HornAlumAuthor Commented:
I'll try this, thanks!
0
 
HornAlumAuthor Commented:
ok so if i understand this code right, it pulls up the local site, based off of AD. in the code below, you'll see that we have the same SiteLinks in our local site

Local Site
So, it tries to compile a list of sites based off of site links.

The code fails right away, with the Null array. The "for" loop takes the first SiteLink in $localSite and assigns it to $siteLink.

I decided to try and just display the $siteLink. My default siteLink seems to have no "Sites" in it. That makes sense because if there's no Sites within the SiteLink, then trying to pull up Sites[0] (the first entry in the array), it's going to come up NULL

$siteLink
So ... maybe I have an issue with Sites? I see the DefaultIPSiteLink under IP in Inter-Site Transports within AD S&S. It has 3 sites listed in there, so i don't understand why the code returns that there are no sites within the Site Link
0
 
HornAlumAuthor Commented:
Actually, I just noticed this uses the Rpc Transport type and I don't have the RPC Transport type in AD S&S. Only IP and SMTP.
0
 
HornAlumAuthor Commented:
Ok seems like I just fixed this. We added a site 2 months before the exchange upgrade. Somehow, a conflict site was created. I ended up deleting that CNF site once i realized it was safe to do so.

I went back to the Exchange server and ran these commands again

$site = [System.DirectoryServices.ActiveDirectory.ActiveDirectorySite]::GetComputerSite()
$site.SiteLinks

This time, I ended up seeing the sites listed

Appreciate the help!
0
 
HornAlumAuthor Commented:
I've requested that this question be closed as follows:

Accepted answer: 500 points for sirakov's comment #a38430355
Assisted answer: 0 points for HornAlum's comment #a38433051

for the following reason:

Parsed the code to find that there was a site issue, which by removing conflicting sites, solved the issue
0
 
sirakovCommented:
Glad you figured it out!
0

Featured Post

Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

  • 7
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now