Hi Andy,
Thanks for standing by my friend. Now I have a friend in db2 world.
I was able to resolve it with weird shared memory allocation
parameters at the linux kernel level.
My earlier shmmax, shmall etc. parameters were as below when I was
not able to allocate the beyond 4G on my machine.
[[Email Address Removed] kernel]# ipcs -l
------ Shared Memory Limits --------
max number of segments = 4096
max seg size (kbytes) = 1048576 // shmmax
max total shared memory (kbytes) = 8388608 // shmall
min seg size (bytes) = 1
With the following settings I was able to go beyond 4GB allocation
for the instance. I was even able to go beyond 8 GB on my machine
allocated to bufferpools only (not a recommended practice I hope) :
[[Email Address Removed] kernel]# ipcs -l
------ Shared Memory Limits --------
max number of segments = 4096
max seg size (kbytes) = 262144
max total shared memory (kbytes) = 33554432
min seg size (bytes) = 1
Hope this is useful for sites have huge memory machines.
Regards,
-- Mukul
-----Original Message-----
From: Andrew Beaton [mailto:[Email address protected]
Sent: Wednesday, June 27, 2007 8:29 AM
To: Mukul Sharma
Subject: Re: DPF (database partitioning feature) Memory allocaton issue
-Please advice
Sorry, if you're running 64 bit DB2, I'm at a loss.
Can you at least get it to start if you decrease some of the memory heap
values?
Shrinking the bufferpools might be a way to start diagnosing the problem
as well.
Sorry I couldn't be more help.
-Andy
Mukul Sharma wrote:
> Thanks for you response Andy,
> Yes I am sure about that and as it is one of the basic rules in DPF
> environments, configuration is pretty consistent on all 8 partitions.
>
> What I am seeing is:
> I start seeing memory allocation error when this instance
allocates
> beyond 4GB of RAM. I think most of the agent related memory is
allocated
> on the fly and it is hitting some kind of limit either on the DB2 or
OS
> side which limits the usage of memory beyond 4 Gigs.
>
> On the other note
> (http://www.ibiblio.org/pub/linux/docs/HOWTO/DB2-HOWTO):
>
> We have not set the following parameters at the kernel level:
>
> HugePages_Total: 0
> HugePages_Free: 0
> Hugepagesize: 2048 kB
>
> And *not set* set DB2_LGPAGE_BP=yes at the registry level.
>
> Are these OS settings absolute must if you want to go over 4 Gigs?
> (2**32)
>
> Thanks for your support and advice again.
> --mukul
>
>
> -----Original Message-----
> From: Andrew Beaton [mailto:[Email address protected]
> Sent: Tuesday, June 26, 2007 1:57 PM
> To: Mukul Sharma
> Subject: Re: DPF (database partitioning feature) Memory allocaton
issue
> - Please advice
>
> **A LazyDBA.com subscriber has responded to your lazydba.com post**
> **LazyDBA.com mail shield has forwarded you this email,
> **and removed any attachments, and kept your email address secret
> **from this person, and any viruses/trojans.
> **If you reply to this email, the person will see your email address
as
> normal
> **Anything below this line is the original email text
>
>
> Pardon me if what I am saying is too obvious, but did you remember
> db2_all when you updated your db cfg parms?
> -Andy Beaton
>
> Mukul Sharma wrote:
>
>> Db2 Gurus,
>>
>>
>>
>> We are trying to implement DPF (database partitioning Feature) at our
>> site and having problems allocating shared memory.
>>
>>
>>
>> It' a 64 bit instance, 8 logical partitions all residing on one
>>
> machine
>
>> with 8 gigs of RAM. Below is the configuration:
>>
>>
>>
>> Machine:
>>
>>
>>
>> [Email address protected] ~]$ uname -a
>>
>> Linux qa-devdb2 2.6.9-34.ELsmp #1 SMP Fri Feb 24 16:56:28 EST 2006
>> x86_64 x86_64 x86_64 GNU/Linux
>>
>>
>>
>> Db2level:
>>
>>
>>
>> DB21085I Instance "d2swnrxb" uses "64" bits and DB2 code release
>> "SQL08027"
>>
>> with level identifier "03080106".
>>
>> Informational tokens are "DB2 v8.1.3.128", "s061108", "MI00180", and
>> FixPak
>>
>> "14".
>>
>> Product is installed at "/opt/IBM/db2/V8.1".
>>
>>
>>
>> Appgroup mem parameters are as below:
>>
>>
>>
>> Max size of appl. group mem set (4KB) (APPGROUP_MEM_SZ) = 64000
>>
>> Percent of mem for appl. group heap (GROUPHEAP_RATIO) = 22
>>
>> Max appl. control heap size (4KB) (APP_CTL_HEAP_SZ) = 800
>>
>> Default application heap (4KB) (APPLHEAPSZ) = 256
>>
>> Percent. of lock lists per application (MAXLOCKS) = 30
>>
>> Max number of active applications (MAXAPPLS) = 80
>>
>> Average number of active applications (AVG_APPLS) = 5
>>
>> Max DB files open per application (MAXFILOP) = 256
>>
>>
>>
>> We start seeing memory allocation errors with the error code as
below:
>>
>
>
>> SQL1084C Shared memory segments cannot be allocated. SQLSTATE=57019
>>
>>
>>
>> I am sure we have got free memory available on the OS side.
>>
>>
>>
>> [Email address protected] ~]$ free -mt
>>
>> total used free shared buffers
>> cached
>>
>> Mem: 7817 5857 1959 0 43
>> 5384
>>
>> -/+ buffers/cache: 429 7387
>>
>> Swap: 16386 0 16386
>>
>> Total: 24204 5857 18346
>>
>>
>>
>> Please advice.
>>
>>
>>
>> Thanks,
>>
>>
>>
>> -- Mukul
>>
>>
>>
>>
>>
>>
>>
>
************************************************************************
> **
>
>> DemandTec Email Notice
>>
>> This email and any attachments may contain confidential and/or
>>
> proprietary information and is intended solely for the use of the
> addressee. If you are not the intended recipient we request that you
> notify us via email or telephone and delete all copies of the message
> from your systems. Additionally, although DemandTec has taken
reasonable
> precautions to ensure the security of this email and any attachments,
we
> encourage you to take similar precautions and accept no liability for
> any loss or damage resulting from its use.
>
>> DemandTec, 1 Circle Star Way, Suite 200, San Carlos, CA 94070,
>>
> 650-226-4600
>
>> ---------------------------------------------------------------------
>> TO REPLY TO EVERBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY
>> To post a dba job: http://jobs.lazydba.com
>> To Subscribe : http://www.LazyDBA.com
>> To unsubscribe: http://www.lazydba.com/unsubscribe.html
>>
>>
>>
>
>
>
>
DB2 & UDB email list listserv db2-l LazyDBA home page