Added special handling of errors when sync fails in a server. Catch errors if creating the link tree directory fails.