

# Troubleshooting Amazon Systems Manager Distributor
<a name="distributor-troubleshooting"></a>

The following information can help you troubleshoot problems that might occur when you use Distributor.

**Topics**
+ [Wrong package with the same name is installed](#distributor-tshoot-1)
+ [Error: Failed to retrieve manifest: Could not find latest version of package](#distributor-tshoot-2)
+ [Error: Failed to retrieve manifest: Validation exception](#distributor-tshoot-3)
+ [Package isn't supported (package is missing install action)](#distributor-tshoot-4)
+ [Error: Failed to download manifest : Document with name does not exist](#distributor-tshoot-5)
+ [Upload failed.](#distributor-tshoot-6)
+ [Error: Failed to find platform: no manifest found for platform: oracle, version 8.9, architecture x86\_64](#distributor-tshoot-7)

## Wrong package with the same name is installed
<a name="distributor-tshoot-1"></a>

**Problem:** You've installed a package, but Distributor installed a different package instead.

**Cause:** During installation, Systems Manager finds Amazon published packages as results before user-defined external packages. If your user-defined package name is the same as an Amazon published package name, the Amazon package is installed instead of your package.

**Solution:** To avoid this problem, name your package something different from the name for an Amazon published package.

## Error: Failed to retrieve manifest: Could not find latest version of package
<a name="distributor-tshoot-2"></a>

**Problem:** You received an error like the following.

```
Failed to retrieve manifest: ResourceNotFoundException: Could not find the latest version of package 
arn:aws-cn:ssm:::package/{{package-name}} status code: 400, request id: {{guid}}
```

**Cause:** You're using a version of SSM Agent with Distributor that is earlier than version 2.3.274.0.

**Solution:** Update the version of SSM Agent to version 2.3.274.0 or later. For more information, see [Updating the SSM Agent using Run Command](run-command-tutorial-update-software.md#rc-console-agentexample) or [Walkthrough: Automatically update SSM Agent with the Amazon CLI](state-manager-update-ssm-agent-cli.md).

## Error: Failed to retrieve manifest: Validation exception
<a name="distributor-tshoot-3"></a>

**Problem:** You received an error like the following.

```
Failed to retrieve manifest: ValidationException: 1 validation error detected: Value 'documentArn'
at 'packageName' failed to satisfy constraint: Member must satisfy regular expression pattern:
arn:aws-cn:ssm:{{region-id}}:{{account-id}}:package/{{package-name}}
```

**Cause:** You're using a version of SSM Agent with Distributor that is earlier than version 2.3.274.0.

**Solution:** Update the version of SSM Agent to version 2.3.274.0 or later. For more information, see [Updating the SSM Agent using Run Command](run-command-tutorial-update-software.md#rc-console-agentexample) or [Walkthrough: Automatically update SSM Agent with the Amazon CLI](state-manager-update-ssm-agent-cli.md).

## Package isn't supported (package is missing install action)
<a name="distributor-tshoot-4"></a>

**Problem:** You received an error like the following.

```
Package is not supported (package is missing install action)
```

**Cause:** The package directory structure is incorrect.

**Solution:** Don't zip a parent directory containing the software and required scripts. Instead, create a `.zip` file of all the required contents directly in the absolute path. To verify the `.zip` file was created correctly, unzip the target platform directory and review the directory structure. For example, the install script absolute path should be `/{{ExamplePackage_targetPlatform}}/install.sh`.

## Error: Failed to download manifest : Document with name does not exist
<a name="distributor-tshoot-5"></a>

**Problem:** You received an error like the following. 

```
Failed to download manifest - failed to retrieve package document description: InvalidDocument: Document with name {{filename}} does not exist.
```

**Cause 1:** Distributor can't find the package by the package name when sharing a Distributor package from another account.

**Solution 1:** When sharing a package from another account, use the full Amazon Resource Name (ARN) for the package and not just its name.

**Cause 2:** When using a VPC, you haven't provided your IAM instance profile with access to the Amazon managed S3 bucket that contains the document `AWS-ConfigureAWSPackage` for the Amazon Web Services Region you are targeting.

**Solution 2:** Make sure that your IAM instance profile provides SSM Agent with access to the Amazon managed S3 bucket that contains the document `AWS-ConfigureAWSPackage` for the Amazon Web Services Region you are targeting, as explained in [SSM Agent communications with Amazon managed S3 buckets](ssm-agent-technical-details.md#ssm-agent-minimum-s3-permissions).

## Upload failed.
<a name="distributor-tshoot-6"></a>

**Problem:** You received an error like the following. 

```
Upload failed. At least one of your files was not successfully uploaded to your S3 bucket.
```

**Cause:** The name of your software package includes a space. For example, `Hello World.msi` would fail to upload.

## Error: Failed to find platform: no manifest found for platform: oracle, version 8.9, architecture x86\_64
<a name="distributor-tshoot-7"></a>

**Problem:** You received an error like the following.

```
Failed to find platform: no manifest found for platform: oracle, version 8.9, architecture x86_64
```

**Cause:** The error means that the JSON package manifest does not have any definition for that platform, in this case, Oracle Linux..

**Solution:** Download the package you want to distribute from the [Trend Micro Deep Security Software](https://help.deepsecurity.trendmicro.com/software.html) site. Create an `.rpm` software package using the [Create a package using the Simple workflow](distributor-working-with-packages-create.md#distributor-working-with-packages-create-simple). Set the following values for the package and complete the upload software package using Distributor:

```
Platform version: _any
Target platform: oracle
Architecture: x86_64
```