[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: checking mirror state?



>"James R. Van Zandt" <jrv@vanzandt.mv.com> writes:
>
>> You can use "find" to look for broken symlinks:
>> 
>>   find . -follow | grep "No such"

Actually, this works only by accident, because find prints its error
message to stderr rather than stdout.  A better pipeline would be:

  find . -follow 2>&1 | grep "No such"

This can be extended to saving the bad symlinks in a file:

  find . -follow 2>&1 | awk '/No such/{sub(/:/,"",$2); print $2}' >afile

                                  - Jim Van Zandt


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-devel-request@lists.debian.org . 
Trouble?  e-mail to templin@bucknell.edu .


Reply to: