Upgrade Failed - Error: FailedThe PAK action "apply_adapter_post_script"
search cancel

Upgrade Failed - Error: FailedThe PAK action "apply_adapter_post_script"

book

Article ID: 375595

calendar_today

Updated On:

Products

VMware Aria Suite

Issue/Introduction

Upgrade failed on Stage 12 of 14, vSphere Management Pack phase.

Environment

Aria Operations 8.17

Aria Operations 8.16

Cause

An issue with API call failure in Aria Operations. Alert Plugin of PluginType "Actions" is not enabled.

Error from /storage/log/vcops/log/pakManager/VMwarevSphere-<build-number>/apply_adapter_post_script_stdout.log

Configuring Actions Plugin for Alert processing
Beginning configuration of Actions Alert Plugin
Making get call to see if the plugin is already configured
{'notificationPluginInstances': []}
action not configured, adding plugin now
Ready to make post request to install Actions Alert Plugin
Invalid http response from Post request status code: [500]
Plugin did not get configured 

 

Error from /storage/log/vcops/log/api.log:

2024-08-08T19:12:56,425+0000 INFO [ajp-nio-127.0.0.1-8010-exec-6, hJCl9lZrCG9jOfZTz3RHsRkfKJzSjTJw] server.config.ThrottleFilter - Allowing POST /alertplugins
2024-08-08T19:12:56,515+0000 INFO [ajp-nio-127.0.0.1-8010-exec-6, hJCl9lZrCG9jOfZTz3RHsRkfKJzSjTJw] service.impl.ControllerFacadeFactory$ControllerFacadeInvocationHandler - Controller API call 'PlatformExecutor.createNotificationPlugin' landed on Node: VMware Aria Operations Cluster Node
2024-08-08T19:12:56,515+0000 ERROR [ajp-nio-127.0.0.1-8010-exec-6, hJCl9lZrCG9jOfZTz3RHsRkfKJzSjTJw] service.impl.DefaultNotificationService - No plugin returned in API Result object after create.
2024-08-08T19:12:56,524+0000 ERROR [ajp-nio-127.0.0.1-8010-exec-6, hJCl9lZrCG9jOfZTz3RHsRkfKJzSjTJw] server.controller.AbstractBaseController - ServiceException caught before sending response.
com.vmware.ops.api.common.exceptions.Exceptions$ServiceException: Internal Server error, cause unknown.
        at com.vmware.ops.api.common.exceptions.Exceptions.mkInternalServerEx(Exceptions.java:96) ~[platform-api-common-1.70.jar:?]
        at com.vmware.ops.api.server.service.impl.DefaultNotificationService.createNotificationPlugin(DefaultNotificationService.java:257) ~[classes/:?]
        at com.vmware.ops.api.server.controller.AlertPluginControllers$AlertPluginController.createAlertPlugin(AlertPluginControllers.java:153) ~[classes/:?]

 

Resolution

Before trying any changes in the Aria Operations instance,  take snapshots as referred on KB  How to take a Snapshot of VMware Aria Operations

Perform the following steps on Suite-API UI to enable the Alert Plugin "Action"

 

1-  Access the Aria Operations swagger by using this link  https://vrops_primary-node_fqdn_or_ip/suite-api

2-  Click the Authorize button to authenticate and enter Admin credentials.

3-  Search in the swagger for the use  GET /api/alertplugins

Click  the "Try it out"  button

 

Set the "PluginTypeId" field to "Actions", Then click the execute button as per image below

 

 
 
The example output below shows the response for when the plugin is present but not enabled:

{
  "notificationPluginInstances": [
    {
      "pluginTypeId": "Actions",
      "pluginId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "name": "Automated Actions",
      "description": "Automated Actions",
      "version": xxxxxxxxxxxxx,
      "enabled": false,
      "configValues": []
    }
  ]
}

 

Note:

If the plugin is absent, continue to step 4. (If this is the case, the response from the previous call will be empty)

If the plugin is present, you can go to step 5. 

 

4-  Create/install the plugin using the following POST call:

POST /api​/alertplugins

with the body of the POST set to:

{
    "pluginTypeId": "Actions",
    "pluginId": null,
    "name": "Automated Actions",
    "description": "Automated Actions",
    "version": 0,
    "configValues": []
}

 

 

Click the Execute button.

 

5- Now retry the call from Step 3 to confirm that the Actions plugin has been created/installed. Take note of the "pluginId" detailed in the response.

6-  Use the following PUT call to activate/enable the Actions Plugin - PUT /api/alertplugins/{pluginId}/enable/{enabled}

     Set the "enabled" field to "true"

     Add the "pluginId" value from step 5 to the "pluginId" field