delete old files and add pid code