0

Getting this issue while i am Deploy my Asp.net core app on bluemix.

Hosting Provider is Bluemix.

Logs:

Downloading artifacts...DOWNLOAD SUCCESSFUL Target:
https://api.ng.bluemix.net Using manifest file
/home/pipeline/cb3f3db1-2e27-4c5a-a1f4-e5b8f9ada7f6/manifest.yml

Updating app myproject01 in org myproject_org / space Dev as xyz@gmail.com...

            OK

            Using route myproject01.mybluemix.net
            Uploading myproject01...
            Uploading app files from: /home/pipeline/cb3f3db1-2e27-4c5a-a1f4-e5b8f9ada7f6
            Uploading 14.7M, 2061 files


            Done uploading
            OK
            Binding service myproject01-cloudantNoSQLDB to app myproject01 in org myproject_org / space Dev as katoch.rohit@gmail.com...
            OK

            Stopping app myproject01 in org myproject_org / space Dev as katoch.rohit@gmail.com...
            OK

            Starting app myproject01 in org myproject_org / space Dev as katoch.rohit@gmail.com...
            -----> Downloaded app package (56M)
            ASP.NET Core buildpack version: v0.9-20160706-1603
            ASP.NET Core buildpack starting compile
            -----> Restoring files from buildpack cache
                   Copied 199 files from /tmp/cache/.dotnet to /tmp/staged/app
                   Copied 14925 files from /tmp/cache/.nuget to /tmp/staged/app
                   Copied 37 files from /tmp/cache/libunwind to /tmp/staged/app
                   OK
            -----> Extracting libunwind
                   OK
            -----> Installing Dotnet CLI
                   OK
            -----> Restoring dependencies with Dotnet CLI
                   log  : Restoring packages for /tmp/staged/app/src/myproject.Utility/project.json...
                   log  : Restoring packages for /tmp/staged/app/src/myproject.Core/project.json...
                   log  : Restoring packages for /tmp/staged/app/src/dotnetCloudantWebstarter/project.json...
                   log  : Restoring packages for /tmp/staged/app/project.json...
                   log  : Writing lock file to disk. Path: /tmp/staged/app/src/myproject.Utility/project.lock.json
                   log  : Writing lock file to disk. Path: /tmp/staged/app/src/myproject.Core/project.lock.json
                   log  : src/myproject.Utility/project.json
                   log  : Restore completed in 1752ms.
                   log  : src/myproject.Core/project.json
                   log  : Restore completed in 1753ms.
                   log  : ./project.json
                   log  : Restore completed in 2036ms.
                   log  : Restoring packages for tool 'Microsoft.AspNetCore.Server.IISIntegration.Tools' in /tmp/staged/app/src/dotnetCloudantWebstarter/project.json...

                   warn :  dotnetCloudantWebstarter (>= 1.0.0) -> System.Threading.Tasks.Extensions (>= 4.0.0-rc2-24027)
                   log  : Writing lock file to disk. Path: /tmp/staged/app/src/dotnetCloudantWebstarter/project.lock.json
                   log  : src/dotnetCloudantWebstarter/project.json
                   log  : Restore completed in 4439ms.
                   OK
            -----> Saving to buildpack cache
                   Copied 0 files from /tmp/staged/app/.dotnet to /tmp/cache
                   Copied 0 files from /tmp/staged/app/.nuget to /tmp/cache
            ASP.NET Core buildpack is done creating the droplet

            -----> Uploading droplet (270M)

            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 down
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            0 of 1 instances running, 1 starting
            FAILED
            Start app timeout

            TIP: Application must be listening on the right port. Instead of hard coding the port, use the $PORT environment variable.

            Use 'cf logs myproject01 --recent' for more information

            Finished: FAILED

plz help me out to get rid of this issue.....

Thanks.

