{"id":12779,"date":"2015-09-14T06:22:00","date_gmt":"2015-09-13T22:22:00","guid":{"rendered":"http:\/\/blog.pmail.idv.tw\/?p=12779"},"modified":"2015-09-14T06:22:00","modified_gmt":"2015-09-13T22:22:00","slug":"windows-server-2016-tp3-nano-server-in-vm-ip%e8%a8%ad%e5%ae%9a%e5%8f%8a%e7%ae%a1%e7%90%86nano","status":"publish","type":"post","link":"https:\/\/blog.pmail.idv.tw\/?p=12779","title":{"rendered":"Windows Server 2016 TP3&ndash; Nano Server in VM (IP\u8a2d\u5b9a\u53ca\u7ba1\u7406Nano)"},"content":{"rendered":"<p>\u524d\u9762\u5169\u7bc7\u95dc\u65bcNano&nbsp; Server&nbsp; in VM&nbsp; \u5b89\u88dd\u5206\u5225\u5229\u7528\u570b\u5916\u7db2\u53cb\u53e6\u5916\u5beb\u7684powershell&nbsp; \u53ca ws 2016 tp3 \u5149\u789f\u4e2d\u7684powershell \u6210\u529f\u5efa\u7acbVM \u4f46\u662f\u5176\u4e2d\u4e26\u6c92\u6709\u63d0\u5230IP\u8a2d\u5b9a\u53ca\u7ba1\u7406\u7684\u90e8\u5206\u3002<\/p>\n<p><!--more--><\/p>\n<p>\u5982\u679c\u662fip\u8a2d\u5b9a\u90e8\u5206\u7576\u7136\u74b0\u5883\u4e2d\u5982\u679c\u6709dhcp&nbsp; Server \u90a3Nano \u5c31\u53ef\u4ee5\u7372\u5f97\u52d5\u614bIP\uff0c\u5982\u679c\u8981\u8a2d\u5b9a\u975c\u614bIP \u5176\u4e2dtechnet \u6587\u4ef6\u4e2d\u6709\u63d0\u5230\u505a\u6cd5\u662f\u53ef\u4ee5\u5728Windows \u5b89\u88dd\u5b8c\u6210\u5f8c\u57f7\u884c\u81ea\u8a02\u6307\u4ee4\u78bc<\/p>\n<p>\u4f7f\u7528powershell \u628aNano Server \u865b\u64ec\u786c\u789f\u5efa\u7acb\u5b8c\u7562\u5f8c\uff0c\u5728\u9084\u6c92\u6709\u958b\u6a5f\u6642\uff0c\u53ef\u4ee5\u5148\u5728\u672c\u6a5f\u5c07\u8a72\u865b\u64ec\u786c\u789f\u5148\u639b\u8f09\u8d77\u4f86.\u4e26\u5c07script \u653e\u5230 <strong><font color=\"#ff0000\">%WINDIR%\\Setup\\Scripts\\<\/font><\/strong> \u9019\u500b\u76ee\u9304\u4e14script \u6a94\u540d\u70ba <strong><font color=\"#ff0000\">SetupComplete.cmd<\/font><\/strong>&nbsp; \u3002<\/p>\n<p>\u90a3SetupComplete.com \u7684\u5167\u5bb9(technet \u6587\u4ef6\u7684\u7bc4\u4f8b):<\/p>\n<p>powershell.exe -command &#8220;Import-Module C:\\windows\\system32\\windowspowershell\\v1.0\\Modules\\Microsoft.PowerShell.Utility\\Microsoft.PowerShell.Utility.psd1; Import-Module C:\\windows\\system32\\WindowsPowerShell\\v1.0\\Modules\\NetAdapter\\NetAdapter.psd1; $ifa = (Get-NetAdapter -Name Ethernet).ifalias; netsh interface ip set address $ifa static 192.168.100.23&#8221;<\/p>\n<p>&nbsp;<\/p>\n<p>\u5be6\u4f5c:<\/p>\n<p>\u639b\u8f09\u865b\u64ec\u786c\u789f\u5f8c\u53ef\u4ee5\u770b\u5230c:\\windows \u76ee\u9304\u6c92\u6709setup\\scripts \u76ee\u9304<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/nano22.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"nano22\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"nano22\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/nano22_thumb.jpg\" width=\"644\" height=\"431\"><\/a><\/p>\n<p>\u6b64\u6642\u53ef\u4ee5\u81ea\u884c\u5efa\u7acbsetup\\scripts \u76ee\u9304\u6700\u5f8c\u518d\u5c07<strong><font color=\"#ff0000\">SetupComplete.cmd<\/font><\/strong>&nbsp; \u653e\u5165\u5373\u53ef<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/nano23.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"nano23\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"nano23\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/nano23_thumb.jpg\" width=\"644\" height=\"286\"><\/a><\/p>\n<p><strong><font color=\"#ff0000\">SetupComplete.cmd<\/font><\/strong>&nbsp; \u5167\u5bb9\u4e2d\u6211\u662f\u591a\u65b0\u589e\u4e86DNS \u8a2d\u5b9a<\/p>\n<p>powershell.exe -command &#8220;Import-Module C:\\windows\\system32\\windowspowershell\\v1.0\\Modules\\Microsoft.PowerShell.Utility\\Microsoft.PowerShell.Utility.psd1; Import-Module C:\\windows\\system32\\WindowsPowerShell\\v1.0\\Modules\\NetAdapter\\NetAdapter.psd1; $ifa = (Get-NetAdapter -Name Ethernet).ifalias; netsh interface ip set address $ifa static 192.168.1.30 255.255.255.0 192.168.1.254&#8243;; netsh interface ip set dnsservers $ifa static 192.168.1.1 primary &#8221;&nbsp;&nbsp;&nbsp; <\/p>\n<p><strong><font color=\"#ff0000\">SetupComplete.cmd<\/font><\/strong>\u4e0b\u8f09: <a href=\"https:\/\/drive.google.com\/file\/d\/0Bz1TgH_bp57acERTVjRULXZUMWM\/view?usp=sharing\" target=\"_blank\">\u9ede\u6211<\/a>&nbsp; (\u4fee\u6539IP\u5373\u53ef\u4f7f\u7528)<\/p>\n<p>\u6700\u5f8c\u5c07\u865b\u64ec\u786c\u789f\u639b\u8f09\u5230hyper-v \u4e2d\u4e26\u4e14\u958b\u6a5f\uff0c\u7b2c\u4e00\u6b21\u958b\u6a5f\u6703\u770b\u5230\u57f7\u884c\u8a72script \u7684\u756b\u9762<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/114.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"114\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"114\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/114_thumb.jpg\" width=\"644\" height=\"328\"><\/a><\/p>\n<p>\u958b\u6a5f\u5f8c\u4e5f\u53ef\u4ee5\u770b\u5230\u975c\u614bIP \u53caDNS \u8a2d\u5b9aOK<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/115.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"115\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"115\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/115_thumb.jpg\" width=\"600\" height=\"484\"><\/a><\/p>\n<p>\u5229\u7528server manager \u4f86\u7ba1\u7406<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/117.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"117\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"117\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/117_thumb.jpg\" width=\"644\" height=\"347\"><\/a><\/p>\n<p>\u5728\u5efa\u7acb\u6642\u5df2\u7d93\u5c07\u8a72nano server \u52a0\u5165\u7db2\u57df\u6240\u4ee5\u53ef\u4ee5\u5f88\u8f15\u9b06\u4f86\u7ba1\u7406\u4ed6<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/118.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"118\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"118\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/118_thumb.jpg\" width=\"642\" height=\"484\"><\/a><\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/119.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"119\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"119\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/119_thumb.jpg\" width=\"644\" height=\"228\"><\/a><\/p>\n<p>\u53ef\u4ee5\u4f7f\u7528powershell \u4f86\u7ba1\u7406<\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/120.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"120\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"120\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/120_thumb.jpg\" width=\"644\" height=\"446\"><\/a><\/p>\n<p><a href=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/121.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"121\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"121\" src=\"https:\/\/blog.pmail.idv.tw\/wp-content\/uploads\/2015\/09\/121_thumb.jpg\" width=\"644\" height=\"418\"><\/a><\/p>\n<div class=\"21cd169d3c0f71e95b84db320302cb4a\" data-index=\"1\" style=\"float: right; margin:10px 0 10px 10px;\">\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-8711325745898650\"\r\n     crossorigin=\"anonymous\"><\/script>\n<\/div>\n\n<div style=\"font-size: 0px; height: 0px; line-height: 0px; margin: 0; padding: 0; clear: both;\"><\/div>","protected":false},"excerpt":{"rendered":"<p>\u524d\u9762\u5169\u7bc7\u95dc\u65bcNano&nbsp; Server&nbsp; in VM&#038;nbsp &hellip; <a href=\"https:\/\/blog.pmail.idv.tw\/?p=12779\">\u95b1\u8b80\u5168\u6587 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"footnotes":""},"categories":[127],"tags":[],"class_list":["post-12779","post","type-post","status-publish","format-standard","hentry","category-tp3"],"_links":{"self":[{"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=\/wp\/v2\/posts\/12779","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=12779"}],"version-history":[{"count":0,"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=\/wp\/v2\/posts\/12779\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=12779"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=12779"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.pmail.idv.tw\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=12779"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}