AGS-如何改變操作系統的'keepalive’設置

原文:http://support.esri.com/index.cfm?fa=knowledgebase.techarticles.articleShow&d=25129

HowTo:  Change the operating system's 'keepalive' settings

Software:  ArcSDE 3.0, 3.0.1, 3.0.2, 3.0.2.1, 3.0.2.2, 8.0.1, 8.0.2, 8.1, 8.1.2, 8.2, 8.3, 9.0, 9.1, 9.2, 9.3

 

Summary

UNIX,Linux和Windows操作系統用'keepalive’設置,來測試空閒TCP連接和確定他們是否任然是活動狀態。默認情況下,'keepalive'被設置爲7200000毫秒(兩小時)。這意味着每隔兩小時服務器計算機ping發出連接的客戶計算機,測試空閒TCP連接,如果服務器沒有從客戶端得到響應,那麼'keepalive'終止這個空閒連接。'keepalive'的間隔時間是能夠被改變的,通過配置操作系統可以實現從兩小時減少到五分鐘。

有時候,一個ArcSDE application server connection (gsrvr) 可能在服務器上落後,這可能由於非正常的gsrvr連接關閉引起。如果這種情況發生,操作系統的'keepalive'設置就能夠移除這個死gsrvr進程來釋放服務器資源。
要一個死gsrvr進程被移除,ArcSDE配置參數‘TCPKEEPALIVE’的值就必須設爲TRUE來實現。他實現ArcSDE來檢查死gsrvr鏈接,基於操作系統的keepalive間隔時間設置。
 WARNING: This article contains instructions to make specific changes to essential parts of your operating system. If these specific changes are not done correctly, it may cause serious problems to your computer operating system and files. First, ESRI recommends that you make a complete backup of your system, including the registry, before implementing any of the specific changes. It is highly recommended that you consult with your IT/MIS department, or other qualified computer systems professional before proceeding. ESRI cannot guarantee that you can solve problems that result from incorrect use of the Registry Editor utility. Use the Registry Editor utility at your own risk. Note: your operating system and any subsequent service packs may affect these instructions. These instructions are subject to change without notice.


 Please consult the operating system documentation for more information on making 'keepalive' setting changes.

 

Procedure

Instructions provided describe how to change the operating system's 'keepalive' settings.

  • On Microsoft Windows set KeepAliveTime to 300000.

    /HKEY_LOCAL_MACHINE/System/CurrentControlSet/Services/TCPIP/Parameters

    If the KeepAlivetime parameter does not already exist in the above location, create it. The time specified is in milliseconds.
  • On Sun Solaris use the ndd command with the -set option to configure the tcp_keepalive_interval.

    # ndd -set /dev/tcp tcp_keepalive_interval 300000

    The time specified is in milliseconds.
  • On IBM AIX use the no command to set communication parameters.

    no -o tcp_keepidle=591

    The time specified is in halfseconds.
  • On HP HP-UX use

    ndd -set /dev/tcp tcp_time_wait_interval 300000

    The time specified is in milliseconds.
  • On RedHat Linux modify the following kernel parameter by editing the /etc/sysctl.conf file, and restart the network daemon (/etc/rc.d/init.d/network restart).

    # Decrease the time default value for tcp_keepalive_time
    
    tcp_keepalive_time = 1800

 

 

Microsoft Knowledge Base Article - 120642 - TCP/IP and NetBT configuration parameters for Windows 2000 or Windows NT ;

Microsoft Knowledge Base Article - 314053 - TCP/IP and NBT configuration parameters for Windows XP

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章