hyper-v

hyper-v 安装Centos及网络配置

北慕城南 提交于 2020-01-13 14:52:39
新安装的Centos系统默认情况下是不能上网的,需要经过相应的配置;选择对应的虚拟机,点击“虚拟交换机管理器”; 设置hyper-v上的网络及分配cpu、内存、磁盘等资源。 安装CentOS7 过程中,先设置网关、IP、子网掩码。 安装完成启动系统后需要用root帐号登录; 桌面右击打开终端命令窗口; 输入以下命令,进入网络配置文件目录; cd /etc/sysconfig/network-scripts/ 输入ls(注意是小写英文字母L,不是1)命令查看具体包含了哪些文件; 通过vi进入ifcfg的第一个文件进行配置或修改; vi ifcfg-eth0(默认文件名) 开启自动启用网络连接; ONBOOT=yes 添加或修改ip地址; IPADDR0=xxx.xxx.xxx.xxx 添加或修改子网掩码; PREFIXO0=24 添加或修改网关地址; GATEWAY0=255.255.255.0 添加或修改DNS服务器; DNS1=(如192.168.1.1) 最后使设置生效并测试是否成功; :wq! #保存退出 service network restart #重启网络 ping www.baidu.com #测试网络是否正常 设置主机名为www; hostname www #设置主机名为www vi /etc/hostname #编辑配置文件 www #修改localhost

Unable to copy to Windows container ('docker cp') on Windows 10

拈花ヽ惹草 提交于 2020-01-13 07:46:10
问题 I set up Docker for Windows on my laptop and switched from Linux Containers to Windows Containers in Docker's settings (which prompted a couple of restarts and Windows updates). I pulled an image and ran a container based on it using the commands: docker pull microsoft/dotnet-framework docker run -it microsoft/dotnet-framework cmd In a second terminal window, I executed the command: docker cp app container_id:/ and received this error message: Error response from daemon: filesystem operations

Hyper-V中安装CentOS

送分小仙女□ 提交于 2020-01-12 17:55:25
转自: https://www.cnblogs.com/cxxjohnson/p/9267988.html 1、设置开启Hyper-V应用程序? 在搜索功能里输入 Hyper-V 然后点击选中的部分 3、在搜索功能里输入Hyper-V 打开 虚拟机存储位置 7、分配内存根据自己情况来设置 交换机为无线网卡 设置 见下图 步骤:) 9、连接虚拟硬盘 11、设置信息如下:通过摘要查看 (最后点击完成后自动创建虚拟机) 13、安装Centos7 选中图中部分 进入安装界面? 15、点击 Done 选择自动分区? 18、等待重启? 然后用root用户登陆 密码是刚才设置的 网络桥接右键 桥接(桥接完成之后记得通过属性修改网桥的IP地址 手动设置) 来源: https://www.cnblogs.com/kxxx/p/11711866.html

hyper-v 安装Centos及网络配置

心已入冬 提交于 2020-01-12 09:12:28
新安装的Centos系统默认情况下是不能上网的,需要经过相应的配置;选择对应的虚拟机,点击“虚拟交换机管理器”; 设置hyper-v上的网络及分配cpu、内存、磁盘等资源。 安装CentOS7 过程中,先设置网关、IP、子网掩码。 安装完成启动系统后需要用root帐号登录; 桌面右击打开终端命令窗口; 输入以下命令,进入网络配置文件目录; cd /etc/sysconfig/network-scripts/ 输入ls(注意是小写英文字母L,不是1)命令查看具体包含了哪些文件; 通过vi进入ifcfg的第一个文件进行配置或修改; vi ifcfg-eth0(默认文件名) 开启自动启用网络连接; ONBOOT=yes 添加或修改ip地址; IPADDR0=xxx.xxx.xxx.xxx 添加或修改子网掩码; PREFIXO0=24 添加或修改网关地址; GATEWAY0=255.255.255.0 添加或修改DNS服务器; DNS1=(如192.168.1.1) 最后使设置生效并测试是否成功; :wq! #保存退出 service network restart #重启网络 ping www.baidu.com #测试网络是否正常 设置主机名为www; hostname www #设置主机名为www vi /etc/hostname #编辑配置文件 www #修改localhost

How to reduce default VM memory for Docker Linux containers on Windows

