Fun With Find
Find command combined with exec can give you about anything you want. For example, you want to list and output to file for user “darkwan”.
find / -user darkwan -exec ls -ld {} \; > /tmp/output
Cool! How about change the owner of files, from “darkwan” to “root” ?
find / -user darkwan -exec chown root {} \;
Anyway, be warned about the destructive of the command if you combined it with rm !
More about this topic can be referred here.
Advertisement
Leave a Comment