Обсуждение: Pgsql crashes frequently

Поиск
Список
Период
Сортировка

Pgsql crashes frequently

От
"Ganesan Kanavathy"
Дата:
We are running Postgresql db and it crashes almost every hour Unable to load up pgsql after a crash.
 
We need to restart the server to start back pg.
 
What would be the cause of this problem. Please help.
 
Regards,
ganesh
 
 

Re: Pgsql crashes frequently

От
"scott.marlowe"
Дата:
On Tue, 7 Oct 2003, Ganesan Kanavathy wrote:

> We are running Postgresql db and it crashes almost every hour Unable to
> load up pgsql after a crash.
>
> We need to restart the server to start back pg.
>
> What would be the cause of this problem. Please help.

Bad hardware.  Check for bad memory, CPU, or hard drive.

Or, your machine is running low on memory and the kernel is killing
processes randomly to free up memory.  That's not as likely, but it does
happen in some setups.

www.memtest86.com for a decent free memory tester for X86 architecture.


Re: Pgsql crashes frequently

От
"Ganesan Kanavathy"
Дата:

When I check the logfile it is stated there:

"pcMemoryCreate: shmget(key=5432001, size=1466368, 03600) failed: Invalid argument

This error usually means that PostgreSQL's request for a shared memory segment exceeded your kernel's SHMMAX parameter.  You can either reduce the request size or reconfigure the kernel with larger SHMMAX.

To reduce the request size (currently 1466368 bytes), reduce PostgreSQL's shared_buffers parameter (currently 64) and/or its max_connections parameter (currently 32).

If the request size is already small, it's possible that it is less than your kernel's SHMMIN parameter, in which case raising the request size or reconfiguring SHMMIN is called for.

The PostgreSQL Administrator's Guide contains more information about shared memory configuration."


I really got no idea what this means. How do I solve this?

What SHMMAX and SHMMIN and how I calculate this value? I have a 1GB of memory.


Regards,
ganesh






-----Original Message-----
From: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of scott.marlowe
Sent: Tuesday, October 07, 2003 10:36 PM
To: Ganesan Kanavathy
Cc: pgsql-admin@postgresql.org
Subject: Re: [ADMIN] Pgsql crashes frequently


On Tue, 7 Oct 2003, Ganesan Kanavathy wrote:

> We are running Postgresql db and it crashes almost every hour Unable
> to load up pgsql after a crash.

> We need to restart the server to start back pg.

> What would be the cause of this problem. Please help.

Bad hardware.  Check for bad memory, CPU, or hard drive.

Or, your machine is running low on memory and the kernel is killing
processes randomly to free up memory.  That's not as likely, but it does
happen in some setups.

www.memtest86.com for a decent free memory tester for X86 architecture.


---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faqs/FAQ.html

Re: Pgsql crashes frequently

От
"scott.marlowe"
Дата:
this page should have the information you need to fix that problem:

http://www.postgresql.org/docs/7.3/static/kernel-resources.html

Let me know if that doesn't take care of the issue.

On Wed, 8 Oct 2003, Ganesan Kanavathy wrote:

> When I check the logfile it is stated there:
>
> "pcMemoryCreate: shmget(key=5432001, size=1466368, 03600) failed:
> Invalid argument
>
> This error usually means that PostgreSQL's request for a shared memory
> segment exceeded your kernel's SHMMAX parameter.  You can either reduce
> the request size or reconfigure the kernel with larger SHMMAX.
>
> To reduce the request size (currently 1466368 bytes), reduce
> PostgreSQL's shared_buffers parameter (currently 64) and/or its
> max_connections parameter (currently 32).
>
> If the request size is already small, it's possible that it is less than
> your kernel's SHMMIN parameter, in which case raising the request size
> or reconfiguring SHMMIN is called for.
>
> The PostgreSQL Administrator's Guide contains more information about
> shared memory configuration."
>
> I really got no idea what this means. How do I solve this?
>
> What SHMMAX and SHMMIN and how I calculate this value? I have a 1GB of
> memory.
>
> Regards,
> ganesh
>
>
>
>
>
> -----Original Message-----
> From: pgsql-admin-owner@postgresql.org
> [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of scott.marlowe
> Sent: Tuesday, October 07, 2003 10:36 PM
> To: Ganesan Kanavathy
> Cc: pgsql-admin@postgresql.org
> Subject: Re: [ADMIN] Pgsql crashes frequently
>
>
> On Tue, 7 Oct 2003, Ganesan Kanavathy wrote:
>
> > We are running Postgresql db and it crashes almost every hour Unable
> > to load up pgsql after a crash.
> >
> > We need to restart the server to start back pg.
> >
> > What would be the cause of this problem. Please help.
>
> Bad hardware.  Check for bad memory, CPU, or hard drive.
>
> Or, your machine is running low on memory and the kernel is killing
> processes randomly to free up memory.  That's not as likely, but it does
> happen in some setups.
>
> www.memtest86.com for a decent free memory tester for X86 architecture.
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
>                http://www.postgresql.org/docs/faqs/FAQ.html
>
>
>


Re: Pgsql crashes frequently

От
"Anis W. Nugroho"
Дата:
If you're using Linus, change those settings (semaphores) with a
root account.

Edit /etc/sysctl.conf to add the setting below (adjust the value
properly)
    kernel.shmmni = xxxx
    kernel.shmmax = xxxx

Execute
    sysctl -p

Good luck,
Anis WN
________________________________
15 Mbytes Free Web-based and  POP3
Sign up now: http://www.gawab.com