Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Ability to continue after a failure #50

Open
saxx0n opened this issue Nov 18, 2024 · 5 comments
Open

Add Ability to continue after a failure #50

saxx0n opened this issue Nov 18, 2024 · 5 comments

Comments

@saxx0n
Copy link

saxx0n commented Nov 18, 2024

Right now I have an issue with several files that are right against the limit for filename length. Due to it, the .balance extension puts it over, and the rebalance fails.

It would be awesome if the script could write the failed file (and the error) to a separate textfile and keep running, as right now it means that I have to babysit/restart this script a lot more than is comfortable.

@joeknock90
Copy link

I second this!

@nan0tEch
Copy link

nan0tEch commented Jan 17, 2025

i tried both methods via ssh and docker, via ssh the script kinda resumes by skippen the files when the script stops after failure. I tried the docker method but this starts completely over again. would it be a possibility to restart the docker and it look to a date modifiet that is older then a date that would be given to the docker instance if it is even possible to give some extra parameters to the docker.

Seems to be a bad situation on my side, a few files didn't have the right permissions. The script is now running 8 hours and counting.

@dlong500
Copy link

Seems like a file length issue could also be entirely resolved with a more robust rename operation that uses a generated UUID for the temporary filename instead of appending an extension.

Of course this adds some complication in the case of a failure due to something else where you might end up with a temporary filename if the script failed after deleting the original file but before a rename operation occurred (though this seems unlikely). The log file should of course also reflect the UUID which could help in that case, and of course as mentioned in the README a backup should always exist before an operation like this.

@AT-StephenDetomasi
Copy link

Seems like a file length issue could also be entirely resolved with a more robust rename operation that uses a generated UUID for the temporary filename instead of appending an extension.

I would support this as long as the generated UUID would only be used if the filename would exceed the filename limit. Otherwise, it uses the standard .balance extension.

@dlong500
Copy link

Rather than complicating the existing logic probably the best way would be to put it behind a flag, something like --use-uuid. That way it would default to the existing method but use UUIDs for everything if the flag is present. I don't have time to make a PR at the moment but I might be able to do that later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants