<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=utf-8">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        color:black;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body bgcolor=white lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><span style='color:#1F497D'>Thanks for the info. I will
check out the site you recommended and give it a try. <o:p></o:p></span></p>

<p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p>

<div>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif";
color:windowtext'>From:</span></b><span style='font-size:10.0pt;font-family:
"Tahoma","sans-serif";color:windowtext'> k12osn-bounces@redhat.com
[mailto:k12osn-bounces@redhat.com] <b>On Behalf Of </b>"Terrell Prudé
Jr."<br>
<b>Sent:</b> Thursday, July 10, 2008 6:59 AM<br>
<b>To:</b> Support list for open source software in schools.<br>
<b>Subject:</b> Re: [K12OSN] home directory permissions<o:p></o:p></span></p>

</div>

</div>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>Ernie Hudson wrote: <o:p></o:p></p>

<p class=MsoNormal>Does anyone have an easy way to change the permissions on
the home directories so that only the owner has access to it. We have some very
bright students and they have found out that they can copy work from someone
else and have more free time. I am using the 5EL and have single sign on using
likewise open from my windows server using active directory. I know I can
change them one at a time using “chmod 700 filename”. I am not adept at writing
scripts and hoping someone can help.<o:p></o:p></p>

<p class=MsoNormal> <o:p></o:p></p>

<p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman","serif"'>Do
get the basics of shell-scripting down.  I'd recommend heading over to <a
href="http://www.tldp.org">http://www.tldp.org</a> and reading the Advanced
BASH Scripting Guide.  That's how I learned how to do it.  Extremely
handy skill and very necessary, just as important as writing .BAT or .REG files
on Windows.<br>
<br>
Now to your specific question.  That's pretty easy to do.  All you
really have to do is change the top level directory permissions under /home, i.
e. no recursion needed.  I'd do it like this, in a basic FOR loop:<br>
<br>
#!/bin/bash<br>
cd /home<br>
for dir in *<br>
do<br>
  chmod 700 $dir<br>
done<br>
<br>
If you want to recurse down and change everything in everyone's homedir to
permissions 700, just add the "-R" switch after "chmod".<br>
<br>
--TP<o:p></o:p></span></p>

<div>

<p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman","serif"'>_______________________________
<br>
Do you <a href="http://www.gnu.org">GNU</a>? <br>
<a href="http://www.cmosnetworks.com">Microsoft Free since 2003</a>--the
ultimate antivirus protection! <o:p></o:p></span></p>

</div>

<p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman","serif"'><o:p> </o:p></span></p>

</div>

</body>

</html>