title: How to set system wide umask?
body: <p>I am working in a lab where we are running Linux (Debian and Ubuntu). Usernames and group names are handled by NIS and yp. We have some common users that everybody has access to that run the experiments and then we each have our own users in addition there is a common group that we are all a member of.</p>
  
  <p>How can I make such that all files and directories on the shared <code>/home/</code> drive (NFS) is read/write(/executable) by user/group? Basically what I want is</p>
  
  <pre><code>chmod -R 664 /home
  chgrp -R commongroup /home
  </code></pre>
  
  <p>or equivalently <code>umask 0002</code>.</p>
  
  <p>But running the above commands only fixes the current files in the folders and umask only works for single users and has to be run every time a user logs in ie. in the <code>.bashrc</code> file (and will this work for changes mode via gnome?). Is there a system wide command or setting that I could use to make sure that our commongroup has write access to the common files?</p>