<div dir="ltr"><div>Hello,</div><div><br></div><div>Thank you very much for the answer. That clears it up.</div><div><br></div><div>I reckon specifying '-K' on dbclient would then do the same as ServerAliveInterval.</div><div><br></div><div>Cheers,</div><div>Daniel<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 18 Mar 2020 at 14:58, Matt Johnston <<a href="mailto:matt@ucc.asn.au">matt@ucc.asn.au</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Daniel,<br>
<br>
-K is equivalent to the OpenSSH ClientAliveInterval. The server will send traffic to check that the connection is open.<br>
<br>
-I will disconnect if there is no traffic for a certain time interval. It won't try to send any traffic over the connection, it just passively looks at what traffic is being sent.<br>
<br>
Note that it seems that currently -K messages will cause the -I idle timer to reset which isn't right, there's a pull request <a href="https://github.com/mkj/dropbear/pull/90" rel="noreferrer" target="_blank">https://github.com/mkj/dropbear/pull/90</a> which I will merge soon.<br>
<br>
Cheers,<br>
Matt<br>
<br>
<br>
> On Wed 18/3/2020, at 7:22 pm, Dániel Fancsali <<a href="mailto:fancsali@gmail.com" target="_blank">fancsali@gmail.com</a>> wrote:<br>
> <br>
> Hello,<br>
> <br>
> First of all, let me just say this: awesome piece of software. Cheers!<br>
> <br>
> I am, however, a bit confused about the idle/keepalive settings. I have been working with OpenSSH quite a bit, and do understand the concepts around ServerAlive and ClientAlive as well as the TCPKeepAlive settings. But I still struggle to wrap my head around -K and -I in dropbear. It's a tad bit unclear which one maps to which one; or in other words, which one happends on what layer.<br>
> <br>
> Maybe, my mistake here is trying to understand those in the context of the OpenSSH settings, but on some level, it's the same protocol.<br>
> <br>
> So, looking at the code, I think this is what happens:<br>
> - Setting -Kx will send an ssh packed every x seconds, and if there's no answer 3 times in a row, it considers the connection to be dead. So this is essentially ServerAlive/ClientAlive mechanism.<br>
> - Specifying -Iy would say, if there's no incoming or outgoing data for y seconds, it considers the connection dead. So this is sort of the others side of the TCP keepalive coin.<br>
> <br>
> Is my understanding correct? If not, can someone please shed some light on this for me?<br>
> <br>
> Regards,<br>
> Daniel<br>
<br>
</blockquote></div>