Skip to content

Instantly share code, notes, and snippets.

@hasbro17
hasbro17 / get-pod.yaml
Created April 21, 2017 18:25
Pod termination with grace period
11:00:17
apiVersion: v1
kind: Pod
metadata:
creationTimestamp: 2017-04-21T18:00:05Z
labels:
app: nginx
name: nginx
namespace: htariq
resourceVersion: "264246"
@hasbro17
hasbro17 / etcd-operator.log
Created April 26, 2017 21:57
More readable etcd operator logs for the issue https://github.com/coreos/etcd-operator/issues/1008
time="2017-04-26T21:37:37Z" level=info msg="etcd-operator Version: 0.2.5"
time="2017-04-26T21:37:37Z" level=info msg="Git SHA: e6c62c0"
time="2017-04-26T21:37:37Z" level=info msg="Go Version: go1.7.5"
time="2017-04-26T21:37:37Z" level=info msg="Go OS/Arch: linux/amd64"
time="2017-04-26T21:37:55Z" level=info msg="finding existing clusters..." pkg=controller
time="2017-04-26T21:37:55Z" level=info msg="starts running from watch version: 181503" pkg=controller
time="2017-04-26T21:37:55Z" level=info msg="start watching at 181503" pkg=controller
time="2017-04-26T21:38:08Z" level=info msg="creating cluster with Spec (spec.ClusterSpec{Size:3, Version:\"3.1.5\", Paused:false, Pod:(*spec.PodPolicy)(nil), Backup:(*spec.BackupPolicy)(0xc420223a80), Restore:(*spec.RestorePolicy)(nil), SelfHosted:(*spec.SelfHostedPolicy)(nil), TLS:(*spec.TLSPolicy)(nil)}), Status (spec.ClusterStatus{Phase:\"Creating\", Reason:\"\", ControlPaused:false, Conditions:[]spec.ClusterCondition(nil), Size:0, Members:spec.MembersStatus{Ready:[]stri
@hasbro17
hasbro17 / example-etcd-cluster-with-backup-0004.log
Created April 26, 2017 23:30
Logs of the etcd member 0004 whose health check fails first after upgrade to 3.1.6 https://github.com/coreos/etcd-operator/issues/1008
Haseebs-MacBook-Pro:etcd-operator haseeb$ kubectl -n e2e-local logs example-etcd-cluster-with-backup-0004 -f
2017-04-26 23:23:30.651048 I | etcdmain: etcd Version: 3.1.5
2017-04-26 23:23:30.651122 I | etcdmain: Git SHA: 20490ca
2017-04-26 23:23:30.651126 I | etcdmain: Go Version: go1.7.5
2017-04-26 23:23:30.651129 I | etcdmain: Go OS/Arch: linux/amd64
2017-04-26 23:23:30.651133 I | etcdmain: setting maximum number of CPUs to 2, total number of available CPUs is 2
2017-04-26 23:23:30.651202 I | embed: listening for peers on http://0.0.0.0:2380
2017-04-26 23:23:30.651232 I | embed: listening for client requests on 0.0.0.0:2379
2017-04-26 23:23:30.663504 I | pkg/netutil: resolving example-etcd-cluster-with-backup-0003.example-etcd-cluster-with-backup.e2e-local.svc.cluster.local:2380 to 10.244.2.45:2380
2017-04-26 23:23:30.663824 I | pkg/netutil: resolving example-etcd-cluster-with-backup-0003.example-etcd-cluster-with-backup.e2e-local.svc.cluster.local:2380 to 10.244.2.45:2380
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRole
metadata:
name: "etcd-operator-default"
rules:
- apiGroups:
- etcd.coreos.com
resources:
- clusters
verbs:
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
name: "etcd-operator-default"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: "etcd-operator-default"
subjects:
- kind: ServiceAccount
apiVersion: "etcd.coreos.com/v1beta1"
kind: "Cluster"
metadata:
name: "etcd-cluster-with-backup-s3"
namespace: "default"
spec:
size: 3
version: "3.1.4"
backup:
backupIntervalInSecond: 60
{
"version": "1.6.4-tectonic.1",
"deployments": [
{
"apiVersion": "extensions/v1beta1",
"kind": "Deployment",
"metadata": {
"labels": {
"k8s-app": "tectonic-channel-operator",
"managed-by-channel-operator": "true"
Starting audit logs for self-hosted etcd cluster: example-etcd-cluster"
time="2017-06-28T20:20:04Z" level=info msg="created pod (example-etcd-cluster-0000) with spec: {
"volumes": [
{
"name": "etcd-data",
"emptyDir": {}
}
],
"containers": [
{
time="2017-07-11T18:45:24Z" level=info msg="Starting debug logs for self-hosted etcd cluster: kube-etcd"
time="2017-07-11T18:45:35Z" level=info msg="created pod (kube-etcd-0000)"
########## Operator restarted for some reason ##########
time="2017-07-11T18:47:56Z" level=info msg="Starting debug logs for self-hosted etcd cluster: kube-etcd"
time="2017-07-11T18:55:04Z" level=info msg="spec update:
Old:
{
"size": 1,
time="2017-07-12T17:36:14Z" level=info msg="Starting debug logs for self-hosted etcd cluster: kube-etcd"
time="2017-07-12T17:36:24Z" level=info msg="created pod (kube-etcd-0000) with spec: {
"volumes": [
{
"name": "etcd-data",
"hostPath": {
"path": "/var/etcd"
}
},
{