mid creation process cleanup