简体   繁体   English

使用DISM在Windows 2008 R2上安装.net 3.5

[英]Install .net 3.5 on Windows 2008 R2 using DISM

I'm writing an installer which uses DISM to enable features and roles on 2012 and 2008 R2. 我正在写一个使用DISM在2012和2008 R2上启用功能和角色的安装程序。

I'm confused about where .Net 3.5 is located in server 2008. On 2012, I am aware that either online access is required or the OS media needs to be mounted. 我对.Net 3.5在服务器2008中的位置感到困惑。在2012年,我知道需要在线访问或需要安装OS媒体。

On 2008 R2 however, I have just disabled network access and managed to install the .Net 3.5 feature. 但是,在2008 R2上,我刚刚禁用了网络访问并设法安装了.Net 3.5功能。 However, when I use the following DISM command I am unable to get the feature installed: dism /online /enable-feature /featurename:NetFx3 /source:c\\windows\\winsxs /LimitAccess 但是,当我使用以下DISM命令时,无法安装该功能:dism / online / enable-feature / featurename:NetFx3 / source:c \\ windows \\ winsxs / LimitAccess

I'm assuming that this is due to .net 3.5 not being in the winsxs folder. 我假设这是由于.net 3.5不在winsxs文件夹中。

Can anyone tell me where it is so I can use the dism command? 谁能告诉我它在哪里,所以我可以使用dism命令?

Thanks in advance 提前致谢

Ok, so changing the above line in the dism from 好的,所以从

dism /online /enable-feature /featurename:NetFx3 /source:c\\windows\\winsxs /LimitAccess dism / online /启用功能/功能名称:NetFx3 / source:c \\ windows \\ winsxs / LimitAccess

to

dism /online /enable-feature /featurename:NetFx3 dism / online /启用功能/功能名称:NetFx3

installs the component ok. 确定安装组件。 I disabled internet access so unlike server 2012 R2 you dont need to give 2008 R2 a location if you are not using the internet or the OS ISO. 我禁用了Internet访问,因此与Server 2012 R2不同,如果您不使用Internet或OS ISO,则无需为2008 R2提供位​​置。

  1. Mount windows 10 dvd 挂载Windows 10 DVD
  2. rus as administrator cmd.exe rus作为管理员cmd.exe
  3. run this command: dism.exe /online /enable-feature /featurename:NetFX3 /Source:g:\\sources\\sxs 运行以下命令: dism.exe /online /enable-feature /featurename:NetFX3 /Source:g:\\sources\\sxs

note: "g:" is the drive that windows 10 has mounted 注意:“ g:”是Windows 10已安装的驱动器

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM