Coder Social home page Coder Social logo

Comments (6)

yelfarri avatar yelfarri commented on July 24, 2024

@Oxalin the keepalive (heartbeat) was completed I see the keepalive message when using Wireshark. Isn't keepAlive a part of the TCPIP or from the application? Since we are getting the keepAlive messages does that mean that the configuration of time and interval in application side is wrong?

image

from usbip-win.

Oxalin avatar Oxalin commented on July 24, 2024

It can be set system wide and per application / socket. From my quick overlook at usbipd, the application is not setting any customized Keep-Alive options, thus relying on the system's default values.

from usbip-win.

yelfarri avatar yelfarri commented on July 24, 2024

I understand but I m talking about usbip client side. I Found in code that usbip has a keepalive function call in "usbip_network.c" line 206. If I remember correctly this call does not set time and intervals. It might be using system default values.
Is "usbip_network.c" shared between usbipd server and usbip client?

from usbip-win.

Oxalin avatar Oxalin commented on July 24, 2024

Yes, indeed. setsockopt() could be called to set the IPPROTO_TCP socket options (as described here https://docs.microsoft.com/en-us/windows/desktop/WinSock/ipproto-tcp-socket-options).However, many options are only available under Windows 10 (1709 and up), even though there are commonly available under Linux...

Thus, I would be tempted to add a heartbeat (keepalive) at the application level. This way, we will be able to support a decent heartbeat in any Windows version. That's why the usbip_net_set_keepalive() doesn't set any IPPROTO_TCP socket options: it was supposed to be added under usbip_net_tcp_connect(). See line 259.

from usbip-win.

cezuni avatar cezuni commented on July 24, 2024

@Oxalin : I agree that application-level heartbeat can help to detect abortive disconnection more quickly. But it's impossible without usbip protocol modification. I think that it's a too big task to resolve at usbip-win project level.

from usbip-win.

cezanne avatar cezanne commented on July 24, 2024

Socket-specific KeepAlive is implemented by be88d56. Application-level heartbeat might be not useful unless a linux implementation follows.

from usbip-win.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.