The set of logs below is appearing every 20 seconds on my heroku app log.
heroku[web.1]: source=web.1 dyno=heroku.... sample#load_avg_1m=0.00
heroku[web.1]: source=web.1 dyno=heroku.... sample#memory_total=18.06MB sample#memory_rss=17.37MB sample#memory_cache=0.69MB sample#memory_swap=0.00MB sample#memory_pgpgin=7511pages sample#memory_pgpgout=2888pages sample#memory_quota=512.00MB
I've found out these are Runtime metrics logs (https://devcenter.heroku.com/articles/log-runtime-metrics), not error logs.
I've tried these commands to disable this function but it didn't make any sense.
$ heroku labs:disable log-runtime-metrics
$ heroku restart
$ git commit --allow-empty -m "Force Heroku build."
$ git push heroku master
I also checked my heroku labs feature conditions by the command below.
$ heroku labs
It says log-runtime-metrics is not activated.
I completely don't have any idea for the cause of this behavior.
Related
I've seen a couple of SO posts, and despite googleing and the heroku --help, I keep getting the same error
I've been working off of this:
https://devcenter.heroku.com/articles/heroku-postgres-import-export
$ heroku pg:backups:restore 'secure-file-location-url' DATABASE_URL --app heroku-app-name --confirm heroku-app-name
Starting restore of secure-file-location-url to postgresql-flat-47715... done
Use Ctrl-C at any time to stop monitoring progress; the backup will continue restoring.
Use heroku pg:backups to check progress.
Stop a running restore with heroku pg:backups:cancel.
Restoring... !
▸ An error occurred and the backup did not finish.
▸
▸ waiting for restore to complete
▸ pg_restore finished with errors
▸ waiting for download to complete
▸ download finished with errors
▸ please check the source URL and ensure it is publicly accessible
▸
▸ Run heroku pg:backups:info r018 for more details.
$ heroku pg:backups:info r018
› Error: Missing required flag:
› -a, --app APP app to run command against
› See more help with --help
My secure-file-location-url is a public Google Drive link, which I can access in an incognito browser window.
As discussed in the comments, your database dump is being hosted on Google Drive and the link you're providing goes to a viewer with a "download file" button.
Instead, you must provide a direct link to the file. The documentation recommends using Amazon S3.
I ran into this problem as well, how I solved it was by adding run to the Heroku CLI command. Formatted like so:
heroku pg:backups:restore '<signed url>' DATABASE_URL -a <your-application-name>
Literally, put DATABASE_URL in there and it will read it from your environment variables. If you try putting in the postgress address it will fail. Also, the application needs to be the last thing added to this command, order matters here.
If we deploy app normally on heroku-cli, we can easily see all the logs by using
$ heroku logs
But how can we check heroku logs if we have connected the heroku app with git repository, then we can't use heroku logs
Suppose I started a one-off process using this command:
heroku run:detached "node do-some-stuff.js" --app my-app
The output of the command is this:
/usr/local/heroku/lib/heroku/jsplugin.rb:108: warning: Insecure world writable dir /usr/local/bin in PATH, mode 040777
Running `node do-some-stuff.js` detached... up, run.3728
Use `heroku logs -p run.3728 -a my-app` to view the output.
I can heroku logs -p run.3728 -a my-app while the process is being run, however, when process has exited it outputs nothing. How do i view the logs for process that has finished?
If you using a logging plugin, just search for run.3728. For a short period of time, the logs will also still be in the heroku logs if you do heroku logs | grep run.3728
$heroku pgbackups:restore DATABASE "http://........heroku2.dump" --app myapp
! Internal server error.
! Run heroku status to check for known platform issues.
$heroku status
=== Heroku Status
Development: No known issues at this time.
Production: No known issues at this time.
$Heroku logs --app tcdemo
No entries specific to any of these commands. myapp.herokuapp.com comes up in the browser.
How can I find out the details of Heroku internal server error?
I am following this blog to upload a Dart app to Heroku and run it. I have gotten to the point where the app is successfully deployed to Heroku, but the app is not running. The following is from the Heroku logs:
2012-12-20T18:04:57+00:00 heroku[web.1]: Starting process with command `dart TestApp.dart`
2012-12-20T18:04:57+00:00 app[web.1]: bash: dart: command not found
2012-12-20T18:04:58+00:00 heroku[web.1]: Process exited with status 127
2012-12-20T18:04:58+00:00 heroku[web.1]: State changed from starting to crashed
The following is the contents of my Procfile
web: dart TestApp.dart
Can anyone point me towards a solution to this error?
You should have forgotten to add the buildpack to the config. See the getting started of Heroku Buildpack for Dart.
Basically, you have to use the following commands :
$> heroku create myapp_name -s cedar
$> heroku config:add BUILDPACK_URL=https://github.com/igrigorik/heroku-buildpack-dart.git
WARNING : With the last version of buildpack it seems dart command is no more in the PATH. A workaround is to use the full path in Procfile:
web: ./dart-sdk/bin/dart TestApp.dart