隐身守侯 提交于 2020-01-12 03:55:48
问题 Scenario Windows 10 Professional Docker 18.06.1-ce running in Windows container mode 4GB of available memory on host system using Hyper-V virtual machine Problem When trying to "switch to Linux containers" via Docker's taskbar item the process fails after a couple of seconds showing an error about "Not enough memory to start Docker". Since the host system does not have that much memory, I'd like to reduce the maximum amount of memory the global Docker machine is allowed to use (I think 2 GB

hyper-v简介及安装使用

旧城冷巷雨未停 提交于 2020-01-12 01:13:14
前言: 作为IT界的巨头,微软自己的虚拟化技术,也是微软第一个采用Vmware与CitrixXen一样基于hypervisor的虚拟化技术,有着自己可圈可点的地方,微软自己的虚拟化技术嘛,对windows的支持基本是没有问题的,而根据官方的资料介绍,它甚至可以安装专门为Linux设计的Integrated Components(里面包含磁盘和网络适配器的VMbus驱动)以使Linux虚机也能获得高性能,同样的,和主流的虚拟化技术相似,hyper-v也支持半虚拟化与全虚拟化,但它的半虚拟化仅支持与宿主机相同版本的系统,如果你不喜欢它的图形化界面,那你也可以在Server Core(命令行的windows)上安装hyper-v虚拟化程序,来满足自己的需求。   总而言之,hyper-v虚拟化技术继承了它的缔造者,微软图形化界面方便操作与直观展示的好处,按它的说法,它的虚拟化性能不比业界主流的虚拟化性能差,那就让时间来检验它的真伪吧。本文章旨在介绍在windows server2012操作系统上安装hyper-v并使用它来建立你的第一个虚拟机程序。 hyper-v运行平台: windows server2008R2及更高版本的服务器系统,win7及更高版本桌面操作系统,hyper-v server 操作系统 硬件要求:       Intel或者AMD64位处理器      

Call a specific version of PowerShell from C#

拟墨画扇 提交于 2020-01-11 13:06:28
问题 I'm trying to use the Get-VM Cmdlet called from C# on a Hyper-V host. Obviously, the according PowerShell module Hyper-V has to be imported first. The import fails, however - apparently because the module is supported only on PowerShell 3.0 (at least that's what I figure from this article). The PowerShell used by System.Management.Automation seems to be version 2.0, though. InitialSessionState iss = InitialSessionState.CreateDefault(); iss.ImportPSModule(new string[] { "Hyper-V" }); Runspace

Call a specific version of PowerShell from C#

一曲冷凌霜 提交于 2020-01-11 13:06:08
问题 I'm trying to use the Get-VM Cmdlet called from C# on a Hyper-V host. Obviously, the according PowerShell module Hyper-V has to be imported first. The import fails, however - apparently because the module is supported only on PowerShell 3.0 (at least that's what I figure from this article). The PowerShell used by System.Management.Automation seems to be version 2.0, though. InitialSessionState iss = InitialSessionState.CreateDefault(); iss.ImportPSModule(new string[] { "Hyper-V" }); Runspace

Windows10家庭版安装虚拟机

江枫思渺然 提交于 2020-01-10 14:06:52
在日常开发中经常有需要兼容IE8的需求,win10默认的IE版本是11,而且版本并不能回退。这时候就需要在电脑上安装虚拟机测试IE8兼容性问题。 在个人电脑上常见的虚拟机有VMware Workstation、Virtual Box、Parallels Desktop、Hyper-V等,这里主要介绍的是Hyper-V。 Windows10家庭版是不开启Hyper-V的,除非升级为专业版,但仅仅想用Hyper-V而升级为专业版完全没有必要,因为家庭版其实是能添加Hyper-V的。 Hyper-V对硬件还是有些要求的,针对服务器,只要满足以下四个条件就可以使用Hyper-v角色: 1.CPU支持数据执行保护(DEP)。 2.CPU支持硬件虚拟化技术。 3.CPU64位处理器。 4.内存最低限度为2GB。 针对个人电脑,除了以上几个要求外,CPU还必须支持二级地址转换,否则,是无法添加Hyper-V的。 一、查看电脑是否支持Hyper-V 可以使用Coreinfo工具软件 ( 下载地址 )来查看电脑是否支持Hyper-V,这是微软SysinternalsSuite工具软件套件中的一个,很实用。具体使用方法,把下载好的Coreinfo解压到桌面上,用管理员模式打开PowerShell,输入:.\ Coreinfo.exe -v,将显示你电脑虚拟化的相关信息,当然你已经添加了Hyper-V了

How to use Kitematic with Hyper-V enabled?

拈花ヽ惹草 提交于 2020-01-03 08:39:09
问题 I have installed Docker for Windows (running Windows 10). Out of the box, Docker would not install an image on Hyper-V but I was able to get it work. Edit : I acquired Kitematic via the link from this screen: Upon clicking download, I get a zip file via http. Next, I copied Kitematic zip contents to c:\program files\docker\kitematic. When I run Kitematic from Docker menu, it gives me an error stating: VirtualBox is not installed. Please install it via the Docker Toolbox. I don't want to use