Re: Parameter value in RDS
От | Philip Semanchuk |
---|---|
Тема | Re: Parameter value in RDS |
Дата | |
Msg-id | 076AB39D-C58A-4C28-B5A7-D08877C190A4@americanefficient.com обсуждение исходный текст |
Ответ на | Re: Parameter value in RDS ("David G. Johnston" <david.g.johnston@gmail.com>) |
Список | pgsql-general |
> On Jan 16, 2024, at 4:19 PM, David G. Johnston <david.g.johnston@gmail.com> wrote: > > On Tuesday, January 16, 2024, Atul Kumar <akumar14871@gmail.com> wrote: > Hi, > > I am new to RDS postgres, I have version 14 running on it with m7g.large > > I found that lots of parameters has DBInstanceClassMemory written, so what exactly is the value of this variable ? > > How should I calculate it? > > IIRC it’s the amount of RAM on your instance. You look it up in a table usually. Or check the web console. Yes, I’m pretty sure that it’s the amount of RAM *in bytes*. Although I like the flexibility of having that expressed in a variable, it wan’t always as easy to use as I wanted it tobe. Specifically, I found that differences in units made it a little difficult to figure out how AWS was configuring things. For example, on an old instance we had, shared_buffers was defined as {DBInstanceClassMemory/10922}. It took me a while tofigure out that that translates to “calculate 75% of available memory, and express that value in 8Kb blocks”. How? Well,10922 = 8 * 1024 * 1.33333. shared_buffers is expressed in 8Kb blocks, so converting from units of bytes (DBInstanceClassMemory)to 8kB blocks (shared_buffers) requires dividing by 8 * 1024. And dividing by 1.3333 is the same asmultiplying by 3/4, which is 75%. This may have been explained in AWS documentation but I couldn’t find it at the time and it took some work on my part tofigure out the logic behind 10922 and some other config magic numbers. Maybe this will save you some time. Cheers Philip
В списке pgsql-general по дате отправления: