Created
March 29, 2024 22:44
-
-
Save gbrayut/eb3b67a44c99ce0dd5f78db8548b856a to your computer and use it in GitHub Desktop.
KCC GKE cgroupMode Testing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: compute.cnrm.cloud.google.com/v1beta1 | |
kind: ComputeNetwork | |
metadata: | |
annotations: | |
cnrm.cloud.google.com/management-conflict-prevention-policy: "none" | |
cnrm.cloud.google.com/deletion-policy: "abandon" | |
name: default | |
spec: | |
description: Default network for the project | |
--- | |
apiVersion: container.cnrm.cloud.google.com/v1beta1 | |
kind: ContainerCluster | |
metadata: | |
#annotations: | |
# cnrm.cloud.google.com/management-conflict-prevention-policy: "none" | |
# cnrm.cloud.google.com/deletion-policy: "abandon" | |
labels: | |
label-one: "value-one" | |
name: cluster-sample-cgroup-123 | |
spec: | |
location: us-central1-a | |
initialNodeCount: 1 | |
networkRef: | |
name: default | |
subnetworkRef: | |
external: projects/gregbray-kcc/regions/us-central1/subnetworks/default | |
ipAllocationPolicy: | |
clusterIpv4CidrBlock: /20 | |
servicesIpv4CidrBlock: /20 | |
monitoringConfig: | |
managedPrometheus: | |
enabled: false | |
clusterAutoscaling: | |
enabled: true | |
autoscalingProfile: BALANCED | |
resourceLimits: | |
- resourceType: cpu | |
maximum: 100 | |
minimum: 10 | |
- resourceType: memory | |
maximum: 1000 | |
minimum: 100 | |
nodeConfig: | |
linuxNodeConfig: | |
sysctls: | |
net.core.somaxconn: "4095" | |
cgroupMode: "CGROUP_MODE_V1" | |
--- | |
apiVersion: container.cnrm.cloud.google.com/v1beta1 | |
kind: ContainerNodePool | |
metadata: | |
name: nodepool-none | |
spec: | |
initialNodeCount: 1 | |
location: us-central1-a | |
autoscaling: | |
minNodeCount: 1 | |
maxNodeCount: 3 | |
clusterRef: | |
name: cluster-sample-cgroup-123 | |
nodeConfig: | |
linuxNodeConfig: | |
sysctls: | |
net.core.somaxconn: "4095" | |
cgroupMode: "CGROUP_MODE_V1" | |
--- | |
apiVersion: container.cnrm.cloud.google.com/v1beta1 | |
kind: ContainerNodePool | |
metadata: | |
name: nodepool-both | |
spec: | |
initialNodeCount: 1 | |
location: us-central1-a | |
autoscaling: | |
minNodeCount: 1 | |
maxNodeCount: 3 | |
clusterRef: | |
name: cluster-sample-cgroup-123 | |
nodeConfig: | |
linuxNodeConfig: | |
sysctls: | |
net.core.somaxconn: "4095" | |
cgroupMode: "CGROUP_MODE_V2" | |
--- | |
apiVersion: container.cnrm.cloud.google.com/v1beta1 | |
kind: ContainerNodePool | |
metadata: | |
name: nodepool-sysctl | |
spec: | |
initialNodeCount: 1 | |
location: us-central1-a | |
autoscaling: | |
minNodeCount: 1 | |
maxNodeCount: 3 | |
clusterRef: | |
name: cluster-sample-cgroup-123 | |
nodeConfig: | |
linuxNodeConfig: | |
sysctls: | |
net.core.somaxconn: "4095" | |
--- | |
apiVersion: container.cnrm.cloud.google.com/v1beta1 | |
kind: ContainerNodePool | |
metadata: | |
name: nodepool-cgroup | |
spec: | |
initialNodeCount: 1 | |
location: us-central1-a | |
autoscaling: | |
minNodeCount: 1 | |
maxNodeCount: 3 | |
clusterRef: | |
name: cluster-sample-cgroup-123 | |
nodeConfig: | |
linuxNodeConfig: | |
cgroupMode: "CGROUP_MODE_UNSPECIFIED" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Test data for GoogleCloudPlatform/k8s-config-connector#1463
Verify changes on nodes using:
stat -fc %T /sys/fs/cgroup/; cat /proc/sys/net/core/somaxconn
where tmpfs = cgroupv1