Chinaunix首页 | 论坛 | 博客
  • 博客访问: 355493
  • 博文数量: 163
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 356
  • 用 户 组: 普通用户
  • 注册时间: 2016-07-01 14:18
文章分类

全部博文(163)

文章存档

2020年(4)

2019年(5)

2018年(4)

2017年(15)

2016年(11)

2015年(10)

2014年(4)

2013年(8)

2012年(13)

2011年(23)

2010年(2)

2009年(16)

2008年(20)

2007年(13)

2006年(12)

2005年(3)

分类:

2008-11-24 17:56:54

! Configuration File for keepalived
global_defs {
   notification_email {
    
    
    
   }
   notification_email_from
   smtp_server 192.168.200.1
   smtp_connect_timeout 30
   router_id LVS_DEVEL
}
vrrp_instance VI_1 {
    state BACKCUP
    interface eth0
    virtual_router_id 51
    priority 199
    advert_int 1
    authentication {
        auth_type PASS
        auth_pass 1111
    }
    virtual_ipaddress {
       1.1.1.1
    }
}
 
   
virtual_server 1.1.1.1 8090 {
    delay_loop 6                  #(每隔10秒查询realserver状态)
    lb_algo wrr                  #(lvs 算法)
    lb_kind DR                   #(Direct Route)
    real_server 1.1.1.2 8090 {
        weight 3               #(权重)
        TCP_CHECK {
        connect_timeout 10       #(10秒无响应超时)
        nb_get_retry 3
        delay_before_retry 3
        connect_port 80
        }
    }
    real_server 1.1.1.3 8090 {
        weight 3
        TCP_CHECK {
        connect_timeout 10
        nb_get_retry 3
        delay_before_retry 3
        connect_port 80
        }
     }
}
阅读(1869) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~