Re: Shared Virtual Memory Question/Engine Shutdown
Posted in 1997
Carol Davies wrote: : : Our project site recently received a binary executable from a sister : site which updated approximately 5000 stored procedures. The executable : brought down the engine due to shared memory limitations. When looking : at the data (onconfig, memory on machine, etc. as stated below), the : numbers don't exactly seem to add up and I am wondering if someone could : provide further insight, as I a probably missing something important: : : Contents of onconfig as related to shared memory: : SHMBASE 0x30000000 # Shared memory base address : SHMVIRTSIZE 8000 # initial virtual shared memory segment : size (Kbytes) : SHMADD 16384 # Size of new shared memory segments : (Kbytes) : SHMTOTAL 190000 # Total shared memory (Kbytes) : : Contents of online.log (paraphrased): : : 13:14:35 Logical Recovery Started. : 13:14:35 dynamically allocated new shared memory segment (size : 16777216) : : (this is repeated for a total of 7 dynamic allocations). After the 7th : dynamic allocation, there are approximately 25 of the following : messages: : : 14:28:46 shmat: [EINVAL][22]: shared memory base address illegal : : 14:28:46 using 0xd0000000, needs 0xffffffff : : 14:28:46 out of virtual shared memory : : which are followed by the engine shutting down with: : : 14:28:49 mtshpool.c, line 2549, thread 69, proc id 24814, Condition : Failed ((po : ol != NULL && ptr != NULL)), In (mt_shm_free) : Thread(69, sqlexec, 0, 1). : 14:28:49 PANIC: Attempting to bring system down : : The server memory configuration is as follows: : >>snip : According to my math, 8000 (initial) + 114688 (16384 X7) = 122688, which : is less than the onconfig max of 190000, and there is system availble : paging memory, so why the shutdown? The only conceivable reason I can : think of is system virtual paging memory allocated to other system : processes, resources. : : Any help would be appreciated. : : System is AIX 3.2.5 : : OnLine Version 7.12.UC1 : ----------------- : Carol Davies : cdavies@csc.com Hi Carol, thanks for your question - it was the clue to solving the same problem at our shop (with much more memory however). It seems, that Informix cannot address more than 8 Virtual Shared Memory Segments (1 at start + 7 additional = 8). (Is this a bug or an undocumented feature?). Allocation of the 9th segment will fail in any case - the sizes of physical memory and SHMMAX don't matter (with the orror you got too). The solution (workaround?) is easy knowing about the limit - simply increase SHMVIRTSIZE to whatever you need (e.g. 130000 in your case) and/or increase SHMADD. Hope this helps, Peter -- ============================ Peter Kolmhofer Database Engineer Porsche Informatik, Austria email: kop@porsche.co.at