fixed a contention lock problem with random replacement and a small problem with the default ini