preg_match to detect failed config