Subject: Re: SunOS 4.1.1 wu-ftpd-2.4 nfs mounted uploads

From: [email-masked] (Andrew H. Evans)
Date: Wed, 22 Nov 1995 10:46:35 -0500

> >  > I have wu-ftpd-2.4 running on SunOS 4.1.1.  Everything is fine until
> >  > I NFS mount a partition under an upload directory.  The files intended
> >  > to land there pass OK according to the client (successful upload messages
> >  > but the directory ends up with a zero-length file with the chown/chmod
> >  > performed as prescribed in ftpaccess.  If I umount that NFS dir and uploa
> >  > direct to local disk, it works fine.
> >  > 
> > 	- Works fine with a local disk
> > 	- can write as root to the NFS disk (so is allowed by exports)
> 
> I suspect this is the problem in the first poster's case.  

The NFS partition is exported correctly, even tried the root= directive.
Authorized (real) users may write to that NFS directory via FTP, while
root may of course write from shell.  Here's the exported directory on the
server:

drwxrwx-wx  2 root     yyy           512 Nov 22 10:14 incoming

It is only with user ftp that the error occurs. Here's the message:

Nov 20 16:18:42 ftp vmunix: NFS write error 13 on host otherhost fh 70c 1 a0000 dea6 57483821 a0000 2 67aeeac1 

The NFS server doesn't have a message for me.  We're not seeing "permission
denied" or anything.  I'm pretty confident I've done everything right - but
who isn't?  Here are my appropriate ftpaccess lines:

path-filter  anonymous  /etc/pathmsg  ^[-A-Za-z0-9_\.]*$  ^\.  ^-

delete          no      guest,anonymous
overwrite       no      guest,anonymous
rename          no      guest,anonymous
chmod           no      guest,anonymous
umask           no      guest,anonymous

upload  /export2/ftp   /incoming/xxx    yes     root    yyy  0660 nodirs

where xxx is the NFS-mounted partition under ~ftp/incoming.  yyy is the
group I'd like to use so "real" users can pick up the files.  /export2/ftp
is the UFS partition/direcory we mount on.

I'm pleased to see some interest in this, at least.  Thanks!

- Andy

 ========================================================================
     Andrew Evans                           Computer Science Department
  Computer Specialist                       University of New Hampshire
    [email-masked]                                Durham, NH 03824
 ========================================================================

---

From: Keith Pilotti <[email-masked]>
Date: Wed, 22 Nov 1995 12:37:21 -0800

> I'm pleased to see some interest in this, at least.  Thanks!

Interesting problems like this is what sysadmins live for!  ;-)

Perhaps poking around after doing a 'chroot ~ftp /bin/csh' will give you some 
additional clues.  This more closely simulates the ftp server filesystem 
environment without having the server itself in the equation.

+Keith

---

From: "Derrick J. Brashear" <[email-masked]>
Date: Wed, 22 Nov 1995 15:57:33 -0500 (EST)

My guess would be ftp is able to write files to the NFS partition as
nobody (yes?) and therefore chowning the files isn't possible, nobody
isn;t a privileged user and therefore can't possibly set the permissions
right on the remote file.

Or i may be wrong.

-D

---

From: [email-masked] (Ulla Fischer)
Date: Wed, 29 Nov 95 10:40:08 GMT

I have had the same problem on a SunOS 4.1.4. After upgrading to
Solaris 2.4 I do not have the problem. I use the same entries in
vfstab as in fstab, in dfstab as in exports and the same automount
configuration. The difference is, that Sun implements automounting of
local mounts as links instead of a nfs mount. And then it works.

Yours,
Ulla Fischer
Danmarks Meteorologiske Institut      Email: [email-masked]
Edb-afdelingen                        Phone: + 45 39 15 75 00 
Lyngbyvej 100                         Phone: + 45 39 15 75 54
2100 Koebenhavn 0                     Fax:   + 45 39 15 75 98
Denmark