博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
33.8. slb configuration
阅读量:6608 次
发布时间:2019-06-24

本文共 5357 字,大约阅读时间需要 17 分钟。

33.8.1. slb real

slb real http 
[port] [max_conn][{http|tcp|icmp|script-tcp|script-udp|sip-tcp|sip-udp}] [hc_up] [hc_down]slb real tcp
[max_conn][{http|tcp|icmp|script-tcp|script-udp|sip-tcp|sip-udp}] [hc_up] [hc_down]slb real ftp
[port] [max_conn] [{tcp|icmp|script-tcp|script-udp|sip-tcp|sip-udp}] [hc_up] [hc_down]slb real udp
[max_conn] [hc_up] [hc_down] [timeout] [{icmp|script-tcp|script-udp|radius-auth|radius-acct}]slb real https
[port] [max_conn] [{https|tcp|tcps|icmp|script-tcp|script-udp|script-tcps|sip-tcp|sip-udp}] [hc_up] [hc_down]slb real tcps
[max_conn] [{tcp|tcps|icmp|script-tcp|script-udp|script-tcps|sip-tcp|sip-udp}] [hc_up] [hc_down]slb real dns
[max_conn] [{dns|icmp|script-tcp|script-udp|sip-tcp|sip-udp}] [hc_up] [hc_down] [timeout]slb real siptcp
[port] [max_conn] [{ http|tcp|icmp|script-tcp|script-udp|sip-tcp|sip-udp}] [hc_up][hc_down]slb real sipudp
[port] [max_conn] [{icmp|script-tcp|script-udp|radius-auth|radius-acct|sip-tcp|sip-udp}] [hc_up][hc_down][timeout]slb real rtsp
[port] [max_conn] [{rtsp-tcp|tcp|icmp|script-tcp|script-udp|none}] [hc_up] [hc_down] [timeout]

基于三层(IP)的类型为“IP”的后台服务。该类服务能同时支持TCP和UDP协议

slb real ip 
[max_conn] [{icmp|none}] [hc_up] [hc_down] [udp timeout]

例 33.1. slb real http

slb real http rs1 172.16.0.9 80slb real http rs2 172.16.0.5 80Array(config)#show slb real httpslb real http "rs1" 172.16.0.9 80 1000 tcp 3 3slb real http "rs2" 172.16.0.5 80 1000 tcp 3 3Array(config)#clear  slb real httpslb real http rs1 172.16.0.9 80 4096 httpslb real http rs2 172.16.0.5 80	4096 httpArray(config)#show slb real httpslb real http "rs1" 172.16.0.9 80 4096 http 3 3slb real http "rs2" 172.16.0.5 80 4096 http 3 3Array(config)#show health server----------------------------------- Server Status ---------------------------------real server name      statusrs1                   UPrs2                   UP----------------------------------- Health Check ----------------------------------real server name      ip              :port    status  hct        rqr rpr checklist-----------------------------------------------------------------------------------rs1                   172.16.0.9      :80      UP      http         0   0rs2                   172.16.0.5      :80      UP      http         0   0

33.8.2. slb virtual

4-7 layer slb

slb virtual http 
[vport] [{arp|noarp}] [max_conn]slb virtual https
[vport] [{arp|noarp}] [max_conn]slb virtual tcp
[{arp|noarp}] [max_conn]slb virtual tcps
[{arp|noarp}] [max_conn]slb virtual ftp
[vport] [max_conn]slb virtual udp
[{arp|noarp}] [max_conn]slb virtual dns
[vport] [{arp|noarp}] [max_conn]slb virtual sipudp
[vport] [{arp|noarp}] [max_conn]slb virtual siptcp
[vport] [{arp|noarp}] [max_conn]slb virtual rtsp
[vport] [mode] [noarp] [max_conn]

3 layer slb

slb virtual ip 
这个命令是用来创建基于三层协议的负载均衡操作的虚拟服务。这种虚拟服务可以同时支持TCP和UDP协议。

例 33.2. slb virtual http

slb virtual http vs1 172.16.0.3 80Array(config)#show slb virtual httpslb virtual http "vs1" 172.16.0.3 80 arp 0

33.8.3. slb group method

