'Microsoft.AspNet.Server.Kestrel' does not contain a static 'Main' method suitab


I'm trying to run the latest <a href="https://github.com/aspnet/Home" rel="nofollow">Asp.Net 5 samples</a> (currently 1.0.0-rc1-update1) from powershell on Windows 10. I have the active and default DNX set as the CLR x86. I have run the dnu restore command against each of the 3 projects and this has completed without error.

If I run the command dnx run for the console sample this works fine. However, when I then run the command dnx web from within either of the web project's folders I get the error message;

'Microsoft.AspNet.Server.Kestrel' does not contain a static 'Main' method suitable for an entry point

The samples are pretty basic and so I assume it must be part of my dnx configuration. But why is this happening and how do I fix it?


The cause of the issue is a strange one actually but it looks like the dnu restore command is case-sensitive. I assume this has something to do with it having to run on Linux too but I'm not sure.

In powershell my current path was all lowercase but my folder structure wasn't. Whilst in webhello , if I ran the command cd ..\WebHello and then ran dnu restore, the restore worked fine and the dnx web command also then ran fine.

Interestingly, if I ran cd ..\webhello, the dnx web command still works fine.


  • using Moq in Asp.Net 5 with dnx50
  • Targeting Runtime for New MVC6 Project in VS 2015
  • Database-first EF7-beta7 dnx ef dbcontext scaffold command fails
  • sh '
  • Restoring deleted mysql database
  • How to capture enclosing scope in Runnable
  • How to replace TouchesBegan with UIGestureRecognizer
  • How to create a custom Powershell operator?
  • Asynchronous Sockets - Handling false socket.AcceptAsync values
  • Find longest path less than or equal to given value of an acyclic, directed graph in Python
  • Open Existing DB in MySQL WorkBench
  • C#: Import/Export Settings into/from a File
  • Does Apportable support to build library binary (.a/.so)?
  • How to set elevation color?
  • Best way to dynamically load an xml configuration file into a Flex4/Flash movie at runtime?
  • Selenium to click on a javascript button corresponding to a text
  • Jenkins: FATAL: Could not initialize class hudson.util.ProcessTree$UnixReflection
  • How can I speed up CURL tasks?
  • htaccess add www if not subdomain, if subdomain remove www
  • x64 applications using gdi+: what are the consequences on performance?
  • Do I need to reset a Perl hash index?
  • HTTP/2 streams vs HTTP/1.1 connections
  • PHP buffered output depending on server setting?
  • MVC3 Razor - ListBox pre-select not working
  • Switching to Release Build causes runtime error in Web Reference
  • Reading JSON from a file using C++ REST SDK (Casablanca)
  • FB SDK and cURL: Unknown SSL protocol error in connection to graph.facebook.com:443
  • How do I fake an specific browser client when using Java's Net library?
  • VS2008 Enable C++ Exception with SEH
  • Why winpcap requires both .lib and .dll to run?
  • QuartzCore.framework for Mono Develop
  • Apache 2.4 - remove | delete | uninstall
  • Run Powershell script from inside other Powershell script with dynamic redirection to file
  • Is there a mandatory requirement to switch app.yaml?
  • Benchmarking RAM performance - UWP and C#
  • Hits per day in Google Big Query
  • FormattedException instead of throw new Exception(string.Format(…)) in .NET
  • Linking SubReports Without LinkChild/LinkMaster
  • XCode 8, some methods disappeared ? ex: layoutAttributesClass() -> AnyClass
  • UserPrincipal.Current returns apppool on IIS