[prev in list] [next in list] [prev in thread] [next in thread] 

List:       netatalk-devel
Subject:    RE: [Netatalk-devel] dsi_stream_read(0): unexpected EOF in netatalk-2.0.0 and netatalk-2.0.1
From:       "Ngo, Hoc" <hoc_ngo () adaptec ! com>
Date:       2004-12-03 2:40:47
Message-ID: C53B425711C07440B85EBF00C108A83B1A69EC () sjce2k01 ! adaptec ! com
[Download RAW message or body]

Hi Bjoern:

 > I didn't pay attention to my past captures.
> > But for newer captures, I found out there was no tickle 
> > request from the server.  Only the client sent tickle 
> > requests and get no replies.
> > 
> > I will do an strace to see what's going on.
> 
> Great.
> 
> Just to make sure this is not the problem: Have you set any 
> tickle relevant
> value in afpd.conf? (tickleval, timeout, sleep)
> 
> Regards,
> Bjoern

I did lots of straces but did not spot any unusual behavior.
But finally, I have nailed down the bug.

FYI, my coworker added utmp support to netatalk-2.0.X.
Whenever a new user logs on, afpd will update utmp files,
which are owned by root and have permissions 0664.
But at the time of update, the process' effective user
and group have been changed to that of the new user.
Hence updating utmp failed for permission reason.

I don't understand why this update failure has anything
to do with the server sending no tickle messages
to the client.  But if I manually change the permissions
of utmp files to 0666, everything will run fine.  But this
method is not good for security reason.


Thus I fix the utmp code to restore root euid temporarily
just for doing a utmp update.  With this fix the server
runs well for a long time without any EOF error.

In retrospect, I start to suspect that some broken pipe
errors might be triggered by a process trying to access
files that it does not have access to.  Just a hypothesis.

Anyway, thank you very much for your valuable insight
and help.

Hoc


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
Netatalk-devel mailing list
Netatalk-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/netatalk-devel

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic