Pivotal Knowledge Base


How to test the Loggregator connection for Apps Manager


Product Version
Pivotal Cloud Foundry® (PCF) 1.6.x


Recent logs and events aren’t appearing in the Apps Manager. Current logs are visible in the Apps Manager and recent logs are visible when tailing them in the CLI.  This article will explain how to test the Loggregator connection.


Current logs are sent to the Apps Manager via WebSockets; recent logs and events are sent via HTTP. This could be the external Load Balancer, a proxy, a firewall, or just that blocked HTTP connections are blocked in the environment.


To get started, we will check to see if we can connect to the Loggregator component over HTTP:

After performing the `curl` command above, you will more than likely see the command hang. If it's not hanging and instead you have received a 404 response, then your loggregator connection is good and your issue is being caused by something else. Since the command is probably hung, continue troubleshooting following the steps below:

  • Make sure you’re logged in as the UAA admin per the instructions earlier and target the apps-manager space. You will also need the CF_LOGGREGATOR_HTTP_URL from earlier.
  • Run `cf app <RUNNING APPS MANAGER> --guid` to get the running Apps Manager guid. Save this guid.
  • Run `cf oauth-token` to get the OAuth token for your current session. You will need this for the next step.
  • Run `cf ssh <RUNNING APPS MANAGER>` to ssh into your Apps Manager container.
  • Run `curl -H ‘Authorization: <cf oauth-token OUTPUT HERE>’ -vv http://loggregator.system.deschutes.mini.pez.pivotal.io/recent?app=<app-guid>`
  • If you see entries that look like logs, then you have a HTTP Loggregator connection. If you don’t, then your Apps Manager does not have a connection to the Loggregator.
    • Example of output:
healthcheck passed�ꬼ��۸("$14407c52-966d-4341-abd3-aa01d86f1c1420BHEALTH

Exit status 0��Ͽ��۸("$14407c52-966d-4341-abd3-aa01d86f1c1420BHEALTH --d804777b9d088c0ea297de2753bc69de6fa2cd50860987a649b1e2d7ffb6
.Successful remote access by������۸("$14407c52-966d-4341-abd3-aa01d86f1c1420BSSH --d804777b9d088c0ea297de2753bc69de6fa2cd50860987a649b1e2d7ffb6

 If your output looks like that, then the loggregator is working. However, the connection to the apps manager is being blocked, which is why recent logs aren’t appearing in Apps manager but do when you run `cf logs` in the CLI.


Powered by Zendesk