Locking a Replication
Lock a File Storage replication resource to prevent updates, moves, and deletions of the resource. Locks help protect resources against tampering.
A lock on a replication resource doesn't prevent the replication from proceeding. The replication process continues even if the resource is locked.
OCI resource locks include the following types:
- Delete lock: Prevents deletion of the locked resource.
- Full lock: Prevents update, move, and deletion of the locked resource.
You can only add or remove one lock type at a time, but both locks can be applied to a resource. For example, you might initially apply a delete lock, but choose to apply a full lock at a later time.
The user who places a lock is the lock owner. Any authorized user with lock privilege or users with global manage permission of the tenancy has the authorization to create and remove any lock in the tenancy. You can override or remove locks.
Required IAM Policy
To create locks, in addition to permissions to manage replications, you need permissions to manage locks.
To lock a replication, you must have RESOURCE_LOCK_ADD
permissions.
- On the File Systems list page, select the file system that you want to work with. If you need help finding the list page or the file system, see Listing File Systems.
- On the source file system's details page, select Replications.
- Select the replication that you want to lock.
- On the replication's details page, next to Resource Locking, select Add.
- In the Add Lock dialog box, select the lock type and select Save changes.
Use the
oci fs replication add
command and required parameters to lock a replication:oci fs replication add --replication-id <replication_OCID> --type <lock_type> [OPTIONS]
For a complete list of parameters and values for CLI commands, see the CLI Command Reference.
Run the AddReplicationLock operation to lock a replication.
For information about using the API and signing requests, see REST API documentation and Security Credentials. For information about SDKs, see SDKs and the CLI.