I tried more than a week without any success to host a very simple wcf service like HelloWorld using netTcpBinding.
With http, everything is fine. I can access my service even from a remote machine. But tcp problems arise.
I followed all the steps that I intended to host my service in WAS:
.Net 3.0 included, including http and non-http activation
I granted the "Network Service" and "IIS_IUSRS" the following permissions for the folder containing the site:
- Read and execute
- Folder List Contents
- Read
Opened ports 8100 and 8086 in the firewall.
The following bindings are set in IIS / Actions / Bindings Manager:
- http 8100: *
- net.tcp 8086: *
HTTP and net.tcp are enabled in IIS Manager / Website Management / Advanced Settings.
The initial problem that I encountered was that I was able to contact the service via http, but when I tried using tcp, I got the following error:
"The message cannot be sent because the service at the endpoint addres 'net.tcp: //myDomain/HelloWorld.Hello.svc' is not available for the protocol address. "
I found a post on this site whose author had the same problem and it was resolved by reinstalling .net 3.0 functions. So I tried this. I also tried reinstalling IIS 7.0 just in case. Now the situation is worse than at the beginning. If I configure the endpoint with tcpBinding in my Web.Config, I canβt even contact my service at this http address using IE! I get the following message:
Could not find a base address matching net.tcp for the endpoint with NetTcpBinding. Schemes of registered base addresses: [http].
The Web.Config file is as follows:
name="HelloWorld.Hello"> <host> <baseAddresses> <add baseAddress="http://myDomain:8100/HelloWorld/" /> <add baseAddress="net.tcp://myDomain:8086/HelloWorld/" /> </baseAddresses> </host> <endpoint address="" binding="wsHttpBinding" contract="HelloWorld.IHello" bindingConfiguration="httpInseguro"> </endpoint> <endpoint address="" binding="netTcpBinding" contract="HelloWorld.IHello" bindingConfiguration="netTcpInseguro"> </endpoint> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" /> </service> </services> <bindings> <wsHttpBinding> <binding name ="httpInseguro"> <security mode ="None" /> </binding> </wsHttpBinding> <netTcpBinding> <binding name ="netTcpInseguro"> <security mode ="None" /> </binding> </netTcpBinding> </bindings>
and the .svc file looks like this:
Can someone please let me know what is going on? I really don't know what else to do. This is a real well, because using http binding is not an option. Thanks in advance.
iis-7 wcf nettcpbinding
Gonzalo mendez
source share