@H_404_0@根据官方文档介绍,至少需要三个节点来运行一整套DC/OS系统,因为我只能申请到2台高性能的虚拟机,所以就用了以下运行环境,使用的Bluemix 英国的zone:
Nmae | IP | OS | Role | Mem | cpu |
ukcent1 | 192.168.0.22 | CentOS7.2 | DC/OS Master | 4GB | Intel Xeon E312xx |
ukcent2 | 192.168.0.23 | CentOS7.2 | DC/OS Slave | 4GB | Intel Xeon E312xx |
@H_404_0@软件环境要求:
- @H_404_0@Python,pip must be installed for DC/OS CLI.
- @H_404_0@A High-availability (HA) TCP/Layer 3 load balancer,such as HAProxy,to balance the following TCP ports to all master nodes: 80,443,8080,8181,2181,5050. (If applicable)
- @H_404_0@An unencrypted SSH key that can be used to authenticate with the cluster nodes over SSH. Encrypted SSH keys are not supported.@H_404_0@
@H_404_0@系统要求:
- @H_404_0@更新系统到最新:@H_404_0@yum -y upgrade
- @H_404_0@关闭firewalld@H_404_0@在Github上已经有一个open的issue https://github.com/docker/docker/issues/16137, Docker与firewalld 一起工作的效果会很差:https://docs.docker.com/v1.6/installation/centos/#firewalld@H_404_0@sudo systemctl stop firewalld && sudo systemctl disable firewalld
- @H_404_0@SSH enabled
- @H_404_0@ICMP enabled
- @H_404_0@NTP enabled
@H_404_0@软件要求:
- @H_404_0@Docker 1.9 or greater is recommended.
- @H_404_0@不要使用Docker的DeviceMapper 存储方式
- @H_404_0@使用OverlayFS或者DeviceMapper 附加直接lvm的方式,而不是loop-lvm。请看这篇文章:http://www.jb51.cc/article/p-ckrsppmg-bcx.html
- @H_404_0@用root用户开启Docker。
- @H_404_0@sudo 用户免密码提权@H_404_0@%wheel ALL=(ALL) NOPASSWD: ALL
- @H_404_0@安装xz unzip curl ipset在所有节点。
- @H_404_0@禁用selinux,并添加nogroup到所有节点。
- @H_404_0@pull Nginx image到Master节点。
@H_404_0@
@H_404_0@下面开启正式的安装之旅: @H_404_0@官方文档介绍的是有一个bootstrap node,专门用来做bootstrap的,由于我只有2台机器,就直接用Master做bootstrap了,在Master节点上下载安装脚本:
@H_404_0@
$curl-Ohttps://downloads.dcos.io/dcos/EarlyAccess/dcos_generate_config.sh@H_404_0@
@H_404_0@以web GUI的方式安装DC/OS:
@H_404_0@
$sudobashdcos_generate_config.sh--web@H_404_0@
@H_404_0@会开启本机的9000端口,信息如下: @H_404_0@
Runningmesosphere/dcos-genconfdockerwithBUILD_DIRsetto/home/centos/genconf 16:36:09dcos_installer.action_lib.prettyprint::====>StartingDC/OSinstallerinwebmode 16:36:09root::Startingserver('0.0.0.0',9000)@H_404_0@
@H_404_0@打开我的Master公网ip:9000就会看到安装界面了:
@H_404_0@
@H_404_0@
@H_404_0@
- @H_404_0@Master Private IP List
- @H_404_0@Agent Private IP List
- @H_404_0@Master Public IP
- @H_404_0@SSH Username,Port and Private Key
- @H_404_0@Upstream DNS Servers
- @H_404_0@IP Dect Script
#!/usr/bin/envbash set-onounset-oerrexit exportPATH=/usr/sbin:/usr/bin:$PATH echo$(ipaddrshoweth0|grep-Eo'[0-9]{1,3}\.[0-9]{1,3}'|head-1)@H_404_0@
@H_404_0@然后点击“Run Pre-Flight”,如果没有什么问题,会看到:
@H_404_0@
@H_404_0@
@H_404_0@然后点击“Deploy”: @H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@
@H_404_0@参考连接: @H_404_0@https://dcos.io/docs/1.7/administration/installing/custom/gui/ @H_404_0@https://github.com/dcos/dcos @H_404_0@https://dcos.io/docs/1.7/usage/