elmah/default.aspx access not working

143 views
Skip to first unread message

howto

unread,
Apr 6, 2007, 3:19:29 PM4/6/07
to ELMAH
I have gone through the previous posts and have not found any similar
errors to the one I am receiving.
I, like others before me, am having problems accessing the elmah/
default.aspx page. I have also confirmed that no records are being
written to the database.

What I have done so far:
- I have run the sql update script and confirmed that the table and
stored procedures were created.
- I have also updated the connectionString to the correct settings for
my account. I am using a shared hosting environment and .Net 2.0
- copied the web.config settings from the My Documents\MSDN\Using HTTP
Modules and Handlers to Create Pluggable ASP.NET Components folder
that was installed as part of the MSI and modified the
connectionString settings
- added the C:\Program Files\GotDotNet\ELMAH\1.0\bin
\GotDotNet.Elmah.dll file to the bin folder of my site

Please let me know if you would like me to post any additional
information that may help in troubleshooting this problem.

Below is the runtime error that I am receiving:

Server Error in '/' Application.
Format of the initialization string does not conform to specification
starting at index 0.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it originated in the code.

Exception Details: System.ArgumentException: Format of the
initialization string does not conform to specification starting at
index 0.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.

Stack Trace:

[ArgumentException: Format of the initialization string does not
conform to specification starting at index 0.]
System.Data.Common.DbConnectionOptions.GetKeyValuePair(String
connectionString, Int32 currentPosition, StringBuilder buffer, Boolean
useOdbcRules, String& keyname, String& keyvalue) +1242
System.Data.Common.DbConnectionOptions.ParseInternal(Hashtable
parsetable, String connectionString, Boolean buildChain, Hashtable
synonyms, Boolean firstKey) +128
System.Data.Common.DbConnectionOptions..ctor(String
connectionString, Hashtable synonyms, Boolean useOdbcRules) +102
System.Data.SqlClient.SqlConnectionString..ctor(String
connectionString) +52

System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String
connectionString, DbConnectionOptions previous) +24

System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(String
connectionString, DbConnectionPoolGroupOptions poolOptions,
DbConnectionOptions& userConnectionOptions) +125
System.Data.SqlClient.SqlConnection.ConnectionString_Set(String
value) +56
System.Data.SqlClient.SqlConnection.set_ConnectionString(String
value) +4
System.Data.SqlClient.SqlConnection..ctor(String connectionString)
+21
GotDotNet.Elmah.SqlErrorLog.GetErrors(Int32 pageIndex, Int32
pageSize, IList errorEntryList) +84
GotDotNet.Elmah.ErrorLogPage.OnLoad(EventArgs e) +364
System.Web.UI.Control.LoadRecursive() +47
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+1061


Version Information: Microsoft .NET Framework Version:2.0.50727.42;
ASP.NET Version:2.0.50727.210


Any help whatsoever would be much appreciated. Thanks in advance.

Eric

unread,
Apr 6, 2007, 6:49:57 PM4/6/07
to ELMAH
Could you post (or upload) your web.config file?

Eric

howto

unread,
Apr 6, 2007, 11:31:27 PM4/6/07
to ELMAH
Thanks Eric. I actually switched to version 2 and now have it working
for the most part. The elmah/default.aspx page is now working. I
updated the 3 files as per the patch file that was released for Medium
Trust hosting servers.

I am now experiencing 2 different problems. I have not received any
email notifications of any of the errors. I also cannot get the RSS
feed to work.

I have provided a snippet of my web.config below:

<?xml version="1.0"?>
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/
v2.0">

<configSections>
<sectionGroup name="gotdotnet.elmah">
<!-- Indicates that inside the section group there will be
an errorLog section -->
<section name="errorLog"
type="System.Configuration.SingleTagSectionHandler, System,
Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/
>
<!-- Indicates that inside the section group there will be
an errorMail section -->
<section name="errorMail"
type="System.Configuration.SingleTagSectionHandler, System,
Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/
>
</sectionGroup>
</configSections>

<!-- The section group is specific to configuration of ELMAH -->

<gotdotnet.elmah>
<!-- This section contains the type of the error logger
to use (SqlErrorLog, MemoryErrorLog, or a custom logger).
as well as the properties pertinent to the error logger
(e.g., connectionString for the SqlErrorLog). -->
<errorLog type="GotDotNet.Elmah.SqlErrorLog, GotDotNet.Elmah"
connectionStringName="ErrorDB"/>

<!-- To have an administrator e-mailed with details of the
exception, uncomment
the following section. You MUST specify a to e-mail
address;
you can optionally specify a from (default is same as
to);
(consult the code for ErrorMailModule for more optional
setting values) -->
<errorMail
from="ad...@domain.com"
to="ad...@domain.com"
subject="Application Error (ELMAH)"
async="true" />
</gotdotnet.elmah>

