Implementation of race free writing of configuration files