add if condition in create_conf_bak_dir function