Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!julius.cs.uiuc.edu!ux1.cso.uiuc.edu!mp.cs.niu.edu!rickert From: rickert@mp.cs.niu.edu (Neil Rickert) Newsgroups: comp.unix.admin Subject: Re: Network-wide Mail Spool? Message-ID: <1990Nov7.174946.29272@mp.cs.niu.edu> Date: 7 Nov 90 17:49:46 GMT References: Organization: Northern Illinois University Lines: 41 In article karl_kleinpaste@cis.ohio-state.edu writes: >Any reason why one couldn't place symlinks: > > cd /usr/spool/mail > foreach i (*) > mv $i ~{$i}/.newmail > ln -s ~{$i}/.newmail $i > end > chmod 555 /usr/spool/mail # to prevent removal of the links. > >That's a serious question; I've been debating this for a while. We'd >like users' mail not to occupy space in a public filesystem, but >rather take up space under the area where quotas are enforced. The only reason I can think of is the following code in /bin/mail (which is usually used for final delivery to the mail spool file). The function safefile() is called to validate the mailbox before the incoming mail is written to it. ------------------------------------------------------------- safefile(f) char *f; { struct stat statb; if (lstat(f, &statb) < 0) return (1); if (statb.st_nlink != 1 || (statb.st_mode & S_IFMT) == S_IFLNK) { fprintf(stderr, "mail: %s has more than one link or is a symbolic link\n", f); return (0); } return (1); } -- =*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*= Neil W. Rickert, Computer Science Northern Illinois Univ. DeKalb, IL 60115. +1-815-753-6940