5 Replies - 3867 Views - Last Post: 25 November 2013 - 05:50 AM

#1 maurices5000  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 13
  • Joined: 26-July 12

Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 16 November 2013 - 10:45 AM

I'm getting an error when I try to run my WCF Service on IIS instead of ASP.NET Development Server.



I'm not exactly sure how these addresses work. But it think it is related to an address somewhere.

I'm using a console app to test the service. I've never had problems with the service until i tried using the IIS port.

Here is my app.config file of the console app. The top address and port number is the ASP.NET Dev Server port. The second one is the IIS port.
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
    <system.serviceModel>
        <bindings>
            <wsHttpBinding>
                <binding name="WSHttpBinding_IWebService" />
            </wsHttpBinding>
        </bindings>
        <client>
			<!-- <endpoint address="http://localhost:5182/Service.svc" binding="wsHttpBinding"-->
            <endpoint address="http://localhost:9876/Service.svc" binding="wsHttpBinding"
                bindingConfiguration="WSHttpBinding_IWebService" contract="MyWCF_ServiceReference.IWebService"
                name="WSHttpBinding_IWebService">
                <identity>
                    <dns value="localhost" />
                </identity>
            </endpoint>
        </client>
    </system.serviceModel>
</configuration>



Click on the images to see a bigger picture.

This is the error mesage:

Posted Image


Is there a reason why the address below is different from the previous ones?

http:// localhost:8732 /Design_Time_Addresses/WCFServiceLibrary/WebService/mex

Posted Image


This is where it is crashing for some unknown reason.

Posted Image


This shows that at the WCF Service itself, the ValidPerson is actually working.

Posted Image


Here is the conf file its running on.

Posted Image

Is This A Good Question/Topic? 0
  • +

Replies To: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

#2 maurices5000  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 13
  • Joined: 26-July 12

Re: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 16 November 2013 - 01:25 PM

Clarification: I don't get an error when I run the WCF Service when using a Windows Service or ASP.NET Development Server. ONLY IIS is the problem.
Was This Post Helpful? 0
  • +
  • -

#3 no2pencil  Icon User is offline

  • Admiral Fancy Pants
  • member icon

Reputation: 5363
  • View blog
  • Posts: 27,325
  • Joined: 10-May 07

Re: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 20 November 2013 - 06:07 AM

How are you determining to use these ports? 8732, 9876, & 5182? Are you certain they are open on your firewall? Is IIS binding these ports?
Was This Post Helpful? 0
  • +
  • -

#4 maurices5000  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 13
  • Joined: 26-July 12

Re: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 24 November 2013 - 10:19 PM

Sorry I didn't notice you had replied.

8732 - This one is my window service port (works fine)

9876 - This port is IIS (Works but not on SQL Server)

5182 - This port is ASP Development Server (Works fine)

All of them work and connect to the database except 9876. Port 9876 works until i trying to connect to SQL Server

Thanks! I've been working on this for days and still I've gotten no wehre.
Was This Post Helpful? 0
  • +
  • -

#5 maurices5000  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 13
  • Joined: 26-July 12

Re: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 25 November 2013 - 01:47 AM

I went in SQL Server and granted the account for my application pool DBO access in other words the db_owner role and it worked. I feel like that is too many permissions but works nonetheless. Posted Image
Was This Post Helpful? 1
  • +
  • -

#6 no2pencil  Icon User is offline

  • Admiral Fancy Pants
  • member icon

Reputation: 5363
  • View blog
  • Posts: 27,325
  • Joined: 10-May 07

Re: Getting Error using IIS but NOT ASP.NET Dev Server. Why?

Posted 25 November 2013 - 05:50 AM

Thank you for posting your solution.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1