Files
floci/docs
Hector Ventura ec5692dfa2 fix(ec2): remove the volume helper container on shutdown (#5551)
* fix(ec2): remove the volume helper container on shutdown

The privileged helper that manages loop devices for EBS volumes was
started on the first volume operation and never stopped or removed, so
it kept running after Floci exited and stayed in the container list.

Ec2VolumeBlockDeviceManager now implements ContainerTeardown. On
shutdown and on a state reset it looks the helper up by name, detaches
the loop devices behind the backing files and removes the container. It
never creates a helper only to remove it, and it also collects one left
behind by an earlier process. Backing files stay in storage and the next
volume operation recreates the helper.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

* fix(ec2): leave no volume helper after a reset and report failed loop detaches

A state reset removed the helper in the container teardown and then
started it again to delete the backing files, so the reset ended with a
running helper. clear() now removes the helper once the files are gone.

The script that releases loop devices before the helper is removed
discarded every losetup failure, so the warning that follows could only
fire when the exec itself failed. It now records each loop device that
would not detach and exits non-zero, while still trying every device and
still removing the helper.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

---------

Signed-off-by: Hector Ventura <hectorvent@gmail.com>
2026-10-12 23:36:15 -04:00
..
2026-03-15 17:43:56 -05:00