The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Help setting up file permissions andrewpmoore UNIX for Dummies Questions & Answers 0 04-24-2008 04:46 AM
To give the "unzip" permissions & "create" file permissions Mike1234 HP-UX 3 03-02-2008 02:34 PM
Setting Default Permissions for Files robbieg UNIX for Dummies Questions & Answers 1 11-24-2004 02:26 PM
Permissions on /bin josramon UNIX for Advanced & Expert Users 7 04-02-2003 07:50 AM
permissions mma_buc_98 UNIX for Dummies Questions & Answers 1 08-13-2002 02:15 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 05-01-2008
Registered User
 

Join Date: Apr 2008
Posts: 28
Setting permissions

I've been told I need to set the permissions for everything in the htdocs folder to 777, but how do I go about doing this?
Thanks
Reply With Quote
Forum Sponsor
  #2  
Old 05-01-2008
vgersh99's Avatar
Moderator
 

Join Date: Feb 2005
Location: Boston, MA
Posts: 3,029
'man chmod'
Reply With Quote
  #3  
Old 05-01-2008
Registered User
 

Join Date: Apr 2008
Posts: 28
sorry, I don't understand that - what does that mean and where do I put that?
Reply With Quote
  #4  
Old 05-01-2008
Registered User
 

Join Date: Apr 2008
Location: European Union/Germany
Posts: 183
777 = everybody can execute and alter everything. That is for sure not what you want. However, it would go as follows (escaping like bash):
Code:
find /whereever/my/htdocs/are/ -exec chmod 777 {} \;
Better do the following (everybody can read, only owner can alter or execute):
Code:
find /whereever/my/htdocs/are/ -type d -exec chmod 755 {} \;
find /whereever/my/htdocs/are/ -type f -exec chmod 644 {} \;
If some cgi needs to write to some location beneath htdocs change ownership of those files/directories to the user used by your webserver to run cgis (normally apache, httpd oder nobody).

Quote:
Originally Posted by thehaapyappy View Post
sorry, I don't understand that - what does that mean and where do I put that?
Put that into command line - it will display help about chmod command. Use "man find" to find out what above does in detail.
Reply With Quote
  #5  
Old 05-01-2008
Dave Miller's Avatar
Registered User
 

Join Date: Dec 2007
Location: Northern NJ, USA
Posts: 150
Quote:
Originally Posted by vgersh99 View Post
'man chmod'
Quote:
Originally Posted by thehaapyappy View Post
sorry, I don't understand that - what does that mean and where do I put that?
man is a build in technical manual. Simply enter man [command] to get details about any unix command. Of course, you need to know WHICH command.

chmod is the command to change permissions.

One thing about man: read the whole thing, particularly the last few lines. There you're see references to similar commands that may be helpful.
Reply With Quote
  #6  
Old 05-01-2008
Registered User
 

Join Date: Apr 2008
Posts: 28
Okay thanks, I've got the man chmod and am now about to read it, but how do I find out where the file to change the htdocs permissions is?
Reply With Quote
  #7  
Old 05-01-2008
Registered User
 

Join Date: Apr 2008
Location: European Union/Germany
Posts: 183
htdocs is no single file but a folder. Ask the one who installed your system, he'll tell you. Maybe Have a look for /srv/www/htdocs , /var/www , /var/lib/apache/htdocs .

If you've installed the system yourself start reading the documentation coming with it - it will help you to actually understand what to do.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 07:40 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0