zoukankan      html  css  js  c++  java
  • linux 系统ssh超时设置

    1.修改client端的etc/ssh/ssh_config添加以下:(在没有权限改server配置的情形下)

    ServerAliveInterval 60 #client每隔60秒发送一次请求给server,然后server响应,从而保持连接
    ServerAliveCountMax 3 #client发出请求后,服务器端没有响应得次数达到3,就自动断开连接,正常情况下,server不会不响应

    2打开SSH服务的配置文件:/etc/ssh/sshd_config
    ClientAliveInterval 120 每隔120秒向客户端发送一个“空包”,以保持于客户端的连接
    ClientAliveCountMax 720 总共发送720次“空包”,之后断开它们之间的连接,也就是:120秒 × 720 = 86400 秒 = 24小时 后

  • 相关阅读:
    富文本
    frame,bounds,position,anchorPoint理解
    内存相关
    OpenGL
    Xcode 编译选项详解
    iOS 工程引用
    iOS 事件传递和消息处理
    UICollectionView用法
    数据库
    多线程
  • 原文地址:https://www.cnblogs.com/zhengchunyuan/p/11712082.html
Copyright © 2011-2022 走看看