envoyproxy / envoyproxy/gateway
Shutdown-manager failed with `hostNetwork` deployment mode
- Dominant language
- Go
- Stars
- 3k
- Forks
- 864
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 148
Description
*Description*:
>When deployed in the `hostNetwork` mode, the shutdown-manager will fail. The `envoy` process exited immidate when pod deleted and shutdown-manager failed with connect `localhost:19000`. Without `hostNetowrk`, that is all work.
*Environment*:
```
ubernetes: v1.31.1
envoy-gateway: v1.7.1
envoy: v1.35.3
```
*Logs*:
The `shutdown-manager` logs:
```
2026-06-25T05:42:20.191Z INFO shutdown-manager envoy/shutdown_manager.go:77 starting shutdown manager
2026-08-26T08:32:34.994Z INFO shutdown-manager envoy/shutdown_manager.go:130 initiating drain with 10 second minimum drain period and 60 second timeout
2026-08-26T08:32:34.995Z ERROR shutdown-manager envoy/shutdown_manager.go:135 error failing active health checks {"error": "Post \"http://localhost:19000/healthcheck/fail\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:34.995Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:35.996Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:36.997Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:37.998Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:38.999Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:40.000Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:41.002Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:42.002Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:43.004Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:44.006Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:45.006Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:45.006Z INFO shutdown-manager envoy/shutdown_manager.go:149 minimum drain period reached; will exit when total connections reaches 0
2026-08-26T08:32:46.007Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:47.009Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:48.009Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:49.010Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:50.011Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:51.012Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:52.013Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:53.014Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:54.014Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:55.015Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:56.016Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:57.017Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:58.019Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:32:59.020Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:00.022Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:01.023Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:02.024Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:03.025Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:04.025Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:05.026Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:06.028Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:07.028Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:08.029Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:09.030Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:10.031Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:11.032Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:12.032Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:13.033Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:14.034Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:15.035Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:16.036Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:17.037Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:18.037Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:19.038Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:20.039Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:21.040Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:22.041Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:23.042Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:24.043Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:25.044Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:26.045Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:27.046Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:28.047Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:29.048Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:30.050Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:31.050Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:32.051Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:33.052Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:34.053Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:35.054Z ERROR shutdown-manager envoy/shutdown_manager.go:145 error getting total connections {"error": "error getting listener downstream_cx_active stat: Get \"http://localhost:19000//stats?filter=^listener\\\\..*\\\\.downstream_cx_active$&format=json\": dial tcp [::1]:19000: connect: connection refused"}
2026-08-26T08:33:35.054Z INFO shutdown-manager envoy/shutdown_manager.go:154 drain sequence timeout exceeded
2026-08-26T08:33:35.067Z INFO shutdown-manager envoy/shutdown_manager.go:67 received terminated
```
The pod config:
```
apiVersion: v1
kind: Pod
metadata:
annotations:
prometheus.io/path: /stats/prometheus
prometheus.io/port: "19001"
prometheus.io/scrape: "true"
creationTimestamp: "2026-08-26T06:41:44Z"
generateName: envoy-eg2-eg-9ad474f3-6b5f78968-
labels:
app.kubernetes.io/component: proxy
app.kubernetes.io/managed-by: envoy-gateway
app.kubernetes.io/name: envoy
gateway.envoyproxy.io/owning-gateway-name: eg
gateway.envoyproxy.io/owning-gateway-namespace: eg2
pod-template-hash: 6b5f78968
sys.99bill.com/gateway: "true"
name: envoy-eg2-eg-9ad474f3-6b5f78968-8llpf
namespace: envoy-gateway-system
ownerReferences:
- apiVersion: apps/v1
blockOwnerDeletion: true
controller: true
kind: ReplicaSet
name: envoy-eg2-eg-9ad474f3-6b5f78968
uid: 2292b123-5d4a-472e-8445-b9e2ae6bb7e2
resourceVersion: "1873502543"
uid: a0161b2e-8aea-4080-9702-a232652f7c13
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/gateway
operator: In
values:
- "true"
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- podAffinityTerm:
labelSelector:
matchExpressions:
- key: app.kubernetes.io/component
operator: In
values:
- proxy
topologyKey: kubernetes.io/hostname
weight: 100
automountServiceAccountToken: false
containers:
- args:
- --service-cluster
- eg2/eg
- --service-node
- $(ENVOY_POD_NAME)
- --config-yaml
- |
admin:
access_log:
- name: envoy.access_loggers.file
typed_config:
"@type": type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog
path: /dev/null
address:
socket_address:
address: 127.0.0.1
port_value: 19000
cluster_manager:
local_cluster_name: eg2/eg
node:
locality:
zone: $(ENVOY_SERVICE_ZONE)
stats_config:
use_all_default_tags: true
stats_tags:
- regex: \.zone(\.(([^\.]+)\.))
tag_name: from_zone
- regex: \.zone\.[^\.]+\.(([^\.]+)\.)
tag_name: to_zone
- regex: "^cluster(\\..+\\.(.+))\\.total_match_count$"
tag_name: socket_match_name
- regex: "circuit_breakers\\.((.+?)\\.).+"
tag_name: priority
layered_runtime:
layers:
- name: global_config
static_layer:
envoy.restart_features.use_eds_cache_for_ads: true
re2.max_program_size.error_level: 4294967295
re2.max_program_size.warn_level: 1000
dynamic_resources:
ads_config:
api_type: DELTA_GRPC
transport_api_version: V3
grpc_services:
- envoy_grpc:
cluster_name: xds_cluster
set_node_on_first_message_only: true
lds_config:
ads: {}
initial_fetch_timeout: 0s
resource_api_version: V3
cds_config:
ads: {}
initial_fetch_timeout: 0s
resource_api_version: V3
static_resources:
listeners:
- name: envoy-gateway-proxy-stats-0.0.0.0-19001
address:
socket_address:
address: '0.0.0.0'
port_value: 19001
protocol: TCP
bypass_overload_manager: true
filter_chains:
- filters:
- name: envoy.filters.network.http_connection_manager
typed_config:
"@type": type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager
stat_prefix: eg-stats-http
normalize_path: true
route_config:
name: local_route
virtual_hosts:
- name: prometheus_stats
domains:
- "*"
routes:
- match:
path: /stats/prometheus
headers:
- name: ":method"
string_match:
exact: GET
route:
cluster: prometheus_stats
http_filters:
- name: envoy.filters.http.router
typed_config:
"@type": type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
clusters:
- name: prometheus_stats
connect_timeout: 0.250s
type: STATIC
lb_policy: ROUND_ROBIN
load_assignment:
cluster_name: prometheus_stats
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: 127.0.0.1
port_value: 19000
- connect_timeout: 10s
eds_cluster_config:
eds_config:
ads: {}
resource_api_version: 'V3'
service_name: eg2/eg
load_balancing_policy:
policies:
- typed_extension_config:
name: 'envoy.load_balancing_policies.least_request'
typed_config:
'@type': 'type.googleapis.com/envoy.extensions.load_balancing_policies.least_request.v3.LeastRequest'
locality_lb_config:
zone_aware_lb_config:
min_cluster_size: '1'
name: eg2/eg
type: EDS
- connect_timeout: 10s
load_assignment:
cluster_name: xds_cluster
endpoints:
- load_balancing_weight: 1
lb_endpoints:
- load_balancing_weight: 1
endpoint:
address:
socket_address:
address: envoy-gateway.envoy-gateway-system.svc.cluster.local.
port_value: 18000
typed_extension_protocol_options:
envoy.extensions.upstreams.http.v3.HttpProtocolOptions:
"@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions"
explicit_http_config:
http2_protocol_options:
connection_keepalive:
interval: 30s
timeout: 5s
name: xds_cluster
type: STRICT_DNS
transport_socket:
name: envoy.transport_sockets.tls
typed_config:
"@type": type.googleapis.com/envoy.extensions.transport_sockets.tls.v3.UpstreamTlsContext
common_tls_context:
tls_params:
tls_maximum_protocol_version: TLSv1_3
tls_certificate_sds_secret_configs:
- name: xds_certificate
sds_config:
path_config_source:
path: /sds/xds-certificate.json
resource_api_version: V3
validation_context_sds_secret_config:
name: xds_trusted_ca
sds_config:
path_config_source:
path: /sds/xds-trusted-ca.json
resource_api_version: V3
overload_manager:
refresh_interval: 0.25s
resource_monitors:
- name: "envoy.resource_monitors.global_downstream_max_connections"
typed_config:
"@type": type.googleapis.com/envoy.extensions.resource_monitors.downstream_connections.v3.DownstreamConnectionsConfig
max_active_downstream_connections: 50000
- name: "envoy.resource_monitors.fixed_heap"
typed_config:
"@type": type.googleapis.com/envoy.extensions.resource_monitors.fixed_heap.v3.FixedHeapConfig
max_heap_size_bytes: 3435973836
actions:
- name: "envoy.overload_actions.shrink_heap"
triggers:
- name: "envoy.resource_monitors.fixed_heap"
threshold:
value: 0.95
- name: "envoy.overload_actions.stop_accepting_requests"
triggers:
- name: "envoy.resource_monitors.fixed_heap"
threshold:
value: 0.98
- --log-level
- warn
- --cpuset-threads
- --drain-strategy
- immediate
- --component-log-level
- misc:error
- --drain-time-s
- "60"
command:
- envoy
env:
- name: ENVOY_POD_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
- name: ENVOY_POD_NAME
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.name
- name: ENVOY_SERVICE_ZONE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.annotations['topology.kubernetes.io/zone']
image: regdev.99bill.com/hci/envoyproxy/envoy:v1.35.3
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
httpGet:
path: /shutdown/ready
port: 19002
scheme: HTTP
livenessProbe:
failureThreshold: 3
httpGet:
path: /ready
port: 19003
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
name: envoy
ports:
- containerPort: 19001
hostPort: 19001
name: metrics
protocol: TCP
- containerPort: 19003
hostPort: 19003
name: readiness
protocol: TCP
readinessProbe:
failureThreshold: 1
httpGet:
path: /ready
port: 19003
scheme: HTTP
periodSeconds: 5
successThreshold: 1
timeoutSeconds: 1
resources:
limits:
cpu: "2"
memory: 4Gi
requests:
cpu: 150m
memory: 640Mi
securityContext:
allowPrivilegeEscalation: true
capabilities:
add:
- NET_BIND_SERVICE
drop:
- ALL
seccompProfile:
type: RuntimeDefault
startupProbe:
failureThreshold: 30
httpGet:
path: /ready
port: 19003
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /certs
name: certs
readOnly: true
- mountPath: /sds
name: sds
- mountPath: /var/log/envoy
name: log
subPathExpr: $(ENVOY_POD_NAME)
- args:
- envoy
- shutdown-manager
command:
- envoy-gateway
env:
- name: ENVOY_POD_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
- name: ENVOY_POD_NAME
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.name
- name: ENVOY_SERVICE_ZONE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.annotations['topology.kubernetes.io/zone']
image: regdev.99bill.com/hci/envoyproxy/gateway:v1.7.1
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
exec:
command:
- envoy-gateway
- envoy
- shutdown
livenessProbe:
failureThreshold: 3
httpGet:
path: /healthz
port: 19002
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
name: shutdown-manager
readinessProbe:
failureThreshold: 3
httpGet:
path: /healthz
port: 19002
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
resources:
requests:
cpu: 10m
memory: 32Mi
securityContext:
allowPrivilegeEscalation: true
capabilities:
add:
- NET_BIND_SERVICE
drop:
- ALL
seccompProfile:
type: RuntimeDefault
startupProbe:
failureThreshold: 30
httpGet:
path: /healthz
port: 19002
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirstWithHostNet
enableServiceLinks: true
hostNetwork: true
nodeName: hci050.99bill.com
preemptionPolicy: PreemptLowerPriority
priority: 0
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
serviceAccount: envoy-eg2-eg-9ad474f3
serviceAccountName: envoy-eg2-eg-9ad474f3
terminationGracePeriodSeconds: 360
tolerations:
- effect: NoExecute
key: node.kubernetes.io/not-ready
operator: Exists
tolerationSeconds: 300
- effect: NoExecute
key: node.kubernetes.io/unreachable
operator: Exists
tolerationSeconds: 300
volumes:
- name: certs
secret:
defaultMode: 420
secretName: envoy
- configMap:
defaultMode: 420
items:
- key: xds-trusted-ca.json
path: xds-trusted-ca.json
- key: xds-certificate.json
path: xds-certificate.json
name: envoy-eg2-eg-9ad474f3
optional: false
name: sds
- hostPath:
path: /opt/log
type: ""
name: log
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with envoy/shutdown_manager.go, especially the startup and drain logic around lines 77 and 130-149, and inspect how it reaches Envoy on localhost:19000 during hostNetwork termination. Reproduce the failure with a hostNetwork deployment and compare it with the working non-hostNetwork case. Done means shutdown-manager can complete its drain without connection-refused errors in hostNetwork mode.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- backend, networking
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100