This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Problem in porting GoAhead Web server on ep7212


We've had goAhead web server running non-stop on 
our mips board for a couple of months now. We increesed
the memory size and there was a bug with the file descriptors
in the select function.

I think the function was socketSelect in file sockGen.c the
file descriptor calculations did not work correctly, I think the
code went:

#if ECOS
#if 0
    nwords = (FD_SETSIZE + NFDBITS) / NFDBITS;
    len = nwords * sizeof(int);
#endif
    len = 32;
#else
    nwords = (socketHighestFd + NFDBITS) / NFDBITS;
    len = nwords * sizeof(int);
#endif

The hack len = 32 makes the web server responde quicker.

Oh and I think my memory size was: 327680

hope this helps,
Col.


On 27 Sep 2001 12:40:24 +0200, Peter Graf wrote:
> Balaji.T.S wrote:
> 
> >We are trying to port GoAhead web server on EP7212. We got the GoAHead web 
> >server from the internet for the eCos. we build it and compiled it for 
> >EP7212. We ported that and it is not working. After debugging we came to 
> >know that the required 60 kb of memory could not be allocated by kernel. 
> >Then we came to know from eCos mail listing that by modifying the Parameters 
> >in the ecos.ecc file (user value of the CYGNUM_LIBC_MALLOC_MEMPOOL_SIZE to 
> >1638400), it is possible to allocate the required memory. But it still we 
> >can't able to port the webserver. the malloc fails to give 60 kb of memory.
> 
> If you are working with an up-to-date version, there might be no fixed
> dynamic memory pool. Usually the heap is used for that. If not, try setting 
> 
> CYGNUM_MEMALLOC_FALLBACK_MALLOC_POOL_SIZE
> 
> to a larger value and make sure you have enough physical memory.
> 
> However, I can start the GoAhead webserver (Target: Custom Hitachi 7709A),
> but is doesn't work reliably. Using simple variable block allocation
> instead of Doug Lea's implementation improves the situation, but the
> webserver still hangs occasionally. Sometimes it recovers if I wait a few
> seconds before the next HTTP access, sometimes it crashes. I suspect that
> GoAhead's internal memory management also has problems, but I have not
> exactly found out.
> 
> I wonder if anybody on this list is successfully using the GoAhead
> Webserver with current eCos version?
> 
> Bye,
> Peter



-- 
===========================================
Colin Ford               PipingHot Networks
Software Engineer        +44 (0)1364 655510 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]