[CentOS] Find and excluding directory
Tom Brown
tom at ng23.netTue Feb 2 21:17:00 UTC 2010
- Previous message: [CentOS] Find and excluding directory
- Next message: [CentOS] cfengine version 3?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
> Your "-path" argument is wrong. Try this: > > find /var/data/foo -path '/var/data/foo/.snapshot' -prune -o -exec chown > usera:groupb {} + > > You need the whole path, and there is no need to escape the '.' character. > I've also used "+" as the terminator. That's just an efficiency issue. It > makes 'find' build command lines with as many matches as will fit rather > than invoking 'chown' separately for each one. > > Hi Robert many thanks - that resolved ths issue for me tom
- Previous message: [CentOS] Find and excluding directory
- Next message: [CentOS] cfengine version 3?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the CentOS mailing list