zoukankan      html  css  js  c++  java
  • Linux haproxy配置参数

    http-request

      option http-server-close

      option http-pretend-keepalive

      option httpclose

      option redispatch

      redirect

      reqadd

      rspadd

    tcp-request

    ACL <name> <criterion> [flags] [operator] <value>

    [flags] 

      -i 不区分大小写

      -f 发从制定文件种加载模式

      -- 标识符的强制结束标记

    <criterion>

      be_sess_rate  用于测试指定的backend上会话创建的速率,常用于在指定backend上的会话创建速度过高时将用户请求转发至另外的backend。用于阻止攻击行为

        backend test

          mode http

          acl being_scanned be_sess_rate gt 50

          redirect location /error_pages/denied.html if being_scanned

      fe_sess_rate 用于测试指定的frontend上的会话创建速率是否满足条件,常用于为frontend指定一个合理的会话创建速率以防止服务被滥用。

        frontend mial

          bind:25

          mode tcp

          maxconn 500

          acl too_ fast fe_sess_rate gt 50

          tcp-request inspect-delay 500ms

          tcp-request content accept if ! too_fast

          tcp-request content accept if WAIT_END

      acl header_info hdr(Connection) -i close

      acl method_info method GET

      acl url_begin path_beg -i /static /images

      acl url_end path_end -i .jpg .js .css

      acl header_begin hdr_beg img. ftp.

      acl header_end hdr_end 

      acl url_begin url_beg http://

      acl url_end url_end

        

  • 相关阅读:
    ruby 中 raise 抛出异常
    ruby中attr_accessor方法的理解
    Redis实现分布式缓存
    应用服务器集群概念
    反向代理和正向代理区别
    如何限制同一用户同时登录多台设备?
    Docker 初始
    Java 的反射机制你了解多少?
    JWT 实战
    判断 uniapp 项目运行到 什么机型
  • 原文地址:https://www.cnblogs.com/houyongchong/p/10601411.html
Copyright © 2011-2022 走看看