2
关注
4638
浏览

用docker-machine创建虚拟主机

您还未登录!暂时最多只可查看 1 条回答

登录! 还没有账号?去注册

XXXX 注册会员 用户来自于: 局域网
2020-07-17 18:38
用docker-machine创建虚拟主机 环境 Window server 2012 R2 64 VMware Workstation 12 CentOS 7 创建虚拟主机 创建一个 oracle virtualbox 为驱动的虚拟主机,关于主机驱动可以参考官网:https://docs.docker.com/machine/drivers/ 问题现象一: –engine-registry-mirror https://1rqn7spi.mirror.aliyuncs.com [root@docker4~]#docker-machinecreate-drivervirtualbox –engine-registry-mirror https://1rqn7spi.mirror.aliyuncs.com host1 Creating CA:/root/.docker/machine/certs/ca.pem Creating client certificate:/root/.docker/machine/certs/cert.pem Running pre-create checks… Error with pre-create check:”VBoxManage not found. Make sure VirtualBox is installed and VBoxManage isin the path” 问题原因: 没有安装virtualbox 解决办法: 安装virtualbox 下载方法一: 下载地址https://www.virtualbox.org/wiki/Linux_Downloads,下载安装包,然后上传到/root 下载方法二: [root@docker4 ~]# yum -yinstall wget [root@docker4~]#wgethttp://download.virtualbox.org/virtualbox/rpm/rhel/7/x86_64/VirtualBox-5.1-5.1.20_114628_el7-1.x86_64.rpm [root@docker4 ~]# yum -yinstall VirtualBox-5.1-5.1.20_114628_el7-1.x86_64.rpm [root@docker4~]#docker-machinecreate–drivervirtualbox –engine-registry-mirrorhttps://1rqn7spi.mirror.aliyuncs.com host1 Running pre-create checks… Error with pre-create check: “This computerdoesn’t have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory” 注意事项: 1、BIOS需要开起硬件虚拟化支持 2、不要用Oracle VM virtaulbox创建虚拟机,Oracle VM virtaulbox不支持嵌套虚拟机。本文用的是VMware Workstation,所以是在 虚拟机->设置 里设置处理器的虚拟化引擎首选模式为“Intel VT-x/EPT 或AMD-V/RVI”及“虚拟化Intel VT-x/EPT 或AMD-V/RVI(V)” [root@docker4~]# docker-machine create –drivervirtualbox –engine-registry-mirror https://1rqn7spi.mirror.aliyuncs.com host1 Running pre-create checks… Creating machine… (host3)Copying/root/.docker/machine/cache/boot2docker.isoto/root/.docker/machine/machines/host3/boot2docker.iso… (host3) Creating VirtualBox VM… (host3) Creating SSH key… Wrapper Docker Machine process exiting due toclosed plugin server (read tcp 127.0.0.1:52580->127.0.0.1:33112: read:connection reset by peer) Error creating machine: Error in driver duringmachine creation: read tcp 127.0.0.1:52580->127.0.0.1:33112: read:connection reset by peer 到源码网址:https://github.com/boot2docker/boot2docker/releases 下载boot2docker.iso 然后上传到/root/.docker/machine/cache [root@docker4 ~]# docker-machine create –driver virtualbox –engine-registry-mirror https://1rqn7spi.mirror.aliyuncs.com host1 Running pre-create checks… Creating machine… (host2)Copying/root/.docker/machine/cache/boot2docker.iso to/root/.docker/machine/machines/host2/boot2docker.iso… (host2) Creating VirtualBox VM… (host2) Creating SSH key… (host2) Starting the VM… (host2) Check network to re-create if needed… (host2) Found a new host-only adapter:”vboxnet0″ (host2) Waiting for an IP… Waiting for machine to be running, this may take afew minutes… Detecting operating system of created instance… Waiting for SSH to be available… Detecting the provisioner… Provisioning with boot2docker… Copying certs to the local machine directory… Copying certs to the remote machine… Setting Docker configuration on the remotedaemon… Checking connection to Docker… Docker is up and running! To see how to connect your Docker Client to theDocker Engine running on this virtual machine, run: docker-machine env host1 到这里虚拟机就创建成功了。 下面查看虚拟机列表 [root@localmachine2host~]#docker-machinels NAME ACTIVE DRIVER STATE URL SWARM DOCKER ERRORS host1 – virtualbox Running tcp://192.168.99.100:2376 v17.06.0-ce 用本机docker客户端指向host1的docker [root@localmachine2host ~]# eval $(docker-machine env host1) [root@localmachine2host ~]# docker info ——————— 原始文章来源: 作者:xjj1314 来源:CSDN 原文:https://blog.csdn.net/xjj1314/article/details/76697161

关于作者

问题动态

发布时间
2020-07-07 20:21
更新时间
2020-07-17 18:38
关注人数
2 人关注

相关问题

创建中间表页面的“批量添加”按钮是干什么用的?
DataFocus在搜索界面用单表创建中间表
创建数据看板的时候有模版,这个模版怎么使用?
系统角色创建时的管理权限都代表什么意思?
如何创建中间表?
创建角色时,角色权限主要哪些?
在数据管理和搜索页面创建中间表有何区别?
在datafocus中可以创建数据表么?
创建中间表时,数据源个数有限制吗?
关联关系的创建里面,可以使用三张表格么,还是说最多只能两两关联?

推荐内容

我要下载一个标准版,怎么还要费用的啊?
MAC在parallel desktop虚拟机中如何将下载的datafocus安装文件传到虚拟机中
DataFocus如何配置移动端 -企业微信
这些服务器能删掉吗?
轨迹图一般需要什么条件?
DataFocus有必要购入标准版么?
我之前安装了迷你版,现在能升级到标准版的吗?
迷你版能否创建关联关系?能支持移动端吗?
安装CENTOS的datafocus选中文,还是英文呀?
安装卸载相关功能说明

热门话题

ETL工程师

数据分析

折线图

数据源连接

排序

热门专栏

数据分析模型探讨研究

热门用户

sophia

datafocus6cbde208694dc540012c8b

叮咚

later

qqqq