Michael Benjamin
  • 346,931
  • 104
  • 581
  • 701
  • can you share your project.json – lazy Aug 31 '16 at 16:58
  • Can you share the code from your project's `Main` method as well as the project.json? – Daniel Grim Aug 31 '16 at 17:13
  • project.json: { "version": "1.0.0-*", "buildOptions": { "emitEntryPoint": true }, "dependencies": { "Microsoft.NETCore.App": { "type": "platform", "version": "1.0.0-rc2-3002702" } }, "frameworks": { "netcoreapp1.0": { "imports": "dnxcore50" } } } – Harmeet Singh Aug 31 '16 at 17:15
  • public static void Main(string[] args) { var config = new ConfigurationBuilder() .AddCommandLine(args).Build(); var host = new WebHostBuilder().UseKestrel() .UseConfiguration(config) .UseStartup() .Build(); host.Run(); } – Harmeet Singh Aug 31 '16 at 17:17
  • Earlier it was Working Fine...just getting for last 2 days.. – Harmeet Singh Aug 31 '16 at 17:17
  • Can you add to your question output of `cf logs myproject01 --recent` ? – Alex da Silva Aug 31 '16 at 17:31
  • @alex Logs are mentioned above.. – Harmeet Singh Aug 31 '16 at 17:39
  • No, you have the output of the `cf push` command. You look at the very end it says "Use 'cf logs myproject01 --recent' for more information" and that is what I am asking. It will show logs from your application as well and you may be able to see why it fails to start. – Alex da Silva Aug 31 '16 at 17:42
  • @alex full logs are here https://docs.google.com/document/d/1HivbawfpLGdHSUo78h2XH9VG0S6OlrFo7s3-9ODPlhg/edit – Harmeet Singh Aug 31 '16 at 17:55
  • @alex u need same thing? – Harmeet Singh Aug 31 '16 at 17:56
  • @HarmeetSingh it seems like you have some dependency conflicts here: /home/vcap/app/src/dotnetCloudantWebstarter/project.json(23,41): warning NU1012: Dependency conflict. NETStandard.Library 1.6.0 expected System.Net.Http >= 4.1.0 but got 4.0.1-rc2-24027. I would make sure you update all of your references in all projects in the solution to target the 1.0.0 runtime rather than RC2. Can you post the project.json files for the other projects in the solution, and place them in an edit to the question itself? – Daniel Grim Aug 31 '16 at 17:57
  • @DanielGrim i have these warnings earlier too, but it was runnning fine...see success log: https://docs.google.com/document/d/1V8xVClRojH0QuG32zowT7RyMP-DocgoXJNgUtFm5T7Q/edit?usp=sharing – Harmeet Singh Aug 31 '16 at 18:07
  • Hey @HarmeetSingh! could you find the solution? I am facing the same issue. Could you please tell me the reason and solution of this? – Amrendra Mar 08 '17 at 06:57

1 Answers1

0

The current versions the boilerplates for ASP.NET Core in Bluemix have had their default memory limits increased to 512MB, but it seems that your application was based on an older version of those boilerplates which had the limit set to 256MB.

While this is enough for a basic "Hello World" style of application, once you start adding more functionality to the application it will need more memory at some point and not having enough memory will cause it to crash.

Increasing the memory limit to 512MB may fix the issues that you're having, but I would also start taking care of the warning messages that you're getting about package version mismatches too before that causes other issues. Pulling packages from both RC2 and RTM in the same application can be problematic when things have changed in the RTM version that your code is trying to call but the package that gets installed is from RC2.

Daniel Grim
  • 2,261
  • 19
  • 22
  • I increased MEMORY QUOTA 256 to 512mb per Instance in Buemixx dashboard but still same error. – Harmeet Singh Aug 31 '16 at 18:45
  • how to do this in .net core? http://stackoverflow.com/questions/29542452/i-am-having-trouble-starting-my-node-app-in-bluemix if it is port issue.. – Harmeet Singh Aug 31 '16 at 20:24
  • The code that you posted from your `Main` method should already be setting the proper port because it is passing the command-line parameters to Kestrel to configure it. – Daniel Grim Sep 01 '16 at 10:23