

# Troubleshooting access to transaction log backups
<a name="USER.SQLServer.AddlFeat.TransactionLogAccess.Troubleshooting"></a>

The following are issues you might encounter when you use the stored procedures for access to transaction log backups.


****  

| Stored Procedure | Error Message | Issue | Troubleshooting suggestions | 
| --- | --- | --- | --- | 
| rds\_tlog\_copy\_setup | Backups are disabled on this DB instance. Enable DB instance backups with a retention of at least "1" and try again. | Automated backups are not enabled for the DB instance. |  DB instance backup retention must be enabled with a retention of at least one day. For more information on enabling automated backups and configuring backup retention, see [Backup retention period](USER_WorkingWithAutomatedBackups.BackupRetention.md).  | 
| rds\_tlog\_copy\_setup | Error running the rds\_tlog\_copy\_setup stored procedure. Reconnect to the RDS endpoint and try again. | An internal error occurred. | Reconnect to the RDS endpoint and run the `rds_tlog_copy_setup` stored procedure again. | 
| rds\_tlog\_copy\_setup | Running the rds\_tlog\_backup\_copy\_setup stored procedure inside a transaction is not supported. Verify that the session has no open transactions and try again.  | The stored procedure was attempted within a transaction using `BEGIN` and `END`. | Avoid using `BEGIN` and `END` when running the `rds_tlog_copy_setup` stored procedure. | 
| rds\_tlog\_copy\_setup | The S3 bucket name for the input parameter `@target_s3_arn` should contain at least one character other than a space.  | An incorrect value was provided for the input parameter `@target_s3_arn`. | Ensure the input parameter `@target_s3_arn` specifies the complete Amazon S3 bucket ARN. | 
| rds\_tlog\_copy\_setup | The `SQLSERVER_BACKUP_RESTORE` option isn't enabled or is in the process of being enabled. Enable the option or try again later.  | The `SQLSERVER_BACKUP_RESTORE` option is not enabled on the DB instance or was just enabled and pending internal activation. | Enable the `SQLSERVER_BACKUP_RESTORE` option as specified in the Requirements section. Wait a few minutes and run the `rds_tlog_copy_setup` stored procedure again. | 
| rds\_tlog\_copy\_setup | The target S3 arn for the input parameter `@target_s3_arn` can't be empty or null.  | An `NULL` value was provided for the input parameter `@target_s3_arn`, or the value wasn't provided. | Ensure the input parameter `@target_s3_arn` specifies the complete Amazon S3 bucket ARN. | 
| rds\_tlog\_copy\_setup | The target S3 arn for the input parameter `@target_s3_arn` must begin with arn:aws.  | The input parameter `@target_s3_arn` was provide without `arn:aws` on the front. | Ensure the input parameter `@target_s3_arn` specifies the complete Amazon S3 bucket ARN. | 
| rds\_tlog\_copy\_setup | The target S3 ARN is already set to the provided value.  | The `rds_tlog_copy_setup` stored procedure previously ran and was configured with an Amazon S3 bucket ARN. | To modify the Amazon S3 bucket value for access to transaction log backups, provide a different `target S3 ARN`. | 
| rds\_tlog\_copy\_setup | Unable to generate credentials for enabling Access to Transaction Log Backups. Confirm the S3 path ARN provided with `rds_tlog_copy_setup`, and try again later.  | There was an unspecified error while generating credentials to enable access to transaction log backups. | Review your setup configuration and try again.  | 
| rds\_tlog\_copy\_setup | You cannot run the rds\_tlog\_copy\_setup stored procedure while there are pending tasks. Wait for the pending tasks to complete and try again.  | Only two tasks may run at any time. There are pending tasks awaiting completion. | View pending tasks and wait for them to complete. For more information on monitoring task status, see [Tracking the status of tasks](USER.SQLServer.AddlFeat.TransactionLogAccess.TrackTaskStatus.md).  | 
| rds\_tlog\_backup\_copy\_to\_S3 | A T-log backup file copy task has already been issued for database: %s with task Id: %d, please try again later.  | Only one copy task may run at any time for a given database. There is a pending copy task awaiting completion. | View pending tasks and wait for them to complete. For more information on monitoring task status, see [Tracking the status of tasks](USER.SQLServer.AddlFeat.TransactionLogAccess.TrackTaskStatus.md).  | 
| rds\_tlog\_backup\_copy\_to\_S3 | At least one of these three parameter sets must be provided. SET-1:(@backup\_file\_start\_time, @backup\_file\_end\_time) \| SET-2:(@starting\_lsn, @ending\_lsn) \| SET-3:(@rds\_backup\_starting\_seq\_id, @rds\_backup\_ending\_seq\_id)  | None of the three parameter sets were provided, or a provided parameter set is missing a required parameter. | You can specify either the time, lsn, or sequence ID parameters. One set from these three sets of parameters are required. For more information on required parameters, see [Copying transaction log backups](USER.SQLServer.AddlFeat.TransactionLogAccess.Copying.md). | 
| rds\_tlog\_backup\_copy\_to\_S3 | Backups are disabled on your instance. Please enable backups and try again in some time. | Automated backups are not enabled for the DB instance. |  For more information on enabling automated backups and configuring backup retention, see [Backup retention period](USER_WorkingWithAutomatedBackups.BackupRetention.md).  | 
| rds\_tlog\_backup\_copy\_to\_S3 | Cannot find the given database %s.  | The value provided for input parameter `@db_name` does not match a database name on the DB instance. | Use the correct database name. To list all databases by name, run `SELECT * from sys.databases` | 
| rds\_tlog\_backup\_copy\_to\_S3 | Cannot run the rds\_tlog\_backup\_copy\_to\_S3 stored procedure for SQL Server system databases or the rdsadmin database.  | The value provided for input parameter `@db_name` matches a SQL Server system database name or the RDSAdmin database. | The following databases are not allowed to be used with access to transaction log backups: `master, model, msdb, tempdb, RDSAdmin.`  | 
| rds\_tlog\_backup\_copy\_to\_S3 | Database name for the input parameter @db\_name can't be empty or null.  | The value provided for input parameter `@db_name` was empty or `NULL`. | Use the correct database name. To list all databases by name, run `SELECT * from sys.databases` | 
| rds\_tlog\_backup\_copy\_to\_S3 | DB instance backup retention period must be set to at least 1 to run the rds\_tlog\_backup\_copy\_setup stored procedure.  | Automated backups are not enabled for the DB instance. | For more information on enabling automated backups and configuring backup retention, see [Backup retention period](USER_WorkingWithAutomatedBackups.BackupRetention.md). | 
| rds\_tlog\_backup\_copy\_to\_S3 | Error running the stored procedure rds\_tlog\_backup\_copy\_to\_S3. Reconnect to the RDS endpoint and try again.  | An internal error occurred. | Reconnect to the RDS endpoint and run the `rds_tlog_backup_copy_to_S3` stored procedure again. | 
| rds\_tlog\_backup\_copy\_to\_S3 | Only one of these three parameter sets can be provided. SET-1:(@backup\_file\_start\_time, @backup\_file\_end\_time) \| SET-2:(@starting\_lsn, @ending\_lsn) \| SET-3:(@rds\_backup\_starting\_seq\_id, @rds\_backup\_ending\_seq\_id)  | Multiple parameter sets were provided. | You can specify either the time, lsn, or sequence ID parameters. One set from these three sets of parameters are required. For more information on required parameters, see [Copying transaction log backups](USER.SQLServer.AddlFeat.TransactionLogAccess.Copying.md).  | 
| rds\_tlog\_backup\_copy\_to\_S3 | Running the rds\_tlog\_backup\_copy\_to\_S3 stored procedure inside a transaction is not supported. Verify that the session has no open transactions and try again.  | The stored procedure was attempted within a transaction using `BEGIN` and `END`. | Avoid using `BEGIN` and `END` when running the `rds_tlog_backup_copy_to_S3` stored procedure. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The provided parameters fall outside of the transaction backup log retention period. To list of available transaction log backup files, run the rds\_fn\_list\_tlog\_backup\_metadata function. | There are no available transactional log backups for the provided input parameters that fit in the copy retention window. | Try again with a valid set of parameters. For more information on required parameters, see [Copying transaction log backups](USER.SQLServer.AddlFeat.TransactionLogAccess.Copying.md). | 
| rds\_tlog\_backup\_copy\_to\_S3 | There was a permissions error in processing the request. Ensure the bucket is in the same Account and Region as the DB Instance, and confirm the S3 bucket policy permissions against the template in the public documentation. | There was an issue detected with the provided S3 bucket or its policy permissions. | Confirm your setup for access to transaction log backups is correct. For more information on setup requirements for your S3 bucket, see [Requirements](USER.SQLServer.AddlFeat.TransactionLogAccess.md#USER.SQLServer.AddlFeat.TransactionLogAccess.Requirements). | 
| rds\_tlog\_backup\_copy\_to\_S3 | Running the `rds_tlog_backup_copy_to_S3` stored procedure on an RDS read replica instance isn't permitted.  | The stored procedure was attempted on a RDS read replica instance. | Connect to the RDS primary DB instance to run the `rds_tlog_backup_copy_to_S3` stored procedure. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The LSN for the input parameter `@starting_lsn` must be less than `@ending_lsn`.  | The value provided for input parameter `@starting_lsn` was greater than the value provided for input parameter `@ending_lsn`. | Ensure the value provided for input parameter `@starting_lsn` is less than the value provided for input parameter `@ending_lsn`. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The `rds_tlog_backup_copy_to_S3` stored procedure can only be performed by the members of `db_owner` role in the source database.  | The `db_owner` role has not been granted for the account attempting to run the `rds_tlog_backup_copy_to_S3` stored procedure on the provided `db_name`. | Ensure the account running the stored procedure is permissioned with the `db_owner` role for the provided `db_name`. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The sequence ID for the input parameter `@rds_backup_starting_seq_id` must be less than or equal to `@rds_backup_ending_seq_id`.  | The value provided for input parameter `@rds_backup_starting_seq_id` was greater than the value provided for input parameter `@rds_backup_ending_seq_id`. | Ensure the value provided for input parameter `@rds_backup_starting_seq_id` is less than the value provided for input parameter `@rds_backup_ending_seq_id`. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The SQLSERVER\_BACKUP\_RESTORE option isn't enabled or is in the process of being enabled. Enable the option or try again later.  | The `SQLSERVER_BACKUP_RESTORE` option is not enabled on the DB instance or was just enabled and pending internal activation. | Enable the `SQLSERVER_BACKUP_RESTORE` option as specified in the Requirements section. Wait a few minutes and run the `rds_tlog_backup_copy_to_S3` stored procedure again. | 
| rds\_tlog\_backup\_copy\_to\_S3 | The start time for the input parameter `@backup_file_start_time` must be less than `@backup_file_end_time`.  | The value provided for input parameter `@backup_file_start_time` was greater than the value provided for input parameter `@backup_file_end_time`. | Ensure the value provided for input parameter `@backup_file_start_time` is less than the value provided for input parameter `@backup_file_end_time`. | 
| rds\_tlog\_backup\_copy\_to\_S3 | We were unable to process the request due to a lack of access. Please check your setup and permissions for the feature.  | There may be an issue with the Amazon S3 bucket permissions, or the Amazon S3 bucket provided is in another account or Region. | Ensure the Amazon S3 bucket policy permissions are permissioned to allow RDS access. Ensure the Amazon S3 bucket is in the same account and Region as the DB instance. | 
| rds\_tlog\_backup\_copy\_to\_S3 | You cannot provide a KMS Key ARN as input parameter to the stored procedure for instances that are not storage-encrypted.  | When storage encryption is not enabled on the DB instance, the input parameter `@kms_key_arn` should not be provided. | Do not provide an input parameter for `@kms_key_arn`. | 
| rds\_tlog\_backup\_copy\_to\_S3 | You must provide a KMS Key ARN as input parameter to the stored procedure for storage encrypted instances.  | When storage encryption is enabled on the DB instance, the input parameter `@kms_key_arn` must be provided. | Provide an input parameter for `@kms_key_arn` with a value that matches the ARN of the Amazon S3 bucket to use for transaction log backups. | 
| rds\_tlog\_backup\_copy\_to\_S3 | You must run the `rds_tlog_copy_setup` stored procedure and set the `@target_s3_arn`, before running the `rds_tlog_backup_copy_to_S3` stored procedure.  | The access to transaction log backups setup procedure was not completed before attempting to run the `rds_tlog_backup_copy_to_S3` stored procedure. | Run the `rds_tlog_copy_setup` stored procedure before running the `rds_tlog_backup_copy_to_S3` stored procedure. For more information on running the setup procedure for access to transaction log backups, see [Setting up access to transaction log backups](USER.SQLServer.AddlFeat.TransactionLogAccess.Enabling.md).  | 