使用 dism 命令安装 IIS、net4.5

安装IIS:

dism /Online /Enable-Feature    /FeatureName:IIS-ApplicationDevelopment    /FeatureName:IIS-ASP    /FeatureName:IIS-ASPNET    /FeatureName:IIS-BasicAuthentication    /FeatureName:IIS-CGI    /FeatureName:IIS-ClientCertificateMappingAuthentication    /FeatureName:IIS-CommonHttpFeatures    /FeatureName:IIS-CustomLogging    /FeatureName:IIS-DefaultDocument    /FeatureName:IIS-DigestAuthentication   /FeatureName:IIS-DirectoryBrowsing   /FeatureName:IIS-FTPExtensibility   /FeatureName:IIS-FTPServer   /FeatureName:IIS-FTPSvc   /FeatureName:IIS-HealthAndDiagnostics   /FeatureName:IIS-HostableWebCore   /FeatureName:IIS-HttpCompressionDynamic   /FeatureName:IIS-HttpCompressionStatic   /FeatureName:IIS-HttpErrors   /FeatureName:IIS-HttpLogging   /FeatureName:IIS-HttpRedirect   /FeatureName:IIS-HttpTracing   /FeatureName:IIS-IIS6ManagementCompatibility   /FeatureName:IIS-IISCertificateMappingAuthentication   /FeatureName:IIS-IPSecurity   /FeatureName:IIS-ISAPIExtensions   /FeatureName:IIS-ISAPIFilter   /FeatureName:IIS-LegacyScripts   /FeatureName:IIS-LegacySnapIn   /FeatureName:IIS-LoggingLibraries   /FeatureName:IIS-ManagementConsole   /FeatureName:IIS-ManagementScriptingTools   /FeatureName:IIS-ManagementService   /FeatureName:IIS-Metabase   /FeatureName:IIS-NetFxExtensibility   /FeatureName:IIS-ODBCLogging   /FeatureName:IIS-Performance   /FeatureName:IIS-RequestFiltering   /FeatureName:IIS-RequestMonitor   /FeatureName:IIS-Security   /FeatureName:IIS-ServerSideIncludes   /FeatureName:IIS-StaticContent   /FeatureName:IIS-URLAuthorization   /FeatureName:IIS-WebDAV   /FeatureName:IIS-WebServer   /FeatureName:IIS-WebServerManagementTools   /FeatureName:IIS-WebServerRole   /FeatureName:IIS-WindowsAuthentication   /FeatureName:IIS-WMICompatibility   /FeatureName:WAS-ConfigurationAPI   /FeatureName:WAS-NetFxEnvironment   /FeatureName:WAS-ProcessModel   /FeatureName:WAS-WindowsActivationService
 

安装.net4.5
dism /online /enable-feature /featurename:IIS-ISAPIFilter
dism /online /enable-feature /featurename:IIS-ISAPIExtensions
dism /online /enable-feature /featurename:IIS-NetFxExtensibility45
完成后再次运行“dism /online /enable-feature /featurename:IIS-ASPNET45”,成功。

查看windows 功能:

dism /online /Get-Features

各种开发工具下载网站:

http://msdn.itellyou.cn/

你可能感兴趣的:(Windows)