zoukankan      html  css  js  c++  java
  • keepalived健康检查 HTTP_GET

    一:

    real_server 192.168.2.188 80 {
         weight 1
         HTTP_GET {
           url {
           path /index.html
           digest bfaa334fdd71444e45eca3b7a1679a4a #http://192.168.2.188/index.html的digest值          }
                connect_timeout 3
                nb_get_retry 3
                delay_before_retry 3
            }

    digest值的获取方法:
    [root@188-test html]# genhash -s 192.168.2.188 -p 80 -u /index.html
    MD5SUM = bfaa334fdd71444e45eca3b7a1679a4a
    genhash命令:
    [root@188-test html]# genhash
    genhash v1.0.0 (18/11, 2002)
    Usage:
      genhash -s server-address -p port -u url
      genhash -S -s server-address -p port -u url
      genhash -h
      genhash -r

    Commands:
    Either long or short options are allowed.
      genhash --use-ssl         -S       Use SSL connection to remote server.
      genhash --server          -s       Use the specified remote server address.
      genhash --port            -p       Use the specified remote server port.
      genhash --url             -u       Use the specified remote server url.
      genhash --use-virtualhost -V       Use the specified virtualhost in GET query.
      genhash --verbose         -v       Use verbose mode output.
      genhash --help            -h       Display this short inlined help screen.
      genhash --release         -r       Display the release number


    二:

    real_server 192.168.2.188 80 {
          weight 1
          HTTP_GET {
              url {
              path /index.html
              status_code 200     #http://192.168.2.188/index.html的返回状态码
                }
  • 相关阅读:
    StandardWrapper ...$$EnhancerByCGLIB$$b9
    Exception in thread "main" java.lang.ClassCastException: $Proxy13
    Mybatis 源码阅读 (一)
    Thread 中yield(), join()
    java 中类型后面三个点的用法
    JAVA 中汉字在不同编码下的字节不同
    Spring FIlterType
    MyBaties学习记录
    MyBaties学习记录Settings参数详解
    JavaScript学习笔记
  • 原文地址:https://www.cnblogs.com/xzlive/p/12097601.html
Copyright © 2011-2022 走看看