Re: async-i/o for 2.4

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Thu, 09 Nov 2000 23:54:56 +0100

Fixed a quite nasty bug today which may well have caused your
shutdown/aioSync problem. Can you please update and try againg.

/Henrik

Costas Tavernarakis wrote:
>
> On Mon, Nov 06, 2000 at 10:19:31PM +0100, Henrik Nordstrom wrote:
> > Costas Tavernarakis wrote:
> >
> > > I've been trying out your 2.4 async i/o fixes on Solaris 8, and it seems to
> > > be working fine for me (although the cache hasn't seen a production load
> > > yet). I've only had an issue where 2.4+asyncio failed to shut down properly,
> > > but i can't tell if it's related to async i/o. It was before your yesterday
> > > fixes, i'll see if it happens again and keep you posted with details.
> >
> > The changes yesterday was quite important. Squid fell over if async-io
> > detected a single problem, such as a missing cache file, out of space or
> > similar problems..
>
> I said i'd get back to you about my shutdown issue, as it may be of interest.
> Although it seems to be asyncio-related, it's perfectly acceptable if you
> discard this as it propably does not belong in a message addressed to your
> personal mailbox, or if you forward it.
>
> I'm sort-of testing this cache as a default parent of my production one.
> Often (but NOT always), when i issue squid -k shutdown, squid hangs.
>
> In cache_log, i get:
> 2000/11/05 18:18:27| Preparing for shutdown after 0 requests
> 2000/11/05 18:18:27| Waiting 30 seconds for active connections to finish
> 2000/11/05 18:18:27| FD 30 Closing HTTP connection
> 2000/11/05 18:18:27| FD 31 Closing HTTP connection
> 2000/11/05 18:18:27| Shutting down...
> 2000/11/05 18:18:27| FD 32 Closing ICP connection
> 2000/11/05 18:18:27| FD 33 Closing SNMP socket
> 2000/11/05 18:18:27| Closing unlinkd pipe on FD 11
> 2000/11/05 18:18:27| aioSync: flushing pending I/O operations
>
> Then, the squid process goes on to use 100% of one cpu (25% CPU usage on a
> 4-cpu system, compared to 3-4% under normal circuimstances). At that time,
> truss shows nothing else going on, but squid beeing in a loop of time_tick():
>
> signotifywait() = 14
> lwp_sigredirect(1, SIGALRM, 0xFF00FC4C) = 0
> Received signal #14, SIGALRM [caught]
> sigprocmask(SIG_SETMASK, 0xFF0EF010, 0x00000000) = 0
> alarm(1) = 0
> sigprocmask(SIG_SETMASK, 0xFF0FADE0, 0x00000000) = 0
> setcontext(0xFFBEF358)
> ...
>
> getting a core image (how nice solaris has gcore),
> gdb gives the following backtrace:
>
> #0 0x89d3c in aio_poll_queues ()
> #1 0x89f1c in aio_sync ()
> #2 0x88b4c in aioSync ()
> #3 0x77f38 in storeDirSync ()
> #4 0x576f8 in SquidShutdown ()
> #5 0x3c1a8 in eventRun ()
> #6 0x5701c in main ()
>
> [if you want the core file itself, i can make it available to you,
> but it's 46MB compressed AND squid was NOT compiled with -g].
> I can recompile with gcc and -g, if you want.
>
> Top at this time continues to report 164 threads just like normal run-time.
>
> >
> > > Before you commit the changes, though, (and this IS minor), please change
> > > some C++ styled comments in aiops.c to C styled ones, as it breaks non-gcc
> > > compilers.
> >
> > Granted. Was not aware that there was any C++ style comments there.. Ah,
> > there is not actually. Those are from Adrian and are already in the HEAD
> > version.. but I fix them when I commit the rest of it.
>
> Correct. I'm sorry to nag you about it.
>
> --
> ========================================================================
> Costas Tavernarakis OTEnet S.A. Internet Service Provider
> E-mail: taver@otenet.gr Home Phone: 01-8842522
> Cellular Phone: +30-97-7272714 Work Phone: 01-3826199
> ========================================================================
Received on Thu Nov 09 2000 - 16:23:48 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:57 MST