View previous topic :: View next topic |
Author |
Message |
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Thu Jul 29, 2010 7:07 am Post subject: |
|
|
Yes a separate test, this time using Active RMA of a customers remote Exchange server. The agent is running using service account that is setup in the same way as the HM account on the HM server; administrator, delegated exchange administrator, run as a service and as a batch job, etc. |
|
Back to top |
|
|
KS-Soft
Joined: 03 Apr 2002 Posts: 12806 Location: USA
|
Posted: Thu Jul 29, 2010 2:17 pm Post subject: |
|
|
We cannot reproduce the problem.
We will modify script for you so you will be able to use Shell Script test method and see error description in Reply field of the test
Regards
Alex |
|
Back to top |
|
|
KS-Soft
Joined: 03 Apr 2002 Posts: 12806 Location: USA
|
Posted: Thu Jul 29, 2010 4:09 pm Post subject: |
|
|
There is sample script that you may use with Shell Script test method, so you should see error description (not just errorlevel code)
Required params: Servername StorageGroupName MDBName
Code: |
Option Explicit
On Error Resume Next
const statusAlive = "scriptRes:Host is alive:"
const statusDead = "scriptRes:No answer:"
const statusUnknown = "scriptRes:Unknown:"
const statusNotResolved = "scriptRes:Unknown host:"
const statusOk = "scriptRes:Ok:"
const statusBad = "scriptRes:Bad:"
const statusBadContents = "scriptRes:Bad contents:"
dim quot, iServer, iMDB, Args, CorrectSyntax, strMode, strComputerName, strSGName, strMDBName, strTemp, arrStGroup, strMDBUrl, i
quot = chr(34)
Set iServer = CreateObject ("CDOEXM.ExchangeServer")
Set iMDB = CreateObject ("CDOEXM.MailboxStoreDB")
Set Args = WScript.Arguments
If Args.count = 3 Then
CorrectSyntax = True
strComputerName = Args(0)
strSGName = Args(1)
strMDBName = Args(2)
Else
CorrectSyntax = False
End If
If CorrectSyntax Then
' Bind to the Exchange Server
iServer.DataSource.Open strComputerName
If Err <> 0 Then
WScript.StdOut.Write statusUnknown & Err.Description
' Cleanup
Set iServer = Nothing
Set iMDB = Nothing
WScript.Quit
End If
strTemp = "LDAP://" & iServer.DirectoryServer & "/" & "cn=" & strMDBName & ","
' Set variant array to the ExchangeServer.StorageGroups
arrStGroup = iServer.StorageGroups
' Look in the StorageGroups array if the StorageGroup with strSGName exists
If strSGName = "" Then
' Add last part to the URL to the MailboxStoreDB
strMDBUrl = strTemp & iServer.StorageGroups(0)
Else
For i = 0 To UBound(arrStGroup)
If InStr(1, UCase(arrStGroup(i)), UCase(strSGName)) <> 0 Then
strMDBUrl = arrStGroup(i)
End If
Next
If strMDBUrl <> "" Then
' Add last part to the URL to the MailboxStoreDB
strMDBUrl = strTemp & strMDBUrl
End If
End If
' Bind to the MailboxStoreDB
iMDB.DataSource.Open strMDBUrl ', , , adCreateOverwrite
If Err <> 0 Then
WScript.StdOut.Write statusUnknown & Err.Description
' Cleanup
Set iServer = Nothing
Set iMDB = Nothing
WScript.Quit
End If
dim sStoreStatus
If iMDB.Status = 0 Then
WScript.StdOut.Write statusOk & "Mounted" & " (" & strSGName & "/" & strMDBName & ")"
ElseIf iMDB.Status = 1 Then
WScript.StdOut.Write statusBad & "Dismounted" & " (" & strSGName & "/" & strMDBName & ")"
ElseIf iMDB.Status = 2 Then
WScript.StdOut.Write statusUnknown & "Store is mounting" & " (" & strSGName & "/" & strMDBName & ")"
ElseIf iMDB.Status = 3 Then
WScript.StdOut.Write statusUnknown & "Store is dismounting" & " (" & strSGName & "/" & strMDBName & ")"
Else
WScript.StdOut.Write statusUnknown & "Unknown Status" & " (" & strSGName & "/" & strMDBName & ")"
End If
' Cleanup
Set iServer = Nothing
Set iMDB = Nothing
Else
WScript.StdOut.Write statusUnknown & "Incorrect syntax. Required params: Servername StorageGroupName MDBName"
End If |
Regards
Alex |
|
Back to top |
|
|
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Sat Jul 31, 2010 3:01 am Post subject: |
|
|
Thanks but getting a Syntax error, the paramaters I am passing are in this format:
SERVER "First Storage Group" "Mailbox Store (SERVER)" |
|
Back to top |
|
|
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Sun Aug 01, 2010 12:29 am Post subject: |
|
|
Strange... all of a sudden it is returning:
"An invalid ADSI pathname was passed" (Typing this reminded me that Copy Reply never works for me).
I tried a different server with the same results.
I also mail enabled the service account just in case and made it a Full Exchange Administrator. No difference to either test. |
|
Back to top |
|
|
KS-Soft
Joined: 03 Apr 2002 Posts: 12806 Location: USA
|
Posted: Mon Aug 02, 2010 9:06 am Post subject: |
|
|
Microsoft says this error can occur when StorageGroupName is incorrect or when "account that you are using is not a part of the Exchange Domain Servers administrator global group"
Regards
Alex |
|
Back to top |
|
|
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Mon Aug 02, 2010 3:32 pm Post subject: |
|
|
The parameters are used locally with no problems from the same account as the RMA service is running under. The server is of course a member of that group as it is an SBS server. Only computer accounts get added to that group not users, users are delegated admin rights through the exchange admin tool. |
|
Back to top |
|
|
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Mon Aug 02, 2010 5:18 pm Post subject: |
|
|
I just configured the script to run on my server (HM local not RMA) and it works perfectly, as does the other test I have running.
It's going to be something simple that's been overlooked but for now I am not seeing what the problem is. |
|
Back to top |
|
|
meppyman
Joined: 06 Sep 2009 Posts: 118 Location: Melbourne
|
Posted: Sun Sep 26, 2010 3:34 am Post subject: |
|
|
Any one got any more ideas with this one? I have a client that has their store go down frequently and it's embarrassing that they know before I do even when it happens after hours. |
|
Back to top |
|
|
|