<connectionStrings>
<!-- You can add the ELMAH tables into any database. Just run
Database.sql in the ELMAH project. -->
<add name="ErrorDB" connectionString="...mystring is in
here..." providerName="System.Data.SqlClient"/>
</connectionStrings>

<system.web>

<httpHandlers>
<!-- Register that a request to elmah/default.aspx should
be serviced by the
ErrorLogPageFactory HTTP Handler factory -->
<add
verb="POST,GET,HEAD"
path="elmah/default.aspx"
type="GotDotNet.Elmah.ErrorLogPageFactory, GotDotNet.Elmah" />
</httpHandlers>

<httpModules>
<add name="ErrorLog" type="GotDotNet.Elmah.ErrorLogModule,
GotDotNet.Elmah" />

<!-- Adds the ErrorMailModule to the HTTP pipeline. -->
<add name="ErrorMail"
type="GotDotNet.Elmah.ErrorMailModule, GotDotNet.Elmah" />
</httpModules>

</system.web>

<system.net>
<mailSettings>
<smtp deliveryMethod="Network">
<network host="...myhost..." port="25"
defaultCredentials="true"></network>
</smtp>
</mailSettings>
</system.net>

</configuration>

Atif Aziz

unread,
Apr 7, 2007, 6:42:37 AM4/7/07
to el...@googlegroups.com
> I have not received any email notifications of any of the errors.

Try and see if it makes a difference to turn off the async option, as in:

<errorMail ... async="false" />

If this doesn't already solve the problem, it may help reveal further details.

- Atif

howto

unread,
Apr 7, 2007, 8:52:19 AM4/7/07
to ELMAH
I have changed the async value as you suggested but the email still
does not work. What does async do?

> from="a...@domain.com"
> to="a...@domain.com"

Eric

unread,
Apr 7, 2007, 10:02:07 PM4/7/07
to ELMAH
Where's your SMTP/Mail-Server? Do you a local or remote one?
If yes, is there any authentification needed?

Eric

Atif Aziz

unread,
Apr 8, 2007, 9:27:49 AM4/8/07
to el...@googlegroups.com
> What does async do?

It sends the mail using another thread from the thread pool so that the HTTP transaction can end sooner. Sometime, communication with the mail server may take a couple of seconds and so disconnecting the reporting via mail from the lifetime of the HTTP transaction can help in certain cases. It's not a bulletproof method since it drains a thread from the thread pool nonetheless, but that's also why the asynchronous implementation is designed to be overridden for more complex cases.

> but the email still does not work.

Silly question, but have you checked your junk mail folder? I know that previously someone else also complained about e-mail delivery problems and it turned out that the mails were being delivered but getting quarantined as junk.

howto

unread,
Apr 8, 2007, 1:34:26 PM4/8/07
to ELMAH
Eric - I am using a shared hosting plan on GoDaddy. To my knowledge,
I should not need authentication for this host. My web.config is as
follows.

<system.net>
<mailSettings>
<smtp deliveryMethod="network" from="m...@mydomain.com">
<network
host="relay-hosting.secureserver.net"
port="25"
defaultCredentials="true"/>
</smtp>
</mailSettings>
</system.net>


Atif - I have confirmed that no email is being sent to junk.

Thanks to both of you for the input thus far. I hope to resolve this
issue with your help.

Eric

unread,
Apr 8, 2007, 10:30:56 PM4/8/07
to ELMAH
At Godaddy I have read two thing what you could check:
1.
NOTE: "smtpout.secureserver.net" is an SMTP relay server. In order to
use this server to send e-mails, you must first activate SMTP relay on
your e-mail account. Log on to your Manage Email Accounts page to set
up SMTP relay. If you do not have SMTP relay set up and your Internet
Service Provider (ISP) allows it, you can use the outgoing mail server
for your Internet Service Provider. Contact your Internet Service
Provider to get this setting.

-> Have you enabled it?

2. http://products.secureserver.net/email/email_outlook.htm
When I read this, it seems that the ougoing server / SMTP needs
authentification.

I'm not sure which ELMAH version you are using (orginal version
doesn't allow to specify user/pwd).
But you could try to define the settings in you config file like this:
<system.net>
<mailSettings>
<smtp from="na...@mydomain.com">
<network host="relay-hosting.secureserver.net"
userName="myUsername" password="mypassword"/>
</smtp>
</mailSetting
..

Eric


Atif Aziz

unread,
Apr 9, 2007, 12:52:23 AM4/9/07
to el...@googlegroups.com
> I also cannot get the RSS feed to work.

Can you give more information about the problem you're experiencing with the RSS feed? For example, what error is your RSS reader when it tried to read the error feed?

- Atif


-----Original Message-----
From: el...@googlegroups.com [mailto:el...@googlegroups.com] On Behalf Of howto
Sent: Saturday, April 07, 2007 8:31 AM
To: ELMAH
Subject: [ELMAH] Re: elmah/default.aspx access not working

Reply all
Reply to author
Forward
0 new messages