mysql python rename and remove files; clean up