标签:0.0.0.0 获取 lob 127.0.0.1 新建 end weight record admin
globallisten stats :8888
stats enable
stats uri /admin
stats auth admin:1234
frontend oldboy.org
bind 0.0.0.0:80
option httplog
option httpclose
option forwardfor
log global
acl www hdr_reg(host) -i www.oldboy.org
use_backend www.oldboy.org if www
backend www.oldboy.org
server 100.1.7.9 100.1.7.9 weight 20 maxconn 3000
1、查
输入:www.oldboy.org
获取当前backend下的所有记录
2、新建
输入:
arg = {
‘bakend‘: ‘www.oldboy.org‘,
‘record‘:{
‘server‘: ‘100.1.7.9‘,
‘weight‘: 20,
‘maxconn‘: 30
}
}
3、删除
输入:
arg = {
‘bakend‘: ‘www.oldboy.org‘,
‘record‘:{
‘server‘: ‘100.1.7.9‘,
‘weight‘: 20,
‘maxconn‘: 30
}
}
转字符串
eval(变量名)
变量名["字典key"]
标签:0.0.0.0 获取 lob 127.0.0.1 新建 end weight record admin
原文地址:http://blog.51cto.com/13707996/2311806