Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
chmod'ing all files and directories?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
freebies_11
n00b
n00b


Joined: 09 Dec 2004
Posts: 36

PostPosted: Mon Jan 14, 2008 6:52 pm    Post subject: chmod'ing all files and directories? Reply with quote

Hi,

How would I go about chmod'ing all files 600 and all directories 700 recursively?

Thanks!
Back to top
View user's profile Send private message
Naib
Watchman
Watchman


Joined: 21 May 2004
Posts: 6051
Location: Removed by Neddy

PostPosted: Mon Jan 14, 2008 6:54 pm    Post subject: Reply with quote

chmod 0700 * -R
_________________
Quote:
Removed by Chiitoo
Back to top
View user's profile Send private message
freebies_11
n00b
n00b


Joined: 09 Dec 2004
Posts: 36

PostPosted: Mon Jan 14, 2008 6:55 pm    Post subject: Reply with quote

Thanks for the quick reply but this won't work since it'll chmod files 700 instead of 600. :?
Back to top
View user's profile Send private message
gerard27
Advocate
Advocate


Joined: 04 Jan 2004
Posts: 2377
Location: Netherlands

PostPosted: Mon Jan 14, 2008 7:02 pm    Post subject: Reply with quote

Use mc.
It's in portage.
Gerard.
_________________
To install Gentoo I use sysrescuecd.Based on Gentoo,has firefox to browse Gentoo docs and mc to browse (and edit) files.
The same disk can be used for 32 and 64 bit installs.
You can follow the Handbook verbatim.
http://www.sysresccd.org/Download
Back to top
View user's profile Send private message
frenkel
Veteran
Veteran


Joined: 13 May 2003
Posts: 1034
Location: .nl

PostPosted: Mon Jan 14, 2008 7:21 pm    Post subject: Reply with quote

Use find, something like this:

$ find -type f -exec chmod 600 '{}' \;
$ find -type d -exec chmod 700 '{}' \;
Back to top
View user's profile Send private message
freebies_11
n00b
n00b


Joined: 09 Dec 2004
Posts: 36

PostPosted: Mon Jan 14, 2008 7:32 pm    Post subject: Reply with quote

Thank you everyone for your replies, the find method worked perfectly. :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum