return thread function when lockfile !exists