creating lock file