Red Hat Bugzilla – Bug 1271468
Running-in-a-docker-container section on Administrator guide should have note to stop kubernetes service if running
Last modified: 2016-11-08 01:29:17 EST
Description of problem:
Document used:- https://docs.openshift.org/latest/getting_started/administrators.html#running-in-a-docker-container
I was trying to experiment today about deploy testing instance of openshift in my devel box which had already running kubernetes services and default ports are occupied by it. Now if I run openshift container as per document then It will exit and when I checked logs from docker then found it try to listen 7001 port which is already occupied by etcd running on devel box.
$ docker logs origin
Generated new key pair as openshift.local.config/master/serviceaccounts.public.key and openshift.local.config/master/serviceaccounts.private.key
I1014 05:39:27.496912 1 plugins.go:71] No cloud provider specified.
I1014 05:39:27.545470 1 start_master.go:386] Starting master on 0.0.0.0:8443 (v1.0.6-519-g86b63be)
I1014 05:39:27.545508 1 start_master.go:387] Public master address is https://10.65.201.190:8443
I1014 05:39:27.545559 1 start_master.go:391] Using images from "openshift/origin-<component>:v1.0.6"
F1014 05:39:27.693065 1 etcd.go:65] Unable to start etcd: listen tcp 0.0.0.0:7001: bind: address already in use
$ sudo netstat -ntpl
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:10252 0.0.0.0:* LISTEN 29396/kube-controll
tcp 0 0 127.0.0.1:2380 0.0.0.0:* LISTEN 29285/etcd
tcp 0 0 127.0.0.1:10255 0.0.0.0:* LISTEN 29623/kubelet
tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 29319/kube-apiserve
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 874/sshd
tcp 0 0 127.0.0.1:7001 0.0.0.0:* LISTEN 29285/etcd
tcp 0 0 127.0.0.1:10248 0.0.0.0:* LISTEN 29623/kubelet
tcp 0 0 127.0.0.1:10249 0.0.0.0:* LISTEN 29570/kube-proxy
tcp 0 0 127.0.0.1:10250 0.0.0.0:* LISTEN 29623/kubelet
tcp 0 0 127.0.0.1:10251 0.0.0.0:* LISTEN 29428/kube-schedule
tcp 0 0 127.0.0.1:2379 0.0.0.0:* LISTEN 29285/etcd
tcp6 0 0 :::8081 :::* LISTEN 12841/docker-proxy
tcp6 0 0 :::8083 :::* LISTEN 18931/docker-proxy
tcp6 0 0 :::22 :::* LISTEN 874/sshd
tcp6 0 0 :::40001 :::* LISTEN 29570/kube-proxy
tcp6 0 0 :::4194 :::* LISTEN 29623/kubelet
tcp6 0 0 :::9090 :::* LISTEN 1/systemd
Version-Release number of selected component (if applicable): 3.x
Steps to Reproduce:
1. Setup a dev-box
2. start kubernetes and docker service on that dev box
3. try to run openshift container on that box
failed because of port conflict.
It should be better if it is mention as a Note to document that kubernetes service should not be running when you are running openshift/origin image so that it will avoid that confusion.
updated with a Caution re: potential port conflict
When you raise needinfo flag then also describe what information you require for reporter end. I didn't see any requested information so clearing this flag. If you have something then raise it again with proper required information.
@timothy Thanks for handing it.
Hey Praveen, sorry about that. Hope that the information that Tim has added has adequately satisfied the needs of this bug.
Once the docs are live, I will close this bug.
Updated my pull request based on review from Alex Dellapenta