How to change Amazon AWS credentials in CubeBackup?


Someone in your organization may accidently remove the Amazon AWS IAM account used by CubeBackup to access the S3 bucket, or deactivate the Access keys of the IAM account. If this happens, CubeBackup will stop working since it cannot connect to the S3 bucket anymore.

Solution

1. Create a new IAM access key

Log into the Amazon AWS IAM console. Click the IAM user used to access S3 storage, then in the Security credentials page, click Create access key to generate another access key for this IAM user. Make sure that the Access key ID and Secret access key are saved for future use.

create IAM access key

2. Update AWS IAM credentials in CubeBackup

To update the AWS IAM Access Key ID and Secret Access key for an existing S3 bucket, please follow the instructions below:

  • Log into the CubeBackup web dashboard, and stop the current backup if it is running.

  • Log (or SSH) into the backup server, and stop the backup service.

    If CubeBackup is installed on Linux, run this command in the bash shell:

    sudo /opt/cubebackup/cbsrv stop
    

    If CubeBackup is installed on Windows, enter services.msc in the command line, then in the Services list that pops up, right-click the CubeBackup entry, and select Stop.

  • Open the file “<CubeBackup installation directory>/db/storage.json” with a text editor, and update the S3AccessKeyId and S3SecretAccessKey fields with the new values.

    On Windows, CubeBackup is installed in “C:/Program Files/CubeBackup4” by default.
    On Linux, CubeBackup is installed in “/opt/cubebackup” by default.

  • Start the backup service for CubeBackup again.

    If CubeBackup is installed on Linux, run this command in the bash shell:

    sudo /opt/cubebackup/cbsrv start
    

    If CubeBackup is installed on Windows, enter services.msc in the command line, then in the Services list that pops up, right-click the CubeBackup entry, and select Start.

  • Go back to the CubeBackup console and ensure that CubeBackup is working normally.