1. Failed to get D-Bus connection: Operation not permitted error
when you execute the systemctl start sshd or start other service, maybe you will encounter this error. this is a bug for Centos7, it will be fixed in 7.2.
so now you can just use the full path like /usr/sbin/sshd & to start the service.
2.Could not load host key: /etc/ssh/ssh_host_ecdsa_key
some key file maybe need manually generated.
After you install openssh-server, you should simplely config the sshd service.
permitRootlogin, and port 22 in /etc/ssh/sshd_config
ssh-keygen -t ecdsa -f /etc/ssh/ssh_host_ecdsa_key
ssh-keygen -t ed25519 -f /etc/ssh/ssh_host_ed25519_key
3.start docker service and set it autostart after system start
sudo systemctl enable docker.service
start the docker service manully:
sudo systemctl start docker.service
4.
docker network create -d bridge hadoop
dk run --net=hadoop -h=nn1 --name=nn1 -v /nn1:/data -itd -p 50070:50070 -p 8081:8081 yaoshuya/hadoop-base
dk run --privileged --net=hadoop -h=nn2 --name=nn2 -v /nn2:/data -itd -p 50071:50070 -p 8082:8081 yaoshuya/hadoop-base
5。基本思路
下载一个最新的CENTOS库,然后加载本地的APP目录到容器中,
把APP中的相关文件复制到容器中,如JDK,SCALASDK,SPARK,HADOOP,HIVE等软件,配置好并保存容器。
需要注意的是最好安装以下软件,
yum install –y which openssh-server
然后配置本机的无密钥访问。
这样基本HADOOP的容器就可以使用了,新的版本比较成熟,很多问题已经有很好的解决方案了。如网络问题。