.NET Framework - WCF service on IIS 5.1 does not works (XP Pro)

Asked By Mikhail S
20-Nov-09 06:15 PM
I cannot get standalone working service. It works perfectly under VC2008
(under ASP.NET development server). It works by Ctrl+F5 until
development server is active. If I stop development server (should be
IIS turn), then it stop working.
My solution includes web project and client project.

WCF Test Client shows followed error message:
// *************************
Error: Cannot obtain Metadata from http://localhost:2899/Service1.svc If
this is a Windows (R) Communication Foundation service to which you have
access, please check that you have enabled metadata publishing at the
specified address.  For help enabling metadata publishing, please refer
to the MSDN documentation at
http://go.microsoft.com/fwlink/?LinkId=65455.WS-Metadata Exchange Error
URI: http://localhost:2899/Service1.svc    Metadata contains a reference
that cannot be resolved: 'http://localhost:2899/Service1.svc'.    Could
not connect to http://localhost:2899/Service1.svc. TCP error code 10061:
No connection could be made because the target machine actively refused
it 127.0.0.1:2899.     Unable to connect to the remote server    No
connection could be made because the target machine actively refused it
127.0.0.1:2899HTTP GET Error    URI: http://localhost:2899/Service1.svc
There was an error downloading 'http://localhost:2899/Service1.svc'.
Unable to connect to the remote server    No connection could be made
because the target machine actively refused it 127.0.0.1:2899
// *************************

And svcutil shows:
// *************************
C:\Program Files\Microsoft Visual Studio 9.0\VC>svcutil
http://localhost:2899/Service1
Microsoft (R) Service Model Metadata Tool
[Microsoft (R) Windows (R) Communication Foundation, Version
3.0.4506.2152]
Copyright (c) Microsoft Corporation.  All rights reserved.

Attempting to download metadata from 'http://localhost:2899/Service1'
using WS-Metadata Exchange or DISCO.
Microsoft (R) Service Model Metadata Tool
[Microsoft (R) Windows (R) Communication Foundation, Version
3.0.4506.2152]
Copyright (c) Microsoft Corporation.  All rights reserved.

Error: Cannot obtain Metadata from http://localhost:2899/Service1

If this is a Windows (R) Communication Foundation service to which you
have access, please check that you have nabled metadata publishing at
the specified address.  For help enabling metadata publishing, please
refer to the MSDN documentation at http://go .microsoft.com/fwlink
?LinkId=65455.

WS-Metadata Exchange Error
URI: http://localhost:2899/Service1
Metadata contains a reference that cannot be resolved:
'http://localhost:2899/Service1'.

Could not connect to http://localhost:2899/Service1. TCP error code
10061: No connection could be made because the target machine actively
refused it 127.0.0.1:2899.

Unable to connect to the remote server
No connection could be made because the target machine actively
refused it 127.0.0.1:2899

HTTP GET Error
URI: http://localhost:2899/Service1
There was an error downloading 'http://localhost:2899/Service1'.

Unable to connect to the remote server
No connection could be made because the target machine actively
refused it 127.0.0.1:2899
// *************************

I publish my web project directly to root: C:\Inetpub\wwwroot\

Thoughts?

Mikhail


*** Sent via Developersdex http://www.developersdex.com ***
Visual Studio
(1)
App Pool
(1)
ASP.NET
(1)
WCF
(1)
IIS
(1)
XP
(1)
Tool
(1)
Exchange
(1)
  Mr. Arnold replied to Mikhail S
20-Nov-09 09:41 PM
If the WCF dev. server app is not converted over to an ASP.NET Web
application against IIS, with an IIS Web virtual directory created for
the application, and creation App Pool entry of the App pool, then it is
not a Web application.



Well the first thing you should have done is typed in
http://localhost/Service1.svc into the Web browser address bar to see if
the Web Service would show its information, which should be on port 80,
the default -- no need to enter a port 80 of localhost:80. If it did not
show by you using the browser first, then something is wrong.

The bottom line is the service is not there listing on port:2899,
because there is no WCF Servic1.svc application there listening.



You should start over and create a WCF Web service project and select
IIS as the infrastructure to use and not File System, you right click
the project in the VS solution and go to Properties and tell it to
create the virtual directory, which the default is port 80, and it will
connect the application to the IIS App Pool.

You can also convert the VS File System Dev solution over to an IIS
ASP.Net Web application too. You can use Google and look it up.
Create New Account
help
Vista support .NET Framework Hi, Is Visual Studio 2003 fully supported under Vista Ultimate ? And about Visual Studio 2005 ? Thanks. C# Discussions Visual Studio.NET 2003 (1) Visual Studio 2005 (1) Visual Studio (1) Vista (1) ASP.NET (1) Update (1) Windows (1) Vstudio
Visual studio 2005 Backward compatibility .NET Framework Is there a way to work on visual studio 2003 projects using visual studio 2005 without converting, maintaining original code? Thanks AM .NET Discussions Visual Studio (1) ASP.NET (1) MsBee (1) Yaleeyangmsblog (1) Messagenews (1) VS2005 (1) COM (1) Hello
Is Microsoft Visual studio 2002 compatible with .NET 2.0? .NET Framework We have an application build on Microsoft Visual Studio 2002 .Net 1.0 ie on 32 bit. Can we port the same application for NET 2.0. Does .NET 2.0 is supported on Microsoft Visual studio 2002 ie for 32 bit application as .NET 2.0 is supported on Microsoft Visual studio 2005. And if yes How .NET 1.0 is to be upgraded to 2.0
Create an Instance of Visual Studio .NET Framework Hi, My C# application have a following code to create an instance of Visual Studio. System.Type type = System.Type.GetTypeFromProgID("VisualStudio.DTE. 8.0"); Object obj = System.Activator.CreateInstance obj; MessageFilter.Register(); dte8Obj.MainWindow.Visible = false; This code work ok in the PC with Visual Studio Installed but doesnt work in the PC with only Framework installed.? How can i make this work in PC with only framework installed? I am using Visual Studio 2005 Thank You miztaken C# Discussions System.Type.GetTypeFromProgID (1) System.Activator.CreateInstance (1) Visual
that is not what I need. I have tried re-installing Service Pack 1 for Visual Studio 2008. I am really hoping that I will not have to to a un-install of Visual Studio. I am running Windows XP Version 5.1.2600 Service Pack 3 Build 2600 Just in-case it is helpful, I am pasting the info from my Visual Studio about window below * ** ** **ABOUT INFO* ** ** * Microsoft Visual Studio 2008 Version 9.0.30729.1 SP Microsoft .NET Framework Version 3.5 SP1 Installed