slb group method 
[algorithm]algorithm 在组内的后台服务中进行负载均衡的算法。可选参数,缺省值为轮循(rr)。基于使用的算法,需要不同的扩展参数。下面标有"*"的算法需要扩展参数。 rr 轮循 pc 保持 Cookie* pi 保持 IP地址* hi Hash IP地址* hc Hash Cookie* ph 保持域名* pu 保持 URL* ic 插入 Cookie* rc 改写 Cookie* ec 嵌入 Cookie* lc 最少连接数* sr 最短响应时间 hh Hash Header* sslsid SSL Session ID* chi Consistent Hash IP* prox 就近性* snmp 简单网络管理协议* sipcid SIP CallID* sipuid SIP UserID* chh Consistent Hash Header* hq Hash Query* hip Hash (IP+Port) *

例 33.3. slb group method

Array(config)#slb group method gm1 rrArray(config)#show slb group methodslb group method "gm1" rr

33.8.4. slb group member

slb group member 

例 33.4. slb group member

Array(config)#slb group member gm1 rs1Array(config)#slb group member gm1 rs2Array(config)#show slb group member gm1slb group member "gm1" "rs1" 1slb group member "gm1" "rs2" 1

33.8.5. slb policy

slb policy default "vs1" "gm1"

例 33.5. slb policy default

Array(config)#slb policy default "vs1" "gm1"Array(config)#show slb policy allslb policy default "vs1" "gm1"

33.8.6. slb group flush

这条命令允许系统管理员清空指定服务组的保持性关系表。这条命令会消除所有已经建立的保持性关系,所有使用这条命令时有提醒信息。已经建立保持连接的用户,会被迫重新建立保持性连接。“group_name”参数,必须是采用hc、hh、ph或者pi算法的服务组。

slb group flush

33.8.7. slb configuration example

例 33.6. slb example

slb real http "http-nginx-0" 10.0.0.68 80 100000 http 3 3slb real http "http-nginx-1" 10.0.0.69 80 100000 http 3 3slb real http "http-user-1" 10.0.0.24 80 100000 http 3 3slb real http "http-user-2" 10.0.0.25 80 100000 http 3 3slb real http "http-user-3" 10.0.0.26 80 100000 http 3 3slb group method "group-nginx-0" rrslb group member "group-nginx-0" "http-nginx-0" 1 0slb group member "group-nginx-0" "http-nginx-1" 1 0slb virtual http "vs-nginx-http" 172.16.0.60 80 arp 0slb group method "group-user-0" rrslb group member "group-user-0" "http-user-1" 1 0slb group member "group-user-0" "http-user-2" 1 0slb group member "group-user-0" "http-user-3" 1 0slb virtual http "vs-user-http" 172.16.0.61 80 arp 0slb policy default "vs-nginx-http" "group-nginx-0"slb policy default "vs-user-http" "group-user-0"

原文出处:Netkiller 系列 手札
本文作者:陈景峯
转载请与作者联系,同时请务必标明文章原始出处和作者信息及本声明。

你可能感兴趣的文章
Ubuntu+Apache+PHP+Mysql环境搭建(完整版)
查看>>
Atitit.计算机图形图像图片处理原理与概论attilax总结
查看>>
于ssh端口转发的深入实例[转 - 当当 - 51CTO技术博客
查看>>
从Python安装到语法基础,这才是初学者都能懂的爬虫教程 ...
查看>>
超级AD远程管理软件
查看>>
Oracle数据库安全加固记录
查看>>
安全运维之:Linux系统账户和登录安全
查看>>
【cocos2d-x从c++到js】17:使用FireFox进行JS远程调试
查看>>
Kafka Offset Storage
查看>>
深度学习笔记之CNN(卷积神经网络)基础
查看>>
JAVA设计模式之【原型模式】
查看>>
Hadoop 添加删除数据节点(datanode)
查看>>
33.8. slb configuration
查看>>
ext的window如何隐藏水平滚动条
查看>>
71.8. Run level shell script to start Oracle 10g services on RedHat Enterprise Linux (RHAS 4)
查看>>
SAP QM Transfer of Inspection Stock
查看>>
全新视觉| 数治省市:SAP大数据构想一切可能
查看>>
ORACLE expdp备份与ORA-31693、ORA-02354、ORA-02149
查看>>
SAP S/4 HANA新变化-信用管理
查看>>
doc-remote-debugging.html
查看>>