Re: Rdesktop client and preventing windows logout
MargoAndTodd <[email protected]> Mon, 19 Jul 2010 11:34:36 -0700
| Newsgroups | gmane.network.rdesktop.user |
|---|---|
| Message-ID | <[email protected]> |
On 07/17/2010 08:42 AM, Mark Ryden wrote:
> Hello,
> This question comes as a result of my trials with rdesktop, though it is a bit
> not related directly to rdesktop. I hope though that some rdesktop users
> might help me.
>
> At the company I use rdesktop client from a Linux machine. I connect
> to a Windows
> machine with rdesktop. The thing is that Windows logs out after some half an
> hour or so when
> there is no windows activity, and I need again to enter use name and password.
> This cannot be changed, because this is dictated
> by the sysadmins at this comopany. I cannot change this timeout according to my
> sysadmin. I also tried from the windows menus to change it, and I could not.
>
> I want somehow to cause windows not to close after this period when
> there's no activity.
> Is there some way - writing some automatic script which generates some activity
> - which can avoid closing the windows after this timeout of half an
> hour or so ?
>
> Rgs,
> Mark
Hi Mark,
The problem occurs when the network layer thinks that
that your network socket is stale and "cleans it up"
thinking it is saving resources.
I had to learn this one the hard way. I administer two terminal
servers and had the same stinkin' logout problems. As it
transpires, the "keep Alives" function in Terminal Server (TS)
is not in the configuration dialog for TS, but burried in some
obscure policy section of the regular server. And, M$
leaves it off by default. What exactly do they think you will be
using TS for anyway? (Numskulls.)
This is my write up on the subject:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Terminal Services: Keep Alives
Explaination:
Taken from: http://www.managemore.com/faq/faq-ts.htm
Section 2: Keep Alives:
In the registry at [w2k3 server only]
HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server, create or edit
the DWORD value of KeepAliveEnable and set it to 1. This will turn Keep
Alives on. This will serve to stabilize the connection by sending
'heartbeat' packets to the client every so often. This will cause an
idle connection to be probed every so often just to be sure that the
connection is still alive and that the client is still listening on the
other side. This will also help prevent disconnects by preventing
network devices from killing off sockets that it assumes to be idle.
Because terminal services is such a low bandwidth protocol, when a user
is idle, no network activity will occur. Some network devices will
interpret a connection that is in the idle state for an extended period
of time to be a dead connection, and thus will terminate the socket.
However, when the user comes out of the idle state, the terminal
services client can no longer contact the terminal server because the
socket is dead. By turning on Keep Alives, the connection will not
appear idle, and therefore the network device will not attempt to
terminate the socket.
Solution:
Open the Local Group Policy Editor: <win><r> gpedit.msc
Go to the follow tree:
Computer Configuration\Administrative Templates\Windows
Components\Terminal Services\Terminal Server\Connections
Locate: Configure keep-alive connection interval.
1) Set it to "Enables"
2) Set the ping interval (in minutes)
Reboot
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Here is a pretty picture to go along with the
write up:
http://www.rdesktop.org/tmp/TS.08.KeepAlive.jpg
HTH,
-T
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
rdesktop-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdesktop-users
TS.08.KeepAlive.jpeg.html
(text/html, 2.6 KB)
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type"><title>Terminal Services Keep Alives</title></head> <body> <big style="font-weight: bold; text-decoration: underline;"><big>Terminal Services: Keep Alives</big><br> </big><big><br> </big><big><span style="font-weight: bold;">Explaination:</span><br> Taken from: <a href="http://www.managemore.com/faq/faq-ts.htm">http://www.managemore.com/faq/faq-ts.htm<br> </a></big><big style="font-weight: bold; text-decoration: underline;"><br> </big> <div style="margin-left: 40px;"><big><font face="Arial" size="2"><big><span style="font-weight: bold;">Section 2: Keep Alives:</span></big></font></big><br> <big><font face="Arial" size="2"><big> In the registry at [w2k3 server only] HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server, create or edit the DWORD value of KeepAliveEnable and set it to 1. This will turn Keep Alives on. This will serve to stabilize the connection by sending 'heartbeat' packets to the client every so often. This will cause an idle connection to be probed every so often just to be sure that the connection is still alive and that the client is still listening on the other side. This will also help prevent disconnects by preventing network devices from killing off sockets that it assumes to be idle. Because terminal services is such a low bandwidth protocol, when a user is idle, no network activity will occur. Some network devices will interpret a connection that is in the idle state for an extended period of time to be a dead connection, and thus will terminate the socket. However, when the user comes out of the idle state, the terminal services client can no longer contact the terminal server because the socket is dead. By turning on Keep Alives, the connection will not appear idle, and therefore the network device will not attempt to terminate the socket. </big></font></big></div> <div> <br><big><span style="font-weight: bold;">Solution:</span></big><br><br>Open the <span style="font-style: italic;">Local Group Policy Editor</span>: <win><r> gpedit.msc<br><br>Go to the follow tree:<br><br> Computer Configuration\Administrative Templates\Windows Components\Terminal Services\Terminal Server\Connections<br><br>Locate: Configure keep-alive connection interval.<br> 1) Set it to "Enables"<br> 2) Set the ping interval (in minutes)<br><br>Reboot<br><br><img style="width: 1000px; height: 801px;" alt="Keep Alives" src="TS.08.KeepAlive.jpeg"></div> </body></html>