What Does Chown Mean?

liunx

Guest
Every so often, I see a script with directions such as<br /><br />"You must chown the directory this script resides in to the same user or group your webserver runs<br />in"<br /><br />Can someone shed some light on this for me?<!--content-->
<a href="http://uk.php.net/chown" target="_blank">http://uk.php.net/chown</a><br /><br />Not that I know what its on about?<!--content-->
Change Owner? And here I thought it was a contraction for <b>CH</b>ow d<b>OWN</b><!--content-->
Welcome to the wonderful world of Unix commands!<br /><br />chown = CHange OWNer (ie, change owner of file or directory)<br /><br />knowing that, then what's: chmod? <br /><br />Yep, CHange MODification (ie, change permissions to read, write or execute a file)<br /><br />And ed? Yep, editor.<br /><br />But, then what about: awk?<br /><br />Nope, awk is not an abbreciation of any words. Rather, the 'awk' command, which is a very powerful parser program in Unix, is the first initial of the last name of the 3 men who invented this neat, little Unix utility!<br /><br />-kw<!--content-->
Alfred V. <b>A</b>ho<br />Peter J. <b>W</b>einberger<br />Brian W. <b>K</b>ernighan<br /><br />Gotta love Google<!--content-->
Okay... making more sense. But my follow up question would be whether we can do this for our scripts? Or is the best/only way to change permissions through chmod?<br /><br />Thanks.<!--content-->
Since your original question was about chown; but, your most recent comment talks only<br />about chmod, I'm not sure to what "whether we can do this" refers.<br /><br />Only the Unix super-user can change the ownership of anything. You can't.<br /><br />Only the owner of a thing can use chmod on the thing to change the permissions.<br /><br />You can change permissions on files that you own using the cPanel interface or using<br />chmod or chmod-like commands in CGI/PHP/shell scripts.<!--content-->
 
Top