Bug 1643191
| Summary: | statefulset cannot create pods: failed error: Pod "ip-172-31-47-15.us-west-2.compute.internal-0" is invalid: spec.hostname | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Hongkai Liu <hongkliu> |
| Component: | kube-controller-manager | Assignee: | Tomáš Nožička <tnozicka> |
| Status: | CLOSED INSUFFICIENT_DATA | QA Contact: | Xingxing Xia <xxia> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 3.11.0 | CC: | aos-bugs, hongkliu, jokerman, jstrunk, maszulik, mfojtik, mifiedle, mmccomas |
| Target Milestone: | --- | ||
| Target Release: | 3.11.z | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2020-05-04 15:01:59 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Hongkai Liu
2018-10-25 17:26:36 UTC
I also tried with a pod with the same name and it is a valid pod name:
Is there something special for sts name?
# oc get pod
NAME READY STATUS RESTARTS AGE
ip-172-31-47-15.us-west-2.compute.internal-0 1/1 Running 0 35s
# oc get pod ip-172-31-47-15.us-west-2.compute.internal-0 -o yaml
apiVersion: v1
kind: Pod
metadata:
annotations:
openshift.io/scc: anyuid
creationTimestamp: 2018-10-25T17:34:21Z
labels:
app: web
name: ip-172-31-47-15.us-west-2.compute.internal-0
namespace: ttt
resourceVersion: "44900"
selfLink: /api/v1/namespaces/ttt/pods/ip-172-31-47-15.us-west-2.compute.internal-0
uid: 354295d7-d87c-11e8-844b-026633a2e2b6
spec:
containers:
- image: docker.io/nginx
imagePullPolicy: Always
name: front-end
ports:
- containerPort: 80
protocol: TCP
resources: {}
securityContext:
capabilities:
drop:
- MKNOD
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /var/run/secrets/kubernetes.io/serviceaccount
name: default-token-4fgww
readOnly: true
dnsPolicy: ClusterFirst
imagePullSecrets:
- name: default-dockercfg-rrrqt
nodeName: ip-172-31-59-125.us-west-2.compute.internal
nodeSelector:
node-role.kubernetes.io/compute: "true"
priority: 0
restartPolicy: Always
schedulerName: default-scheduler
securityContext:
seLinuxOptions:
level: s0:c21,c5
serviceAccount: default
serviceAccountName: default
terminationGracePeriodSeconds: 30
volumes:
- name: default-token-4fgww
secret:
defaultMode: 420
secretName: default-token-4fgww
status:
conditions:
- lastProbeTime: null
lastTransitionTime: 2018-10-25T17:34:21Z
status: "True"
type: Initialized
- lastProbeTime: null
lastTransitionTime: 2018-10-25T17:34:30Z
status: "True"
type: Ready
- lastProbeTime: null
lastTransitionTime: null
status: "True"
type: ContainersReady
- lastProbeTime: null
lastTransitionTime: 2018-10-25T17:34:21Z
status: "True"
type: PodScheduled
containerStatuses:
- containerID: docker://c72a553c3a1bf14135ade8c160653663d36fb3f768ae5630e1ae195fb425da6a
image: docker.io/nginx:latest
imageID: docker-pullable://docker.io/nginx@sha256:b73f527d86e3461fd652f62cf47e7b375196063bbbd503e853af5be16597cb2e
lastState: {}
name: front-end
ready: true
restartCount: 0
state:
running:
startedAt: 2018-10-25T17:34:30Z
hostIP: 172.31.59.125
phase: Running
podIP: 172.21.0.10
qosClass: BestEffort
startTime: 2018-10-25T17:34:21Z
FYI, STS pod uses the name in spec.hostname. It you name the sts with "abc" and create it, it can create pod abc-0. `oc get pod abc-0 -o yaml`, it shows: spec ... hostname: abc-0 This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug. If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. |