error check on tar command