Uploading API Gateway patch fails due to "Could not write attachments" etc.
search cancel

Uploading API Gateway patch fails due to "Could not write attachments" etc.

book

Article ID: 42946

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

The upload of an API Gateway patch (Platform or Application) will fail with the following error at the console:

Runtime error (check configuration): Could not write attachments

OR

There was an error while uploading the patch.

OR

Permission denied

Environment

All supported versions of the API Gateway

Cause

  1. The permissions and/or ownership of a patch are not correct
  2. The API Gateway service daemon is not running
  3. There is insufficient space on a partition used by the Gateway patching subsystem

Resolution

Each cause has its own resolution. It is advisable to make sure of the following with regard to all three. 

Perform the following from the root shell prompt:

  1. Ensure that the Gateway service is running by executing the following command: #service ssg start
  2. Set the necessary ownership on all update files: #chown layer7. /home/ssgconfig/*.L7P
  3. Set the necessary permissions on all update files: #chmod 644 /home/ssgconfig/*.L7P
  4. Verify there is adequate disk space by executing one of the following commands
  7-series and older 8-series and newer
Command df -h | grep sda2 | awk '{print $6, $5}' df -Ph | egrep "/opt|/tmp" | awk '{print $6, $5}'

If any of the values exceed 75% then disk space should be freed. 


Each time a new patch is applied, there are status files created for them. They are found in /opt/SecureSpan/Controller/var/patches/ . To create space, you can remove all the status files but the latest CR and platform patch that you have applied.

You can also remove unnecessary L7P files from the directory where they are stored. By default, this should be /home/ssgconfig .

Additional Information

If any of the values exceed 75% then disk space should be freed.
 
You may also want to review the following articles: Article Id: 185399, Article Id: 44315 and Article Id: 42624