Coda File System

Re: Coda on Linux-PPC (builds and starts, but can't find server)

From: Peter J. Braam <braam_at_cs.cmu.edu>
Date: Mon, 3 Aug 1998 08:38:12 -0400 (EDT)
On Sun, 2 Aug 1998, Troy Benjegerdes wrote:

> Okay, I've been playing with coda again, and I managed to build venus and
> get it to almost fully start without segfaulting.

Excellent!


> 
> There appear to be two problems.
> 
> First, I had to change all the 'getservbyname( something, NULL )' to
> 'getservbyname( something, "udp" )' (or tcp) to get this to work. For some
> reason getservbyname segfaults if given a Null pointer for type. I may not
> have gotten these right, so this might be the cause..
> Anyway, the problem is that I set 'testserver.cs.cmu.edu' as the coda
> server, and I get a report in the log saying:
> 
> 23:39:16 strauss.coda.cs.cmu.edu unreachable
> 23:39:44 GetRootVolume: Can't get root volume name!
> 
> (Could this also be because I'm behind and IP-masqing firewall? )
> 

Yes, at the moment you can't go through that.  This message more or less
indicates that everything is working....


> The second problem is that when I give venus a TERM or HUP signal, it
> segfaults. I believe this to be a problem with the lwp library and the way
> PPC linux does signals. PPC linux does something strange like using the
> area above the stack for linkage information, and by the signal handler.
> This is happily blowing away stuff on the stack, which is causing threads
> using that stack to segfault. I've tried padding the top of the stack with
> an extra 16 and 32 bytes. It might just take more, or a different way of
> doing it. (FYI, as of a few weeks ago, pthreads was broken on LinuxPPC
> because of this very reason)

Yes, that would be pretty bad.

> 
> Also, what does it take to use ptreads instead of the LWP stuff?

My feeling on pthreads is that it's not worth looking at until we have
ironed out just about all stability issues.  

> 
> If anyone wants patches to mess with, let me know.
> 

I'd love these patches, but given the amazing progress you have made, you
could perhaps sort out the signal issue too.   The main stack of the
program survives for the "Main" lwp thread. The others are memory mapped
with guard pages before and after to solidly detect stack overflow with a
segmentation fault. Somehow the signal handler should go back to the
original stack.

On the whole Coda programs do not really rely on signals (although of
course the kernel could send one).

- Peter -


> --------------------------------------------------------------------------
> | Troy Benjegerdes    |    troybenj_at_iastate.edu    |    hozer_at_drgw.net   |
> |    Unix is user friendly... You just have to be friendly to it first.  |
> | This message composed with 100% free software.    http://www.linux.org |
> --------------------------------------------------------------------------
> 
Received on 1998-08-03 08:43:06