Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8154237
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T16:16:29+00:00 2026-06-06T16:16:29+00:00

I have a service that use the tcp binding and this services allows to

  • 0

I have a service that use the tcp binding and this services allows to the clients interact with the database. I use EF and self tracking entities.

One thing that I want to do is store files in the database, so to not overload the wire, i have two tables with their corresponding entities. One table Documents with the information of the documents (type, size… etc) and other table, Files, that store the binary information, the file.

Well, in local, when I run the client and the service in the same computer, I can store the files that I want. I try with a file of 6MB. But If I run the client in other computer in the same lan, then I have many problems.

For example, if I try to store a small file, 50kB, I don’t have problems, but if I try to store the file of 6MB, then I can get different errors.

For example, if I configure in the client a low timeout, for example 1 minute, I get the error:

System.TimeoutException: This request operation sent to net.tcp://192.168.1.5:7997/CMMSHost did not receive a reply within the configured timeout (00:01:00).

If I configure the client to have a timeout of 10 minutes, then I get the following error:

The server did not provide a meaningful reply

The service is hosted in a wpf application, and in the Begin method of the serve that add the document in the database, I send a text with a log to know if the call is received or not. When I get some of the errors, the call in not received, so I think that the problem perhaps is that the self tacking entity for some reason does not arrive to the service.

My app.config for the service is the following:

<endpoint address=""
                  binding="netTcpBinding"
                  bindingConfiguration="tcpBinding"
                  name="NetTcpBindingEndpoint"
                  contract="GTS.CMMS.Service.IService">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>

        <endpoint contract="IMetadataExchange" binding="mexTcpBinding" address="net.tcp://localhost:5000/mex" />
      </service>
    </services>

    <behaviors>
      <serviceBehaviors>
        <behavior name="behaviorConfig">
          <!--
          <serviceMetadata httpGetEnabled="true" />-->
          <!--Necesario para poder enviar excepciones desde el servicio al cliente.-->
          <serviceDebug includeExceptionDetailInFaults="true"/>
          <serviceThrottling maxConcurrentCalls="100" maxConcurrentSessions="100" />
          <serviceMetadata/>
        </behavior>
      </serviceBehaviors>
    </behaviors>


    <bindings>
      <netTcpBinding>
        <binding name="tcpBinding" maxBufferSize="67108864"
                      maxReceivedMessageSize="67108864" maxBufferPoolSize="67108864"
                       transferMode="Buffered" closeTimeout="00:00:10"
                       openTimeout="00:00:10" receiveTimeout="00:20:00"
                       sendTimeout="00:01:00" maxConnections="100">
          <security mode="None"/>
          <readerQuotas maxArrayLength="67108864" maxBytesPerRead="67108864" maxStringContentLength="67108864"/>
          <reliableSession enabled="true" inactivityTimeout="00:20:00" />
        </binding>
      </netTcpBinding>
    </bindings>
  </system.serviceModel>

And the client configuration is:

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <system.serviceModel>
    <bindings>
      <netTcpBinding>
        <binding name="NetTcpBinding_IService" closeTimeout="00:01:00"
          openTimeout="00:01:00" receiveTimeout="00:01:00" sendTimeout="00:01:00"
          transactionFlow="false" transferMode="Buffered" transactionProtocol="OleTransactions"
          hostNameComparisonMode="StrongWildcard" listenBacklog="10" maxBufferPoolSize="524288"
          maxBufferSize="65536" maxConnections="10" maxReceivedMessageSize="65536">
          <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
            maxBytesPerRead="4096" maxNameTableCharCount="16384" />
          <reliableSession ordered="true" inactivityTimeout="00:20:00"
            enabled="true" />
          <security mode="None">
            <transport clientCredentialType="Windows" protectionLevel="EncryptAndSign" />
            <message clientCredentialType="Windows" />
          </security>
        </binding>
      </netTcpBinding>
    </bindings>
    <client>
      <endpoint address="net.tcp://192.168.1.5:7997/CMMSHost" binding="netTcpBinding"
        bindingConfiguration="NetTcpBinding_IService" contract="IService"
        name="NetTcpBinding_IService" />
    </client>
  </system.serviceModel>
</configuration>

I use a large readquotes, to try to discard that the problem is the size of the file, but the problem persists.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T16:16:31+00:00Added an answer on June 6, 2026 at 4:16 pm

    I don’t think this is an issue related to WCF. I assume its rather related to your IIS.
    Can you try the following code snippet in your web.config?

    <system.webServer>
            <security>
                <requestFiltering>
                    <requestLimits maxAllowedContentLength="524288000"/>
                </requestFiltering>
            </security>
    </system.webServer>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WCF service, that use tcp for the communication. When I try
I have a service with two contracts that I want to use with tcp
I have a WCF based service that I use to expose AJAX functionality. Sometimes
I have a WCF service that processes some messages. I use EntityFramework to retrieve
I have a website that talks to a remote WCF web service. Both use
Is it possible to use Phonegap's Build service to build projects that may have
So, I have a WCF service that is listening on both net.tcp and net.pipe.
I have a self-hosted WCF service that is hosted by a desktop application. I
I have a WCF chat service that accepts duplex tcp connections. A single duplex
I have a Windows Service that is exposing a WCF service thru a net.tcp

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.