some rework on the failed cleanup script, still some more to go here