Go Back   The macosxhints Forums > OS X Help Requests > UNIX - General



Reply
 
Thread Tools Rate Thread Display Modes
Old 06-07-2005, 04:14 PM   #1
uli_the_knecht
Prospect
 
Join Date: Mar 2004
Posts: 16
set automatically all files on a server-volume to 777

hi,

i want to set all files in a server-volume (mac os x server) to rwx for everyone (777). now, i'm doing it with cron:
chmod -R 777 /Path_to_share/

is there a better way to do this?

thanks!
__________________
greez. uli (the knecht)
uli_the_knecht is offline   Reply With Quote
Old 06-07-2005, 05:34 PM   #2
acme.mail.order
League Commissioner
 
Join Date: Sep 2003
Location: Tokyo
Posts: 6,045
There is definitely a better way. Please explain what you are trying to accomplish in detail. I would guess that a bit of group management is what you need, not a blunt read/write/run by everyone.
acme.mail.order is offline   Reply With Quote
Old 06-08-2005, 12:03 AM   #3
uli_the_knecht
Prospect
 
Join Date: Mar 2004
Posts: 16
hi

10 macs, no shared user directories (ldap), connected via afp on the server. all users should have read/write/execute to every file on the server-volume. if another user shortly would handle with the file-server, there should be no limited access to anything.

thanks,
__________________
greez. uli (the knecht)
uli_the_knecht is offline   Reply With Quote
Old 06-08-2005, 12:21 AM   #4
hayne
Site Admin
 
Join Date: Jan 2002
Location: Montreal
Posts: 31,940
Quote:
Originally Posted by uli_the_knecht
all users should have read/write/execute to every file

You don't want the "execute" bit turned on except for files that actually are executable (programs or shell scripts, not documents) and for folders/directories.
Thus it would be much better to use:
chmod -R ugo+rwX /Path_to_share/

(Read 'man chmod' for details, noting that it is an uppercase X in the command I recommended.)
hayne is offline   Reply With Quote
Old 06-08-2005, 12:31 AM   #5
uli_the_knecht
Prospect
 
Join Date: Mar 2004
Posts: 16
ok, i see, this works fine.

thank you!
__________________
greez. uli (the knecht)
uli_the_knecht is offline   Reply With Quote
Old 06-08-2005, 02:20 PM   #6
forbin
Triple-A Player
 
Join Date: Jan 2005
Location: Rochester, NY
Posts: 123
You can change the umask to 000 so all files created will have permissions of 777.
forbin is offline   Reply With Quote
Old 06-08-2005, 03:58 PM   #7
voldenuit
Hall of Famer
 
Join Date: Sep 2003
Location: Old Europe
Posts: 4,969
Note however that experience shows that one fine day someone will trash a whole bunch of somebody elses files by mistake.
That day you'll have to take the time to figure out a reasonable account and group management.

And even if in your special situation the setup works, it is not Good Practice in usual contexts.
voldenuit is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off

Forum Jump



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


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.
Site design © IDG Consumer & SMB; individuals retain copyright of their postings
but consent to the possible use of their material in other areas of IDG Consumer & SMB.