Welcome Guest! To enable all features please Register.

Notification

Icon
Error

New Topic Post Reply
How to remove 500 internal server error on godaddy
Guest
#1 Posted : Wednesday, July 13, 2011 6:40:31 AM(UTC)
Rank: Guest

Joined: 12/12/2009(UTC)
Posts: 443
Points: 1,361
I tried your solution here but could not remove the error:

http://am22tech.com/s/22/Blogs/post/2011/04/20/Remove-500-Internal-Error-and-Show-Actual-Detailed-Error-On-IIS6-and-7-In-Godaddy-Windows-Hosting.aspx

here is the web.config:

Code:

<configuration>


<configsections>
<sectiongroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectiongroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="scriptResourceHandler" requirepermission="false" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectiongroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="Everywhere" name="jsonSerialization" requirepermission="false" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="profileService" requirepermission="false" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="authenticationService" requirepermission="false" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="roleService" requirepermission="false" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">






<appsettings>
<connectionstrings>
<system.web>

<compilation debug="false" explicit="true" strict="false">

<assemblies>
<add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089">
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089">
<add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089">
</add></add></add></add></assemblies>

</compilation>
<pages>
<namespaces>
<clear>
<add namespace="System">
<add namespace="System.Collections">
<add namespace="System.Collections.Generic">
<add namespace="System.Collections.Specialized">
<add namespace="System.Configuration">
<add namespace="System.Text">
<add namespace="System.Text.RegularExpressions">
<add namespace="System.Linq">
<add namespace="System.Xml.Linq">
<add namespace="System.Web">
<add namespace="System.Web.Caching">
<add namespace="System.Web.SessionState">
<add namespace="System.Web.Security">
<add namespace="System.Web.Profile">
<add namespace="System.Web.UI">
<add namespace="System.Web.UI.WebControls">
<add namespace="System.Web.UI.WebControls.WebParts">
<add namespace="System.Web.UI.HtmlControls">
</add></add></add></add></add></add></add></add></add></add></add></add></add></add></add></add></add></add></clear></namespaces>

<controls>
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" namespace="System.Web.UI" tagprefix="asp">
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" namespace="System.Web.UI.WebControls" tagprefix="asp">
</add></add></controls>

</pages>

<authentication mode="Windows">



<httphandlers>
<remove path="*.asmx" verb="*">
<add path="*.asmx" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="*">
<add path="*_AppService.axd" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="*">
<add path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="GET,HEAD">
</add></add></add></remove></httphandlers>
<httpmodules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
</add></httpmodules>


</authentication></system.web>

<system.codedom>
<compilers>
<compiler <br="" extension=".cs" language="c#;cs;csharp" warninglevel="4"> type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<provideroption name="CompilerVersion" value="v3.5">
<provideroption name="WarnAsError" value="false">
</provideroption></provideroption></compiler>
<compiler <br="" extension=".vb" language="vb;vbs;visualbasic;vbscript" warninglevel="4"> type="Microsoft.VisualBasic.VBCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<provideroption name="CompilerVersion" value="v3.5">
<provideroption name="OptionInfer" value="true">
<provideroption name="WarnAsError" value="false">
</provideroption></provideroption></provideroption></compiler>
</compilers>
</system.codedom>


<system.webserver>
<validation validateintegratedmodeconfiguration="false">
<modules>
<remove name="ScriptModule">
<add name="ScriptModule" precondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
</add></remove></modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated">
<remove name="ScriptHandlerFactory">
<remove name="ScriptHandlerFactoryAppServices">
<remove name="ScriptResource">
<add <br="" name="ScriptHandlerFactory" path="*.asmx" precondition="integratedMode" verb="*"> type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add <br="" name="ScriptHandlerFactoryAppServices" path="*_AppService.axd" precondition="integratedMode" verb="*"> type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptResource" path="ScriptResource.axd" precondition="integratedMode" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" verb="GET,HEAD">
</add></add></add></remove></remove></remove></remove></handlers>
</validation></system.webserver>


<runtime>
<assemblybinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentassembly>
<assemblyidentity name="System.Web.Extensions" publickeytoken="31bf3856ad364e35">
<bindingredirect newversion="3.5.0.0" oldversion="1.0.0.0-1.1.0.0">
</bindingredirect></assemblyidentity></dependentassembly>
<dependentassembly>
<assemblyidentity name="System.Web.Extensions.Design" publickeytoken="31bf3856ad364e35">
<bindingredirect newversion="3.5.0.0" oldversion="1.0.0.0-1.1.0.0">
</bindingredirect></assemblyidentity></dependentassembly>
</assemblybinding>
</runtime>


</connectionstrings></appsettings></section></section></section></section></sectiongroup></section></sectiongroup></sectiongroup></configsections></configuration>

Sponsor

Soan
#2 Posted : Wednesday, July 13, 2011 6:47:04 AM(UTC)
Rank: Administration
Soan

Joined: 1/9/2010(UTC)
Posts: 393
Points: 1,158
Location: India
Hi Jignesh,

I just went through your web.config code and it has multiple problems. Looks like some novice has written the code of this file.
I have corrected all of them and here is the new code. Copy and paste this code in your web.config and the 500 internal error should go away.

Code:

<configuration>


<configsections>
<sectiongroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectiongroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="scriptResourceHandler" requirepermission="false" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectiongroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="Everywhere" name="jsonSerialization" requirepermission="false" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="profileService" requirepermission="false" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="authenticationService" requirepermission="false" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section allowdefinition="MachineToApplication" name="roleService" requirepermission="false" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">






<appsettings>
<connectionstrings>
<system.web>

<compilation debug="false" explicit="true" strict="false">

<assemblies>
<add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />

</assemblies>

</compilation>
<pages>
<namespaces>
<clear />
<add namespace="System" />
<add namespace="System.Collections" />
<add namespace="System.Collections.Generic" />
<add namespace="System.Collections.Specialized" />
<add namespace="System.Configuration" />
<add namespace="System.Text" />
<add namespace="System.Text.RegularExpressions" />
<add namespace="System.Linq" />
<add namespace="System.Xml.Linq" />
<add namespace="System.Web" />
<add namespace="System.Web.Caching" />
<add namespace="System.Web.SessionState" />
<add namespace="System.Web.Security" />
<add namespace="System.Web.Profile" />
<add namespace="System.Web.UI" />
<add namespace="System.Web.UI.WebControls" />
<add namespace="System.Web.UI.WebControls.WebParts" />
<add namespace="System.Web.UI.HtmlControls" />


</namespaces>

<controls>
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" namespace="System.Web.UI" tagPrefix="asp" />
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" namespace="System.Web.UI.WebControls" tagPrefix="asp" />

</controls>

</pages>

<authentication mode="Windows" />



<httpHandlers>
<remove path="*.asmx" verb="*" />
<add path="*.asmx" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="*" />
<add path="*_AppService.axd" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="*" />
<add path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false" verb="GET,HEAD" />


</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
</add>
</httpModules>



</system.web>

<system.codedom>
<compilers>
<compiler extension=".cs" language="c#;cs;csharp" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v3.5" />
<providerOption name="WarnAsError" value="false" />

</compiler>
<compiler extension=".vb" language="vb;vbs;visualbasic;vbscript" warningLevel="4"
type="Microsoft.VisualBasic.VBCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v3.5" />
<providerOption name="OptionInfer" value="true" />
<providerOption name="WarnAsError" value="false" />

</compiler>
</compilers>
</system.codedom>


<system.webserver>
<validation validateintegratedmodeconfiguration="false">
<modules>
<remove name="ScriptModule">
<add name="ScriptModule" precondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
</add>
</remove>
</modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated" />
<remove name="ScriptHandlerFactory" />
<remove name="ScriptHandlerFactoryAppServices" />
<remove name="ScriptResource" />
<add name="ScriptHandlerFactory" path="*.asmx" precondition="integratedMode" verb="*"
type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptHandlerFactoryAppServices" path="*_AppService.axd" precondition="integratedMode" verb="*"
type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptResource" path="ScriptResource.axd" precondition="integratedMode" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" verb="GET,HEAD" />

</handlers>
</validation>
</system.webserver>


<runtime>
<assemblybinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentassembly>
<assemblyidentity name="System.Web.Extensions" publickeytoken="31bf3856ad364e35">
<bindingredirect newversion="3.5.0.0" oldversion="1.0.0.0-1.1.0.0">
</bindingredirect>
</assemblyidentity>
</dependentassembly>
<dependentassembly>
<assemblyidentity name="System.Web.Extensions.Design" publickeytoken="31bf3856ad364e35">
<bindingredirect newversion="3.5.0.0" oldversion="1.0.0.0-1.1.0.0">
</bindingredirect>
</assemblyidentity>
</dependentassembly>
</assemblybinding>
</runtime>


</connectionstrings>
</appsettings>
</section>
</section>
</section>
</section>
</sectiongroup>
</section>
</sectiongroup>
</sectiongroup>
</configsections>
</configuration>
Guest
#3 Posted : Wednesday, July 13, 2011 4:53:26 PM(UTC)
Rank: Guest

Joined: 12/12/2009(UTC)
Posts: 443
Points: 1,361
Still getting the same error..
"500 (Internal Server) Error "
Soan
#4 Posted : Wednesday, July 13, 2011 6:04:41 PM(UTC)
Rank: Administration
Soan

Joined: 1/9/2010(UTC)
Posts: 393
Points: 1,158
Location: India
Hi Jignesh,

If you are still getting errors, then i would say that you need to take help of a asp.net developer to look into your Godaddy acoount configuration and your web site code.
500 internal server error is too generic to give you any specific solution.

Also, i corrected all probable problems with the web.config and if that does not solve your issues...somebody needs to look into it to what exactly is causing an issue.

Soan.
Guest
#5 Posted : Wednesday, July 20, 2011 5:03:22 AM(UTC)
Rank: Guest

Joined: 12/12/2009(UTC)
Posts: 443
Points: 1,361
hi soan..
the problem was the same..
i had asp.net 4.0 enabled by default and my application is in ver 3.5....
thank you for your help..
Soan
#6 Posted : Wednesday, July 20, 2011 6:56:17 AM(UTC)
Rank: Administration
Soan

Joined: 1/9/2010(UTC)
Posts: 393
Points: 1,158
Location: India
Great..
I am glad it had worked for you.

Let me know if you need more help.

Soan
Guest
#7 Posted : Friday, December 23, 2011 12:42:36 AM(UTC)
Rank: Guest

Joined: 12/12/2009(UTC)
Posts: 443
Points: 1,361
Hi,

I am also getting the same error 500.

I have a hosting plan with godaddy. In this plan, I can include multiple domains. In one such domain ( not the primary), I want my .net application to run.

xxx.com (primary)
|_ yy.com
|_ xyz.com and so on.

In xyz.com, I want my .net application to run. In the domain folder, my aspx (simple registration page) files reside along with web.config file.

<connectionStrings>
<add name="xx" connectionString=" Data Source=xx.db.xx.hostedresource.com; Initial Catalog=xx; User ID=xx; Password=xx;">
</connectionStrings>
<configuration>
<system.webServer>
<httpErrors errorMode="Detailed" />
<asp scriptErrorSentToBrowser="true"/>
</system.webServer>
<system.web>
<customErrors mode="Off"/>
<compilation debug="true" strict="false" explicit="true" />
<trace enabled="true" pageOutput="true" />
</system.web>
</configuration>

my aspx file


<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<table style="position: relative">
<tr>
<td style="width: 100px">
</td>
<td style="width: 100px">
</td>
<td style="width: 100px">
</td>
</tr>
<tr>
<td style="width: 100px">
<asp:TextBox ID="TextBox1" runat="server" Style="position: relative"></asp:TextBox></td>
<td style="width: 100px">
<asp:TextBox ID="TextBox2" runat="server" Style="position: relative"></asp:TextBox></td>
<td style="width: 100px">
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Style="position: relative"
Text="Button" /></td>
</tr>
<tr>
<td style="width: 100px">
</td>
<td style="width: 100px">
</td>
<td style="width: 100px">
</td>
</tr>
</table>

</div>
</form>
</body>
</html>


code behind cs file

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;


public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

}
protected void Button1_Click(object sender, EventArgs e)
{
string aa = ConfigurationManager.ConnectionStrings["xx"].ConnectionString;
SqlConnection con = new SqlConnection(aa);
con.Open();
string name = TextBox1.Text;
string pwd = TextBox2.Text;

string str = "insert into login values('" + name + "', '" + pwd + "', '" + pwd + "', '" + pwd + "')";
SqlCommand cmd = new SqlCommand(str, con);

cmd .ExecuteNonQuery ();


}
}

I have been on this issue for over a month. no help from godaddy



Soan
#8 Posted : Tuesday, December 27, 2011 4:00:38 AM(UTC)
Rank: Administration
Soan

Joined: 1/9/2010(UTC)
Posts: 393
Points: 1,158
Location: India
Does your primary site work fine or it is also throwing the 500 internal server error?

If the primary site is working fine, then you have issue with the child site's web.config.

Also, do check the version of asp.net that is enabled for you on Godaddy.

You also need to include the inheritchild="false" tag in the parent (root) site's webconfig. Look here for the exact answer:
http://am22tech.com/s/22/Forum1/forum.aspx?g=posts&t=2

Let me know if this solves the issue or we need to look deeper.
Quick Reply Show Quick Reply
Users browsing this topic
Guest
New Topic Post Reply
Forum Jump  
You can post new topics in this forum.
You can reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.