ensure shm is used if possible