我在一个项目中工作,把我们的SIP移动到下面。敬GCP。
我使用带有私有IP的UDP内部负载均衡器将呼叫从Asterisk路由到我的Kamailio SBC,Asterisk被配置为负载均衡器的地址IP作为单个传出端点。

我的内部UDP负载均衡器运行在5060前端,后端有2 SBC和端口80上的基本http健康检查。
在每个kamailio上,我的应用程序列表在端口5060上,apache服务器在端口80上进行健康检查,因此停止httpd将实例的状态更改为不健康。
forwarding-rules
# gcloud compute forwarding-rules describe ip-gateway-internal-lb-local-fontend --region=europe-west3
IPAddress: 10.156.0.15
IPProtocol: UDP
backendService: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3/backendServices/My-gateway-internal-lb-bservices
creationTimestamp: '2018-01-30T10:20:19.564-08:00'
description: ''
id: 'XXXXXXXXXXXXX'
kind: compute#forwardingRule
loadBalancingScheme: INTERNAL
name: ip-gateway-internal-lb-local-fontend
network: https://www.googleapis.com/compute/v1/projects/My-Project/global/networks/default
ports:
- '5060'
region: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3
selfLink: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3/forwardingRules/ip-gateway-internal-lb-local-fontend
subnetwork: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3/subnetworks/defaultbackend-service
# gcloud compute backend-services describe My-gateway-internal-lb-bservices --region=europe-west3
backends:
- balancingMode: CONNECTION
description: ''
group: https://www.googleapis.com/compute/v1/projects/My-Project/zones/europe-west3-a/instanceGroups/My-gateway-1xx
connectionDraining:
drainingTimeoutSec: 0
creationTimestamp: '2018-01-30T10:15:10.688-08:00'
description: ''
fingerprint: XXXXXXXXX
healthChecks:
- https://www.googleapis.com/compute/v1/projects/My-Project/global/healthChecks/basic-check-internal-http
id: 'XXXXXXXXX'
kind: compute#backendService
loadBalancingScheme: INTERNAL
name: My-gateway-internal-lb-bservices
protocol: UDP
region: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3
selfLink: https://www.googleapis.com/compute/v1/projects/My-Project/regions/europe-west3/backendServices/My-gateway-internal-lb-bservices
sessionAffinity: NONE
timeoutSec: 3健康检查
# gcloud compute health-checks describe basic-check-internal-http
checkIntervalSec: 3
creationTimestamp: '2018-01-31T01:13:25.030-08:00'
description: ''
healthyThreshold: 2
httpHealthCheck:
host: ''
port: 80
proxyHeader: NONE
requestPath: /
id: 'XXXXXXXXXXXXXXXXXXXX'
kind: compute#healthCheck
name: basic-check-internal-http
selfLink: https://www.googleapis.com/compute/v1/projects/My-Project/global/healthChecks/basic-check-internal-http
timeoutSec: 3
type: HTTP
unhealthyThreshold: 2所有超时设置为3s,由会话关联(持久化)完成的内部UDP LB路由规则不会立即被删除,移除大约需要15分钟(没有任何通信量)。
同样的情况下,当一个实例再次恢复健康时,LB需要15分钟才能考虑并开始接收流量。
当我使用带有外部地址IP的UDP负载均衡器时,我没有遇到这个问题,因为发送通信量的星号地址是本地的,所以每个调用的5元组哈希都不同。
但是对于使用内部IP的UDP LB,5元组散列总是相同的(相同的src/dst IP:Port),因此我如何配置会话关联(持久性)规则的超时,或者强制刷新我的LB内存。
也许是一只虫子!有谁遇到过同样的问题吗?谢谢,期待有人能帮我解决这个问题吗?
布尔乌斯
发布于 2018-02-02 09:01:58
https://stackoverflow.com/questions/48548452
复制相似问题