我做了什么:
1,创建了一个新的Mvc应用程序项目。
2,使用Visual Studio构建部署包
3,在命令行中运行此命令
C:\TEMP\packages\MvcApplication6.deploy.cmd /t
它与此输出崩溃
C:\Users\Fabik>C:\TEMP\packages\MvcApplication6.deploy.cmd /t
=========================================================
SetParameters from:
"C:\TEMP\packages\MvcApplication6.SetParameters.xml"
You can change IIS Application Name, Physical path, connectionString
or other deploy parameters in the above file.
-------------------------------------------------------
Start executing msdeploy.exe
-------------------------------------------------------
"C:\Program Files\IIS\Microsoft Web Deploy V3\\msdeploy.exe" -source:package='C
:\TEMP\packages\MvcApplication6.zip' -dest:auto,includeAcls='False' -verb:sync -
disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:Certific
ateExtension -setParamFile:"C:\TEMP\packages\MvcApplication6.SetParameters.xml"
-whatif
Unhandled Exception: System.Configuration.ConfigurationErrorsException: Configur
ation system failed to initialize ---> System.Configuration.ConfigurationErrorsE
xception: Unrecognized configuration section startup. (C:\Program Files\IIS\Micr
osoft Web Deploy V3\msdeploy.exe.Config line 2)
at System.Configuration.ConfigurationSchemaErrors.ThrowIfErrors(Boolean ignor
eLocal)
at System.Configuration.BaseConfigurationRecord.ThrowIfParseErrors(Configurat
ionSchemaErrors schemaErrors)
at System.Configuration.ClientConfigurationSystem.EnsureInit(String configKey
)
--- End of inner exception stack trace ---
at System.Configuration.ClientConfigurationSystem.EnsureInit(String configKey
)
at System.Configuration.ClientConfigurationSystem.System.Configuration.Intern
al.IInternalConfigSystem.GetSection(String sectionName)
at System.Configuration.ConfigurationManager.GetSection(String sectionName)
at System.Configuration.PrivilegedConfigurationManager.GetSection(String sect
ionName)
at System.Diagnostics.DiagnosticsConfiguration.Initialize()
at System.Diagnostics.TraceInternal.InitializeSettings()
at System.Diagnostics.TraceInternal.get_Listeners()
at System.Diagnostics.Trace.get_Listeners()
at MSDeploy.CommandLineTraceListener.EnableCommandLineTraceListeners()
at MSDeploy.MSDeploy.Main(String[] unusedArgs)
当我使用IIS管理器导入包时,它工作正常。可能是什么问题呢 ? 我正在使用Visual Studio 2010
答案 0 :(得分:0)
该错误消息看起来像.NET 2 CLR正在执行msdeploy.exe。尝试(重新)安装.NET 4.0 Full Profile。