now, can record pid to file