use a different pid if one is given