Skip to content

Instantly share code, notes, and snippets.

@juusujanar
Created January 20, 2021 14:48
Show Gist options
  • Save juusujanar/a9b9918a4d6d0dc5e101b0b191ec0a00 to your computer and use it in GitHub Desktop.
Save juusujanar/a9b9918a4d6d0dc5e101b0b191ec0a00 to your computer and use it in GitHub Desktop.
apiVersion: v1
data:
Corefile: |
.:53 {
errors
health {
lameduck 5s
}
ready
kubernetes cluster.local in-addr.arpa ip6.arpa {
pods insecure
fallthrough in-addr.arpa ip6.arpa
ttl 30
}
prometheus :9153
forward . /etc/resolv.conf {
max_concurrent 1000
}
cache 30
loop
reload
loadbalance
}
kind: ConfigMap
metadata:
creationTimestamp: "2021-01-20T14:34:45Z"
managedFields:
- apiVersion: v1
fieldsType: FieldsV1
fieldsV1:
f:data:
.: {}
f:Corefile: {}
manager: kubeadm
operation: Update
time: "2021-01-20T14:34:45Z"
name: coredns
namespace: kube-system
resourceVersion: "219"
selfLink: /api/v1/namespaces/kube-system/configmaps/coredns
uid: 30d62089-a156-414f-afe2-84fbdc63d860
nameserver 127.0.0.1
nameserver 2001:4860:4860::8888
nameserver 2001:4860:4860::8844
options edns0 trust-ad ndots:0
{
"status": {
"id": "cade1c4452bad908d4bba9b5173bdf74bef9cb98785923922f31916c822ab277",
"metadata": {
"attempt": 4,
"name": "coredns"
},
"state": "CONTAINER_EXITED",
"createdAt": "2021-01-20T14:44:38.550001372Z",
"startedAt": "2021-01-20T14:44:38.762989101Z",
"finishedAt": "2021-01-20T14:44:39.897532957Z",
"exitCode": 1,
"image": {
"image": "k8s.gcr.io/coredns:1.7.0"
},
"imageRef": "sha256:bfe3a36ebd2528b454be6aebece806db5b40407b833e2af9617bf39afaff8c16",
"reason": "Error",
"message": "",
"labels": {
"io.kubernetes.container.name": "coredns",
"io.kubernetes.pod.name": "coredns-f9fd979d6-6qtgp",
"io.kubernetes.pod.namespace": "kube-system",
"io.kubernetes.pod.uid": "5bdbf126-aa6f-41fc-bc8c-702251c1e80f"
},
"annotations": {
"io.kubernetes.container.hash": "8e0f1281",
"io.kubernetes.container.ports": "[{\"name\":\"dns\",\"containerPort\":53,\"protocol\":\"UDP\"},{\"name\":\"dns-tcp\",\"containerPort\":53,\"protocol\":\"TCP\"},{\"name\":\"metrics\",\"containerPort\":9153,\"protocol\":\"TCP\"}]",
"io.kubernetes.container.restartCount": "4",
"io.kubernetes.container.terminationMessagePath": "/dev/termination-log",
"io.kubernetes.container.terminationMessagePolicy": "File",
"io.kubernetes.pod.terminationGracePeriod": "30"
},
"mounts": [
{
"containerPath": "/etc/coredns",
"hostPath": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~configmap/config-volume",
"propagation": "PROPAGATION_PRIVATE",
"readonly": true,
"selinuxRelabel": false
},
{
"containerPath": "/var/run/secrets/kubernetes.io/serviceaccount",
"hostPath": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~secret/coredns-token-vb8z9",
"propagation": "PROPAGATION_PRIVATE",
"readonly": true,
"selinuxRelabel": false
},
{
"containerPath": "/etc/hosts",
"hostPath": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/etc-hosts",
"propagation": "PROPAGATION_PRIVATE",
"readonly": false,
"selinuxRelabel": false
},
{
"containerPath": "/dev/termination-log",
"hostPath": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/containers/coredns/f1ae5dd5",
"propagation": "PROPAGATION_PRIVATE",
"readonly": false,
"selinuxRelabel": false
}
],
"logPath": "/var/log/pods/kube-system_coredns-f9fd979d6-6qtgp_5bdbf126-aa6f-41fc-bc8c-702251c1e80f/coredns/4.log"
},
"info": {
"sandboxID": "f84fed8055da1c56eb35274e4379fdc922d942996c33d6f94960c2a834489e45",
"pid": 0,
"removing": false,
"snapshotKey": "cade1c4452bad908d4bba9b5173bdf74bef9cb98785923922f31916c822ab277",
"snapshotter": "overlayfs",
"runtimeType": "io.containerd.runc.v2",
"runtimeOptions": null,
"config": {
"metadata": {
"name": "coredns",
"attempt": 4
},
"image": {
"image": "sha256:bfe3a36ebd2528b454be6aebece806db5b40407b833e2af9617bf39afaff8c16"
},
"args": [
"-conf",
"/etc/coredns/Corefile"
],
"envs": [
{
"key": "KUBE_DNS_SERVICE_HOST",
"value": "10.96.0.10"
},
{
"key": "KUBE_DNS_SERVICE_PORT_DNS",
"value": "53"
},
{
"key": "KUBE_DNS_PORT",
"value": "udp://10.96.0.10:53"
},
{
"key": "KUBE_DNS_PORT_9153_TCP_PORT",
"value": "9153"
},
{
"key": "KUBERNETES_SERVICE_PORT",
"value": "443"
},
{
"key": "KUBERNETES_PORT_443_TCP_PORT",
"value": "443"
},
{
"key": "KUBERNETES_PORT_443_TCP",
"value": "tcp://10.96.0.1:443"
},
{
"key": "KUBE_DNS_PORT_53_UDP_PROTO",
"value": "udp"
},
{
"key": "KUBE_DNS_PORT_53_UDP_PORT",
"value": "53"
},
{
"key": "KUBE_DNS_PORT_9153_TCP_PROTO",
"value": "tcp"
},
{
"key": "KUBERNETES_SERVICE_PORT_HTTPS",
"value": "443"
},
{
"key": "KUBERNETES_PORT",
"value": "tcp://10.96.0.1:443"
},
{
"key": "KUBERNETES_PORT_443_TCP_ADDR",
"value": "10.96.0.1"
},
{
"key": "KUBE_DNS_SERVICE_PORT",
"value": "53"
},
{
"key": "KUBE_DNS_SERVICE_PORT_DNS_TCP",
"value": "53"
},
{
"key": "KUBE_DNS_SERVICE_PORT_METRICS",
"value": "9153"
},
{
"key": "KUBE_DNS_PORT_53_TCP_PROTO",
"value": "tcp"
},
{
"key": "KUBE_DNS_PORT_53_TCP_PORT",
"value": "53"
},
{
"key": "KUBERNETES_SERVICE_HOST",
"value": "10.96.0.1"
},
{
"key": "KUBERNETES_PORT_443_TCP_PROTO",
"value": "tcp"
},
{
"key": "KUBE_DNS_PORT_53_TCP",
"value": "tcp://10.96.0.10:53"
},
{
"key": "KUBE_DNS_PORT_53_TCP_ADDR",
"value": "10.96.0.10"
},
{
"key": "KUBE_DNS_PORT_9153_TCP",
"value": "tcp://10.96.0.10:9153"
},
{
"key": "KUBE_DNS_PORT_9153_TCP_ADDR",
"value": "10.96.0.10"
},
{
"key": "KUBE_DNS_PORT_53_UDP",
"value": "udp://10.96.0.10:53"
},
{
"key": "KUBE_DNS_PORT_53_UDP_ADDR",
"value": "10.96.0.10"
}
],
"mounts": [
{
"container_path": "/etc/coredns",
"host_path": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~configmap/config-volume",
"readonly": true
},
{
"container_path": "/var/run/secrets/kubernetes.io/serviceaccount",
"host_path": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~secret/coredns-token-vb8z9",
"readonly": true
},
{
"container_path": "/etc/hosts",
"host_path": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/etc-hosts"
},
{
"container_path": "/dev/termination-log",
"host_path": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/containers/coredns/f1ae5dd5"
}
],
"labels": {
"io.kubernetes.container.name": "coredns",
"io.kubernetes.pod.name": "coredns-f9fd979d6-6qtgp",
"io.kubernetes.pod.namespace": "kube-system",
"io.kubernetes.pod.uid": "5bdbf126-aa6f-41fc-bc8c-702251c1e80f"
},
"annotations": {
"io.kubernetes.container.hash": "8e0f1281",
"io.kubernetes.container.ports": "[{\"name\":\"dns\",\"containerPort\":53,\"protocol\":\"UDP\"},{\"name\":\"dns-tcp\",\"containerPort\":53,\"protocol\":\"TCP\"},{\"name\":\"metrics\",\"containerPort\":9153,\"protocol\":\"TCP\"}]",
"io.kubernetes.container.restartCount": "4",
"io.kubernetes.container.terminationMessagePath": "/dev/termination-log",
"io.kubernetes.container.terminationMessagePolicy": "File",
"io.kubernetes.pod.terminationGracePeriod": "30"
},
"log_path": "coredns/4.log",
"linux": {
"resources": {
"cpu_period": 100000,
"cpu_shares": 102,
"memory_limit_in_bytes": 178257920,
"oom_score_adj": -998,
"hugepage_limits": [
{
"page_size": "1GB"
},
{
"page_size": "2MB"
}
]
},
"security_context": {
"capabilities": {
"add_capabilities": [
"NET_BIND_SERVICE"
],
"drop_capabilities": [
"all"
]
},
"namespace_options": {
"pid": 1
},
"run_as_user": {},
"readonly_rootfs": true,
"no_new_privs": true,
"masked_paths": [
"/proc/acpi",
"/proc/kcore",
"/proc/keys",
"/proc/latency_stats",
"/proc/timer_list",
"/proc/timer_stats",
"/proc/sched_debug",
"/proc/scsi",
"/sys/firmware"
],
"readonly_paths": [
"/proc/asound",
"/proc/bus",
"/proc/fs",
"/proc/irq",
"/proc/sys",
"/proc/sysrq-trigger"
]
}
}
},
"runtimeSpec": {
"ociVersion": "1.0.2-dev",
"process": {
"user": {
"uid": 0,
"gid": 0
},
"args": [
"/coredns",
"-conf",
"/etc/coredns/Corefile"
],
"env": [
"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
"HOSTNAME=coredns-f9fd979d6-6qtgp",
"KUBE_DNS_SERVICE_HOST=10.96.0.10",
"KUBE_DNS_SERVICE_PORT_DNS=53",
"KUBE_DNS_PORT=udp://10.96.0.10:53",
"KUBE_DNS_PORT_9153_TCP_PORT=9153",
"KUBERNETES_SERVICE_PORT=443",
"KUBERNETES_PORT_443_TCP_PORT=443",
"KUBERNETES_PORT_443_TCP=tcp://10.96.0.1:443",
"KUBE_DNS_PORT_53_UDP_PROTO=udp",
"KUBE_DNS_PORT_53_UDP_PORT=53",
"KUBE_DNS_PORT_9153_TCP_PROTO=tcp",
"KUBERNETES_SERVICE_PORT_HTTPS=443",
"KUBERNETES_PORT=tcp://10.96.0.1:443",
"KUBERNETES_PORT_443_TCP_ADDR=10.96.0.1",
"KUBE_DNS_SERVICE_PORT=53",
"KUBE_DNS_SERVICE_PORT_DNS_TCP=53",
"KUBE_DNS_SERVICE_PORT_METRICS=9153",
"KUBE_DNS_PORT_53_TCP_PROTO=tcp",
"KUBE_DNS_PORT_53_TCP_PORT=53",
"KUBERNETES_SERVICE_HOST=10.96.0.1",
"KUBERNETES_PORT_443_TCP_PROTO=tcp",
"KUBE_DNS_PORT_53_TCP=tcp://10.96.0.10:53",
"KUBE_DNS_PORT_53_TCP_ADDR=10.96.0.10",
"KUBE_DNS_PORT_9153_TCP=tcp://10.96.0.10:9153",
"KUBE_DNS_PORT_9153_TCP_ADDR=10.96.0.10",
"KUBE_DNS_PORT_53_UDP=udp://10.96.0.10:53",
"KUBE_DNS_PORT_53_UDP_ADDR=10.96.0.10"
],
"cwd": "/",
"capabilities": {
"bounding": [
"CAP_NET_BIND_SERVICE"
],
"effective": [
"CAP_NET_BIND_SERVICE"
],
"inheritable": [
"CAP_NET_BIND_SERVICE"
],
"permitted": [
"CAP_NET_BIND_SERVICE"
]
},
"noNewPrivileges": true,
"oomScoreAdj": -998
},
"root": {
"path": "rootfs",
"readonly": true
},
"mounts": [
{
"destination": "/proc",
"type": "proc",
"source": "proc",
"options": [
"nosuid",
"noexec",
"nodev"
]
},
{
"destination": "/dev",
"type": "tmpfs",
"source": "tmpfs",
"options": [
"nosuid",
"strictatime",
"mode=755",
"size=65536k"
]
},
{
"destination": "/dev/pts",
"type": "devpts",
"source": "devpts",
"options": [
"nosuid",
"noexec",
"newinstance",
"ptmxmode=0666",
"mode=0620",
"gid=5"
]
},
{
"destination": "/dev/mqueue",
"type": "mqueue",
"source": "mqueue",
"options": [
"nosuid",
"noexec",
"nodev"
]
},
{
"destination": "/sys",
"type": "sysfs",
"source": "sysfs",
"options": [
"nosuid",
"noexec",
"nodev",
"ro"
]
},
{
"destination": "/sys/fs/cgroup",
"type": "cgroup",
"source": "cgroup",
"options": [
"nosuid",
"noexec",
"nodev",
"relatime",
"ro"
]
},
{
"destination": "/etc/coredns",
"type": "bind",
"source": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~configmap/config-volume",
"options": [
"rbind",
"rprivate",
"ro"
]
},
{
"destination": "/etc/hosts",
"type": "bind",
"source": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/etc-hosts",
"options": [
"rbind",
"rprivate",
"rw"
]
},
{
"destination": "/dev/termination-log",
"type": "bind",
"source": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/containers/coredns/f1ae5dd5",
"options": [
"rbind",
"rprivate",
"rw"
]
},
{
"destination": "/etc/hostname",
"type": "bind",
"source": "/var/lib/containerd/io.containerd.grpc.v1.cri/sandboxes/f84fed8055da1c56eb35274e4379fdc922d942996c33d6f94960c2a834489e45/hostname",
"options": [
"rbind",
"rprivate",
"ro"
]
},
{
"destination": "/etc/resolv.conf",
"type": "bind",
"source": "/var/lib/containerd/io.containerd.grpc.v1.cri/sandboxes/f84fed8055da1c56eb35274e4379fdc922d942996c33d6f94960c2a834489e45/resolv.conf",
"options": [
"rbind",
"rprivate",
"ro"
]
},
{
"destination": "/dev/shm",
"type": "bind",
"source": "/run/containerd/io.containerd.grpc.v1.cri/sandboxes/f84fed8055da1c56eb35274e4379fdc922d942996c33d6f94960c2a834489e45/shm",
"options": [
"rbind",
"rprivate",
"rw"
]
},
{
"destination": "/var/run/secrets/kubernetes.io/serviceaccount",
"type": "bind",
"source": "/var/lib/kubelet/pods/5bdbf126-aa6f-41fc-bc8c-702251c1e80f/volumes/kubernetes.io~secret/coredns-token-vb8z9",
"options": [
"rbind",
"rprivate",
"ro"
]
}
],
"annotations": {
"io.kubernetes.cri.container-name": "coredns",
"io.kubernetes.cri.container-type": "container",
"io.kubernetes.cri.sandbox-id": "f84fed8055da1c56eb35274e4379fdc922d942996c33d6f94960c2a834489e45"
},
"linux": {
"resources": {
"devices": [
{
"allow": false,
"access": "rwm"
}
],
"memory": {
"limit": 178257920
},
"cpu": {
"shares": 102,
"period": 100000
}
},
"cgroupsPath": "/kubepods/burstable/pod5bdbf126-aa6f-41fc-bc8c-702251c1e80f/cade1c4452bad908d4bba9b5173bdf74bef9cb98785923922f31916c822ab277",
"namespaces": [
{
"type": "pid"
},
{
"type": "ipc",
"path": "/proc/1141/ns/ipc"
},
{
"type": "uts",
"path": "/proc/1141/ns/uts"
},
{
"type": "mount"
},
{
"type": "network",
"path": "/proc/1141/ns/net"
},
{
"type": "cgroup"
}
],
"maskedPaths": [
"/proc/acpi",
"/proc/kcore",
"/proc/keys",
"/proc/latency_stats",
"/proc/timer_list",
"/proc/timer_stats",
"/proc/sched_debug",
"/proc/scsi",
"/sys/firmware"
],
"readonlyPaths": [
"/proc/asound",
"/proc/bus",
"/proc/fs",
"/proc/irq",
"/proc/sys",
"/proc/sysrq-trigger"
]
}
}
}
}
Client:
Context: default
Debug Mode: false
Plugins:
app: Docker App (Docker Inc., v0.9.1-beta3)
buildx: Build with BuildKit (Docker Inc., v0.5.1-docker)
Server:
Containers: 6
Running: 2
Paused: 0
Stopped: 4
Images: 31
Server Version: 20.10.2
Storage Driver: btrfs
Build Version: Btrfs v5.9
Library Version: 102
Logging Driver: json-file
Cgroup Driver: systemd
Cgroup Version: 2
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 269548fa27e0089a8b8278fc4fc781d7f65a939b
runc version: ff819c7e9184c13b7c2607fe6c30ae19403a7aff
init version: de40ad0
Security Options:
seccomp
Profile: default
cgroupns
Kernel Version: 5.10.7-200.fc33.x86_64
Operating System: Fedora 33 (Workstation Edition)
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.26GiB
Name: plastic
ID: I3MV:W343:VYVH:7443:4BVL:TIDQ:B7CR:CWYA:W32Q:X4O6:52PN:YVTJ
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
WARNING: No kernel memory TCP limit support
WARNING: No oom kill disable support
WARNING: Support for cgroup v2 is experimental
# This file is managed by man:systemd-resolved(8). Do not edit.
#
# This is a dynamic resolv.conf file for connecting local clients to the
# internal DNS stub resolver of systemd-resolved. This file lists all
# configured search domains.
#
# Run "resolvectl status" to see details about the uplink DNS servers
# currently in use.
#
# Third party programs should typically not access this file directly, but only
# through the symlink at /etc/resolv.conf. To manage man:resolv.conf(5) in a
# different way, replace this symlink by a static file or a different symlink.
#
# See man:systemd-resolved.service(8) for details about the supported modes of
# operation for /etc/resolv.conf.
nameserver 127.0.0.53
options edns0 trust-ad
[
{
"Name": "kind",
"Id": "bdd7e68c63d99b1f0357c2f86e3db5e21abbd39246e2e4766d083ce7ee3257b5",
"Created": "2021-01-20T13:59:53.853702449+02:00",
"Scope": "local",
"Driver": "bridge",
"EnableIPv6": true,
"IPAM": {
"Driver": "default",
"Options": {},
"Config": [
{
"Subnet": "172.18.0.0/16",
"Gateway": "172.18.0.1"
},
{
"Subnet": "fc00:f853:ccd:e793::/64",
"Gateway": "fc00:f853:ccd:e793::1"
}
]
},
"Internal": false,
"Attachable": false,
"Ingress": false,
"ConfigFrom": {
"Network": ""
},
"ConfigOnly": false,
"Containers": {
"63ba80dfc6973eb68d046a89c68be0d81725619cc5a1c8bddffc20897367c2b0": {
"Name": "registry",
"EndpointID": "b9e6995b13e4ffe4aaaede7fc7b92170e7742548d4488d1ed19a3d0b49875ad4",
"MacAddress": "02:42:ac:12:00:03",
"IPv4Address": "172.18.0.3/16",
"IPv6Address": "fc00:f853:ccd:e793::3/64"
},
"f38ca53711aeef82b812a2ab98fa5c6581633102818d82d656ba4b1db3a7c1ff": {
"Name": "test-control-plane",
"EndpointID": "06ea23e393e0ff556668625466df79892a6fb4ca48b61a945eb35742a9899529",
"MacAddress": "02:42:ac:12:00:02",
"IPv4Address": "172.18.0.2/16",
"IPv6Address": "fc00:f853:ccd:e793::2/64"
}
},
"Options": {
"com.docker.network.bridge.enable_ip_masquerade": "true"
},
"Labels": {}
}
]
.:53
[INFO] plugin/reload: Running configuration MD5 = db32ca3650231d74073ff4cf814959a7
CoreDNS-1.7.0
linux/amd64, go1.14.4, f59c03d
[FATAL] plugin/loop: Loop (127.0.0.1:53003 -> :53) detected for zone ".", see https://coredns.io/plugins/loop#troubleshooting. Query: "HINFO 1548797846507714410.3858146172311417690."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment