You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The backup feature (backup_storage) fails if the destination path is in a different mount point than the files (e.g. a different Docker bind mount or volume).
This happens because os.Rename as used here is just a call to the renameat syscall, which doesn't allow moving across partitions.
You can't "move" a file on different partitions, because you have to copy bytes around. If you want to move or rename a file, you are talking about a file system just pointing to the same bytes, just from a different location. Thus if you get that error you should just copy and delete the file.
Thus I guess the error could be captured and a different move method attempted, kind of
if e, ok := err.(*os.LinkError); ok && e.Err == syscall.EXDEV {
// Retry with a different way of moving.
}
But as it is right now, such a move will cause the error posted below, regardless of having correct write permissions on the destination path.
Describe the bug
The backup feature (
backup_storage
) fails if the destination path is in a different mount point than the files (e.g. a different Docker bind mount or volume).This happens because os.Rename as used here is just a call to the renameat syscall, which doesn't allow moving across partitions.
The error is
EXDEV
, which Go translates into "invalid cross-device link". See os.Rename between different partitions:Thus I guess the error could be captured and a different move method attempted, kind of
But as it is right now, such a move will cause the error posted below, regardless of having correct write permissions on the destination path.
Egress Version
https://hub.docker.com/r/livekit/egress/
v1.8.0
Egress Request
N/A
Additional context
/backup_storage/
is a Docker bind-mount to the host system, where recording backups should be stored.Logs
The text was updated successfully, but these errors were encountered: