PostgreSQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesPostgreSQL Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old January 16th, 2004, 02:34 PM
metaBarf metaBarf is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Posts: 373 metaBarf User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 49 m 6 sec
Reputation Power: 6
some questions about postgresql.conf

###Sorry for the double post, my browser is acting weird

I've been considering modifying this file according to the server that it is installed on to make better use of the system resources. The machine is a dedicated postgres server, so I think that changing memory allocation and so forth should be for the better. However, I'm not sure about some of the parameters. For instance,

the Optimizer Parameters portion that has
enable_seqscan
enable_indexscan

and so forth, these options are commented out. So by default are they set to the value shown in the file, the same as the enable_tcpip option?

My main other question involves the shared_buffers parameter in the Shared Memory Size section.

This value has a comment that says "2xmax_connections, min 16". However, in the document that I'm reading about such configurations by Bruce Momjian, he says, "The default POSTGRESQL configuration allocates 1000 shared buffers." but the number in my postgresql.conf file is something like 64. So, which is it? Should I change this to 100, which would be 2x50 max_connections? or should it be 1000 or something, as I belive is indicated by Bruce? The article by him that I am referring to is this one

Thanks in advance for any recommendations!

Last edited by metaBarf : January 16th, 2004 at 02:39 PM.

Reply With Quote
  #2  
Old January 16th, 2004, 03:57 PM
bcyde's Avatar
bcyde bcyde is offline
Me likey breadsticks...
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Jan 2003
Location: Los Angeles
Posts: 1,189 bcyde User rank is Sergeant (500 - 2000 Reputation Level)bcyde User rank is Sergeant (500 - 2000 Reputation Level)bcyde User rank is Sergeant (500 - 2000 Reputation Level)bcyde User rank is Sergeant (500 - 2000 Reputation Level)bcyde User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 1 h 12 m 58 sec
Reputation Power: 12
Send a message via AIM to bcyde Send a message via Yahoo to bcyde
The default of 64 shared buffers was changed to 1000 in recent versions of Postgres. For the best settings of how to calculate shared buffers check the varlena links (written by Josh Berkus and Shridhar Daithankar sp?) that rycamor posted at the top of this PG forum for postgres performance tweaking. Those are the most comprehensive and up to date documents regarding postgres performance tweaking as of this post.

Also you should not change the values for enable_seqscan or enable_indexscan, these should both be enabled by default. Basically if you turn off enable_seqscan then queries will always try to use indexes which is NOT always the best query plan in the case of small tables and result sets. Also, if you do have to disable these options, you can do so per query, and not on a global scale via the .conf. Also, if you are getting poor query plans it probably means you might need to adjust the settings in the postgresql.conf to give better hints to the query planner instead of using measures like disabling sequence scans or adjust your actual query instead.

HTH,
-b
__________________
PostgreSQL, it's what's for dinner...

Last edited by bcyde : January 16th, 2004 at 03:59 PM.

Reply With Quote
  #3  
Old January 16th, 2004, 05:32 PM
metaBarf metaBarf is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Posts: 373 metaBarf User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 49 m 6 sec
Reputation Power: 6
thank you sir

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesPostgreSQL Help > some questions about postgresql.conf


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway
Stay green...Green IT