dbTalk Databases Forums  

Problem with 7.4.1 and complicated queries

comp.databases.postgresql.general comp.databases.postgresql.general


Discuss Problem with 7.4.1 and complicated queries in the comp.databases.postgresql.general forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jonathan Weiss
 
Posts: n/a

Default Problem with 7.4.1 and complicated queries - 10-23-2004 , 05:23 PM






Cheers,

I have a problem with postgresql7.4.1 on a SuSE machine. I use the
database for a C#-application for a small company to store their
clients, sales, etc... This all works flawless since 1 year. Since 2
weeks the database hangs if I perform long queries with views involved
in order to generate long reports about sales per month per categorie
and so on. The database does not respond and only I dump the database
and work on the dump I can continue. Working on the old set does not
work.

Each night, I run vacuumdb, but it does not help.

Is this something known?

I can send you more information if needed.

Thanks,
Jonathan

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo (AT) postgresql (DOT) org so that your
message can get through to the mailing list cleanly


Reply With Quote
  #2  
Old   
Jonathan Weiss
 
Posts: n/a

Default Re: Problem with 7.4.1 and complicated queries - 10-24-2004 , 03:00 PM






Hi!

Quote:
This sounds like maybe you're FSM settings aren't high enough, or you
aren't analyzing your tables.
I doubled the values for max_fsm_pages and max_fsm_relations.

Quote:
Try vacuum full and analyze first, and see if that fixes the problem.
If so, then you either need to vacuum more often, increase your fsm
ssettings, (or both) and probably need to schedule regular analyzes.
I tried vacuum full and analyze, but the problem still remains. The
funny thing is, that working on a fresh dumped version works.


Greets,
Jonathan

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo (AT) postgresql (DOT) org)



Reply With Quote
  #3  
Old   
Jonathan Weiss
 
Posts: n/a

Default Re: Problem with 7.4.1 and complicated queries - 11-10-2004 , 04:25 PM



Cheers,

The Problems with the database still show up.
We upgraded the database to 7.4.6

From postgresql.conf:
shared_buffers = 10000 # min 16, at least max_connections*2, 8KB each
sort_mem = 2048 # min 64, size in KB
vacuum_mem = 8192 # min 1024, size in KB
# - Free Space Map -
max_fsm_pages = 50000 # min max_fsm_relations*16, 6 bytes each
max_fsm_relations = 3000 # min 100, ~50 bytes each

The sympton is that one report that uses a long querie freezes, the
correospondig process uses 98% CPU. If I dump the database und run the
querie on the new database, everything works fine. SO I justed made
the customer a new database and used the backup for the data. But on
the nex day, same thing. The reports would freeze. This only happens
with one report, not always with the same querie. But if I run the
query over the CLI, it also freezes, so it is not the gui or a network
timeout. This query worked for over one year, nobody changed
something.

VACUUM FULL ; ANALYZE;

will not change anything.

Any hints?

Thank you,
Jonathan

On Sun, 24 Oct 2004 22:00:09 +0200, Jonathan Weiss <joweiss (AT) gmail (DOT) com> wrote:
Quote:
Hi!


This sounds like maybe you're FSM settings aren't high enough, or you
aren't analyzing your tables.

I doubled the values for max_fsm_pages and max_fsm_relations.

Try vacuum full and analyze first, and see if that fixes the problem.
If so, then you either need to vacuum more often, increase your fsm
ssettings, (or both) and probably need to schedule regular analyzes.

I tried vacuum full and analyze, but the problem still remains. The
funny thing is, that working on a fresh dumped version works.

Greets,
Jonathan

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

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



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.