Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 08-25-2008, 01:39 PM   #1
LQ Newbie
Registered: Jun 2006
Posts: 5

Rep: Reputation: 0
Recursive directory search

I need a script which will go through directories and find all xml type files. Then it needs to change the permissions to chmod 774. I thought this would be easy, not I'm stuck.
Old 08-25-2008, 01:55 PM   #2
LQ Guru
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 253Reputation: 253Reputation: 253
find / -type f -iname *.xml -exec chmod 774 {} \;

Change the / directory to whatever specific directory you want to limit the search to.
Old 08-26-2008, 06:28 AM   #3
LQ Newbie
Registered: Jun 2006
Posts: 5

Original Poster
Rep: Reputation: 0
Thanks, that was easier than I thought. Maybe it was just Monday, so I couldn't think.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
looking for a recursive dependency search tool Tortanick Linux - General 2 01-20-2007 09:45 AM
deletion of a recursive directory? captainnico Linux - Software 9 02-04-2006 05:52 AM
Recursive search in bash scripting ! zulfilee Linux - Software 3 12-12-2004 10:40 PM
recursive directory traversal klfreese Linux - Newbie 2 08-20-2003 07:27 PM
recursive search of a string in a directory ?! realos Linux - Software 4 11-27-2002 04:49 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:55 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration