On Sat, 7 Jan 2012, logical american wrote:
> I was manually running the "rm -r * " command
>
> cd /backup/lib
> rm -r *
> cd ../lib32
> rm -r *
> cd ../lib64
> rm -r *
>
> and then things stopped working at this point
>
> but lib64 was a symbolic link to /lib, I believe, which I believe was
> pointing back to /lib on the main system, not /lib on my backup drive.

Yeah, that sounds likely.  By cd'ing into the link (lib64 -> /lib) you 
moved to /lib, and rm -r *'ed as indicated.

However, if you hadn't cd'ed into the link, the rm would have just removed 
the symbolic link, and not the files in the dir the link points to
(cd /backup; rm -r *).

Or, you could test that the entity you want to cd into is a real 
directory, rather than a link, before doing the cd and remove step
(man test).

--
David Fleck
[email protected]

_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug

Reply via email to