Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

add-env.sh did not successfully enable analytics

Hi everyone,

I have a few environments (dev, test, prod) running in my Apigee Private Cloud v4.15.04.03, all with analytics data working perfectly fine.

I went to create an additional environment today by ssh-ing into the management server VM and running the add-env.sh script. I entered all the prompted info correctly and it claims to have received an HTTP 201 from the API to enable analytics for the env.

At the very end of the add-env.sh script, it says that one can check the overall analytics status with two commands. When I run both commands, they each suggest that analytics has failed to be enabled.

\d analytics."fooBarOrg.fooBarEnv.fact"

Did not find any relation named "analytics."fooBarOrg.fooBarEnv.fact"".

^ i.e. the postgres tables were never created. Why?

<mgmt-svr>/v1/o/fooBarOrg/environments/fooBarEnv/provisioning/axstatus


{
  "environments": [
    {
      "components": [
        {
          "hosts": "[localhost, localhost]",
          "message": "success",
          "name": "qs",
          "status": "SUCCESS",
          "uuid": "[ea0c145b-fd45-4003-90ef-7c479a826634, c7ab40bb-d430-4987-b9d2-e38fdf1dea4b]"
        },
        {
          "hosts": "[localhost:localhost]",
          "message": "",
          "name": "pg",
          "status": "UNKNOWN",
          "uuid": "[ab38e06e-09b6-44a4-9b44-bbbfc282ceec:3d46f771-86c1-4449-959a-c4ad44a41ebb]"
        }
      ],
      "message": "",
      "name": "fooBarEnv"
    }
  ],
  "organization": "fooBarOrg",
  "status": "FAILURE"
}

^ i.e. the postgres server is in an UNKNOWN status and the analytics overall status is FAILURE. Why?

In the Management Server UI, I see this error in red when I browse to any of the pages while the fooBarEnv is selected in the top-right drop-down:

Error fetching analytics data Invalid API Call

I have followed the shell script prompts correctly. I even removed the env and re-tried it 3 times, just for good measure, and the same failure result occurs every time. I see errors in the postgres logs, but they seem to complain about the tables missing, which we already know from the postgres command above.

Does anyone have any idea how this could be happening? Thanks!

Best,

Chris

3 6 1,361
6 REPLIES 6
Top Solution Authors