The status of docker run is existing.

  docker, question

In the use of online docshttps://github.com/yeasy/docker_practice/blob/master/mesos/installation.md

docker run –net=”host” \
-p 5050:5050 \
-e “MESOS_HOSTNAME=${HOST_IP}” \
-e “MESOS_IP=${HOST_IP}” \
-e “MESOS_ZK=zk://${HOST_IP}:2181/mesos” \
-e “MESOS_PORT=5050” \
-e “MESOS_LOG_DIR=/var/log/mesos” \
-e “MESOS_QUORUM=1” \
-e “MESOS_REGISTRY=in_memory” \
-e “MESOS_WORK_DIR=/var/lib/mesos” \
-d \
garland/mesosphere-docker-mesos-master

clipboard.png

I’d like to know how to debug, but I don’t have a log.

Operating steps

1. 设置本机的IP地址
HOST_IP=10.11.31.7
2. 运行ZooKeeper容器
docker run -d \
 -p 2181:2181 \
 -p 2888:2888 \
 -p 3888:3888 \
 garland/zookeeper
3. 运行Mesos Master容器
docker run --net="host" \
 -p 5050:5050 \
 -e "MESOS_HOSTNAME=${HOST_IP}" \
 -e "MESOS_IP=${HOST_IP}" \
 -e "MESOS_ZK=zk://${HOST_IP}:2181/mesos" \
 -e "MESOS_PORT=5050" \
 -e "MESOS_LOG_DIR=/var/log/mesos" \
 -e "MESOS_QUORUM=1" \
 -e "MESOS_REGISTRY=in_memory" \
 -e "MESOS_WORK_DIR=/var/lib/mesos" \
 -d \
 garland/mesosphere-docker-mesos-master
4. 运行Marathon容器
docker run \
 -d \
 -p 8080:8080 \
 garland/mesosphere-docker-marathon --master zk://${HOST_IP}:2181/mesos --zk zk://${HOST_IP}:2181/marathon
5. 运行Mesos Slave容器
docker run -d \
 --name mesos_slave_1 \
 --entrypoint="mesos-slave" \
 -e "MESOS_MASTER=zk://${HOST_IP}:2181/mesos" \
 -e "MESOS_LOG_DIR=/var/log/mesos" \
 -e "MESOS_LOGGING_LEVEL=INFO" \
 garland/mesosphere-docker-mesos-master:latest

I ran again, no problem, you can passdocker logsCommand to view the container log for debugging.