up-right-and-down-left-from-centerHow AutoScaler Works

Learn what happens to your data when Datafy autoscales your EBS volumes - from activation through growing, shrinking, and deactivation

Datafy AutoScaler

Datafy AutoScaler reduces your EBS costs by automatically right-sizing your volumes to match actual usage. This page explains what happens to your volumes at each stage of the autoscaling lifecycle - from activation through growing, shrinking, and deactivation.

circle-check

Virtualization Layer

To understand how AutoScaler works, it helps to understand what changes when Datafy manages a volume - and, just as importantly, what stays the same.

When you activate autoscaling on a volume, Datafy AutoScaler creates a virtualization layer between your filesystem and the underlying EBS storage. This layer intercepts I/Os at the block device level and redirects them to Datafy-managed volumes, which are sized to match your actual data usage.

Your filesystem is never modified - whether you use ext4, XFS, or another supported Linux filesystem, it continues operating exactly as before. Your applications, your OS, and your filesystem all still see the same virtual volume at the same mount point, with the same reported size. The only difference is that behind the scenes, the data lives on smaller, right-sized EBS volumes managed by Datafy.

Think of it like a virtual address system: your applications write to the same "address" they always have, but Datafy translates that address to the actual location on the underlying storage.

Datafy Virtualization Layer

Datafy Volume Pairs

Under the hood, Datafy replaces your original EBS volume with a pair of smaller EBS volumes and stripes data across them using a RAID 0 scheme. This means that each read or write is distributed across both volumes in the pair, which helps balance I/O and throughput load.

The striping is fully managed by the Datafy agent - your filesystem and applications are unaware that multiple volumes are involved. From their perspective, nothing has changed.

circle-info

For simplicity, the diagrams on this page refer to a single new volume created during activation, shrink, and deactivation. In practice, each of these operations creates or replaces a pair of volumes that work together as a single logical unit.

Optimization Actions

Throughout the lifecycle of an autoscaling volume Datafy AutoScaler will perform the following optimization actions:

  • Autoscaling Activation- the initial migration of the data from a standard EBS volume, to an autoscaling one.

  • Growing- when data is written to the volume, the managed volume will "grow", to ensure that there is alway enough space.

  • Shrinking- when data is deleted from the volume and utilization drops, the data will be migrated to smaller volume, to minimize empty space and maximize savings.

  • Autoscaling Deactivation- if desired, the data will be copied back to a new full-sized volume, which will continue operating without AutoScaler.

Autoscaling Activation

When you activate autoscaling on a volume - either manually through the All Volumes Table, or automatically using autoscaling rules - the following steps happen:

1

Datafy creates new, right-sized EBS volumes

New, smaller EBS volumes are created in your AWS account. These volumes are sized based on how much data you are actually using, plus a buffer to accommodate normal write activity.

2

Your data is copied live

Datafy copies your data from the original volume to the new Datafy-managed volumes, while your applications keep running. The copy operations are automatically throttled to give priority to the I/Os from your application. This ensures minimal impact on your application's performance.

3

Switch to Datafy volumes

Once the copy is complete, AutoScaler activates the virtualization layer. All I/O is redirected to the new, smaller volumes, and the original volume is deleted. From this point on, the Datafy agent continuously monitors your storage usage and adjusts capacity automatically.

For example, a volume provisioned at 250 GiB with 50 GiB of actual data will be replaced by Datafy-managed volumes totaling roughly 60 GiB - so you only pay for what you are actually using, plus a small buffer.

circle-check

Growing

Datafy continuously monitors how much storage your volumes are actually using. When usage approaches the current capacity, Datafy automatically increases it, before you run out of space.

circle-check

Growing is handled in one of two ways:

Modify

When possible, Datafy uses the AWS volume modify API to enlarge the existing volumes in place.

Append

When a volume is in cooldown and AWS modify can't be performed, Datafy creates new volumes and appends them to the existing set. This ensures that growth is always possible with no delays, regardless of AWS modification limits.

In both cases, the process is seamless. Your applications continue running normally, and the filesystem is unaware that underlying volumes have changed.

Shrinking

When your data usage decreases and capacity utilization drops below a configurable threshold (default 50%), AutoScaler initiates a shrink to reclaim unused storage and reduce costs.

Shrinking works similarly to the initial activation: AutoScaler creates new, smaller volumes, copies your data to them live, and then discards the old, larger volumes once the copy is complete. As with all other operations, this requires no downtime. The performance impact is minimal and can be throttled.

circle-info

If your volume receives new writes during the shrink process, and the utilization rises, AutoScaler automatically aborts the shrink operation.

Autoscaling Deactivation

You can deactivate autoscaling on any volume at any time.

When you deactivate, AutoScaler copies your data back to a standard EBS volume at the original provisioned size - the same size the volume was before you activated autoscaling. The virtualization layer is removed, and the Datafy-managed volumes are deleted.

Once deactivation is complete, the volume operates as a normal EBS volume, fully independent of Datafy. As with every other operation, deactivation requires zero downtime.

Last updated

Was this helpful?