Re: FW: [HACKERS] Changing the default configuration (was Re:

2003-02-18 Thread Justin Clift
Hi everyone, Just looked on the IBM website for info relating to shared memory and IPC limits in AIX, and found a few useful-looking documents: The Interprocess Communication (IPC) Overview http://www-1.ibm.com/support/docview.wss?rs=0&context=SWG10&q=shmget&uid=aix15f11dd1d98f3551f85256816006a0

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-17 Thread Bruce Momjian
People seemed to like the idea: Add a script to ask system configuration questions and tune postgresql.conf. --- Bruce Momjian wrote: > Peter Eisentraut wrote: > > Tom Lane writes: > > > > > Well, as I com

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-14 Thread Tilo Schwarz
Bruce Momjian writes: > Tom Lane wrote: > > Bruce Momjian <[EMAIL PROTECTED]> writes: > > > So, my idea is to add a message at the end of initdb that states people > > > should run the pgtune script before running a production server. > > > > Do people read what initdb has to say? > > > > IIRC, the

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-14 Thread Jason Hihn
>Nutshell: > "Easy to install but is horribly slow." > > or > > "Took a couple of minutes to configure and it rocks!" Since when is it easy to install on win32? The easiest way I know of is through Cygwin, then you have to worry about installing the IPC service (an gettin

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-13 Thread Kevin Brown
Bruce Momjian wrote: > We could prevent the postmaster from starting unless they run pg_tune or > if they have modified postgresql.conf from the default. Of course, > that's pretty drastic. If you're going to do that, then you may as well make the defaults something that will perform reasonably w

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-13 Thread Kevin Brown
Josh Berkus wrote: > > > Uh ... do we have a basis for recommending any particular sets of > > > parameters for these different scenarios? This could be a good idea > > > in the abstract, but I'm not sure I know enough to fill in the details. > > Sure. > Mostly-Read database, few users, good ha

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-13 Thread Greg Stark
> On Wed, 12 Feb 2003, Bruce Momjian wrote: > > > > And part of the reason is because some/most BSD's map the page tables > > into physical RAM (kernel space) rather than use some shared page table > > mechanism. This is good because it prevents the shared memory from > > being swapped out (perfor

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-13 Thread Bruce Momjian
I was speaking of the 4.4 BSD. FreeBSD has the merged VM, and I think NetBSD only recently did that. BSD/OS does do the locking by default and it maps into the kernel address space. I believe FreeBSD has a sysctl to control locking of SysV memory. One advantage of having it all at the same VM

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-13 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > So, my idea is to add a message at the end of initdb that states people > > should run the pgtune script before running a production server. > > Do people read what initdb has to say? > > IIRC, the RPM install scripts hide initdb's o

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-13 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > So, my idea is to add a message at the end of initdb that states people > should run the pgtune script before running a production server. Do people read what initdb has to say? IIRC, the RPM install scripts hide initdb's output from the user entirely.

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-13 Thread Curt Sampson
On Wed, 12 Feb 2003, Bruce Momjian wrote: > Christopher Kings-Lynne wrote: > > > You cannot change SHMMAX on the fly on FreeBSD. > > And part of the reason is because some/most BSD's map the page tables > into physical RAM (kernel space) rather than use some shared page table > mechanism. This is

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-12 Thread Bruce Momjian
Peter Eisentraut wrote: > Tom Lane writes: > > > Well, as I commented later in that mail, I feel that 1000 buffers is > > a reasonable choice --- but I have to admit that I have no hard data > > to back up that feeling. > > I know you like it in that range, and 4 or 8 MB of buffers by default > s

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Tom Lane
>> You cannot change SHMMAX on the fly on FreeBSD. I think we suffered some topic drift here --- wasn't the last question about whether SEMMAX can be increased on-the-fly? That wouldn't have anything to do with memory-mapping strategies... regards, tom lane -

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-12 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > I know you like it in that range, and 4 or 8 MB of buffers by default > should not be a problem. But personally I think if the optimal buffer > size does not depend on both the physical RAM you want to dedicate to > PostgreSQL and the nature and size

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Bruce Momjian
Christopher Kings-Lynne wrote: > > Seriously, I know Linux can change these on the fly, and I'm pretty sure > > Solaris can too. I haven't played with BSD for a while so can't speak > > about that. Anyone else know? > > You cannot change SHMMAX on the fly on FreeBSD. And part of the reason is

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Larry Rosenman
--On Thursday, February 13, 2003 09:47:28 +0800 Christopher Kings-Lynne <[EMAIL PROTECTED]> wrote: Seriously, I know Linux can change these on the fly, and I'm pretty sure Solaris can too. I haven't played with BSD for a while so can't speak about that. Anyone else know? You cannot change S

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Christopher Kings-Lynne
> Seriously, I know Linux can change these on the fly, and I'm pretty sure > Solaris can too. I haven't played with BSD for a while so can't speak > about that. Anyone else know? You cannot change SHMMAX on the fly on FreeBSD. Chris ---(end of broadcast)-

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-12 Thread Peter Eisentraut
Tom Lane writes: > Well, as I commented later in that mail, I feel that 1000 buffers is > a reasonable choice --- but I have to admit that I have no hard data > to back up that feeling. I know you like it in that range, and 4 or 8 MB of buffers by default should not be a problem. But personally

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread scott.marlowe
On Tue, 11 Feb 2003, Tom Lane wrote: > "scott.marlowe" <[EMAIL PROTECTED]> writes: > > ... If he starts running out of semaphores, that's a > > problem he can address while his database is still up and running in most > > operating systems, at least in the ones I use. > > Back in the day, this

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Andrew Sullivan
On Tue, Feb 11, 2003 at 05:32:58PM -0700, scott.marlowe wrote: > So, what OSes would have a problem, if any, with boosting something > like max connects to 200? What are the breaking points on other OSes? Solaris 8 broke at 200, the last time I tried on a new box. 150 didn't break it, though.

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Rod Taylor
On Wed, 2003-02-12 at 11:39, Andrew Sullivan wrote: > On Tue, Feb 11, 2003 at 05:25:29PM -0700, Rick Gigger wrote: > > > The type of person who can't configure it or doesnt' think to try is > > probably not doing a project that requires any serious performance. > > I have piles of email, have fie

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-12 Thread Andrew Sullivan
On Tue, Feb 11, 2003 at 05:25:29PM -0700, Rick Gigger wrote: > The type of person who can't configure it or doesnt' think to try is > probably not doing a project that requires any serious performance. I have piles of email, have fielded thousands of phone calls, and have had many conversations w

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-12 Thread Daniel Kalchev
>>>"scott.marlowe" said: > On 11 Feb 2003, Greg Copeland wrote: > > Besides, I'm not sure that it makes sense to let other product needs > > dictate the default configurations for this one. It would be one thing > > if the vast majority of people only used PostgreSQL with Apache. I know > >

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Shridhar Daithankar<[EMAIL PROTECTED]>
On Tuesday 11 Feb 2003 10:56 pm, you wrote: > Josh Berkus <[EMAIL PROTECTED]> writes: > > What if we supplied several sample .conf files, and let the user choose > > which to copy into the database directory? We could have a "high read > > performance" profile, and a "transaction database" profil

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Christopher Kings-Lynne
> A separate line of investigation is "what is the lowest common > denominator nowadays?" I think we've established that SHMMAX=1M > is obsolete, but what replaces it as the next LCD? 4M seems to be > correct for some BSD flavors, and I can confirm that that's the > current default for Mac OS X -

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Christopher Kings-Lynne
> >> We could retarget to try to stay under SHMMAX=4M, which I think is > >> the next boundary that's significant in terms of real-world platforms > >> (isn't that the default SHMMAX on some BSDen?). That would allow us > >> 350 or so shared_buffers, which is better, but still not really a > >> se

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > Tom Lane writes: >> We could retarget to try to stay under SHMMAX=4M, which I think is >> the next boundary that's significant in terms of real-world platforms >> (isn't that the default SHMMAX on some BSDen?). That would allow us >> 350 or so shared_

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread Tom Lane
"scott.marlowe" <[EMAIL PROTECTED]> writes: > ... The original choice of 32 was set because the original > choice of 64 shared memory blocks as the most we could hope for on common > OS installs. Now that we're looking at cranking that up to 1000, > shouldn't max connections get a look too? Ac

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Christopher Kings-Lynne
> >After it's all said and done, I would rather someone simply say, "it's > >beyond my skill set", and attempt to get help or walk away. That seems > >better than them being able to run it and say, "it's a dog", spreading > >word-of-mouth as such after they left PostgreSQL behind. Worse yet, > >t

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Bruno Wolff III
On Tue, Feb 11, 2003 at 17:42:06 -0700, "scott.marlowe" <[EMAIL PROTECTED]> wrote: > > The poor performance of Postgresql in it's current default configuration > HAS cost us users, trust me, I know a few we've almost lost where I work > that I converted after some quick tweaking of their datab

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread scott.marlowe
On Wed, 12 Feb 2003, Curt Sampson wrote: > On Tue, 11 Feb 2003, Tom Lane wrote: > > > It's a lot too conservative. I've been thinking for awhile that we > > should adjust the defaults. > > Some of these issues could be made to Just Go Away with some code > changes. For example, using mmap rathe

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread scott.marlowe
On Tue, 11 Feb 2003, Rick Gigger wrote: > The type of person who can't configure it or doesnt' think to try is > probably not doing a project that requires any serious performance. As long > as you are running it on decent hardware postgres will run fantastic for > anything but a very heavy load.

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Curt Sampson
On Tue, 11 Feb 2003, Tom Lane wrote: > It's a lot too conservative. I've been thinking for awhile that we > should adjust the defaults. Some of these issues could be made to Just Go Away with some code changes. For example, using mmap rather than SysV shared memory would automatically optimize y

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread scott.marlowe
On Tue, 11 Feb 2003, Merlin Moncure wrote: > Here's the comment I was referring to: > > /* > * InitProcGlobal - > * initializes the global process table. We put it here so that > * the postmaster can do this initialization. > * > * We also create all the per-process semaphores

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Rick Gigger
> On Tue, 2003-02-11 at 10:20, Tom Lane wrote: > > "Merlin Moncure" <[EMAIL PROTECTED]> writes: > > > May I make a suggestion that maybe it is time to start thinking about > > > tuning the default config file, IMHO its just a little bit too > > > conservative, > > > > It's a lot too conservative.

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Lamar Owen
On Tuesday 11 February 2003 13:03, Robert Treat wrote: > On Tue, 2003-02-11 at 12:08, Justin Clift wrote: > > b) Said benchmarking person knows very little about PostgreSQL, so they > > install the RPM's, packages, or whatever, and "it works". Then they run > > whatever benchmark they've downloade

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Peter Eisentraut
Tom Lane writes: > We could retarget to try to stay under SHMMAX=4M, which I think is > the next boundary that's significant in terms of real-world platforms > (isn't that the default SHMMAX on some BSDen?). That would allow us > 350 or so shared_buffers, which is better, but still not really a >

FW: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread Merlin Moncure
True, but even so, 32 max connections is a bit light. I have more pgsql databases than that on my box now. My point in my previous answer to Tom was that you HAVE to shut down postgresql to change this. It doesn't allocate tons of semaphores on startup, [snip] is this correct? I recall loo

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread scott.marlowe
On 11 Feb 2003, Greg Copeland wrote: > On Tue, 2003-02-11 at 12:55, Tom Lane wrote: > > "scott.marlowe" <[EMAIL PROTECTED]> writes: > > > Is setting the max connections to something like 200 reasonable, or likely > > > to cause too many problems? > > > > That would likely run into number-of-sema

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread scott.marlowe
On Tue, 11 Feb 2003, Tom Lane wrote: > "scott.marlowe" <[EMAIL PROTECTED]> writes: > > Is setting the max connections to something like 200 reasonable, or likely > > to cause too many problems? > > That would likely run into number-of-semaphores limitations (SEMMNI, > SEMMNS). We do not seem to

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Jeff Hoffmann
Tom Lane wrote: I think that what this discussion is really leading up to is that we are going to decide to apply the same principle to performance. The out-of-the-box settings ought to give reasonable performance, and if your system can't handle it, you should have to take explicit action to ac

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread Greg Copeland
On Tue, 2003-02-11 at 12:55, Tom Lane wrote: > "scott.marlowe" <[EMAIL PROTECTED]> writes: > > Is setting the max connections to something like 200 reasonable, or likely > > to cause too many problems? > > That would likely run into number-of-semaphores limitations (SEMMNI, > SEMMNS). We do not

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Tom Lane
"scott.marlowe" <[EMAIL PROTECTED]> writes: > Is setting the max connections to something like 200 reasonable, or likely > to cause too many problems? That would likely run into number-of-semaphores limitations (SEMMNI, SEMMNS). We do not seem to have as good documentation about changing that as

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Matthew T. O'Connor
On Tue, 2003-02-11 at 13:01, Tom Lane wrote: > "Jon Griffin" <[EMAIL PROTECTED]> writes: > > So it appears that linux at least is way above your 8 meg point, unless I > > am missing something. > > Yeah, AFAIK all recent Linuxen are well above the range of parameters > that I was suggesting (and ev

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread scott.marlowe
My other pet peeve is the default max connections setting. This should be higher if possible, but of course, there's always the possibility of running out of file descriptors. Apache has a default max children of 150, and if using PHP or another language that runs as an apache module, it is qu

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread mlw
Apology After Mark calms down and, in fact, sees that Greg was saying the right thing after all, chagrin is the only word. I'm sorry. Greg Copeland wrote: On Tue, 2003-02-11 at 11:23, mlw wrote: Greg Copeland wrote: I'd personally rather have people stumble

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Robert Treat
On Tue, 2003-02-11 at 12:08, Justin Clift wrote: > b) Said benchmarking person knows very little about PostgreSQL, so they > install the RPM's, packages, or whatever, and "it works". Then they run > whatever benchmark they've downloaded, or designed, or whatever > Out of curiosity, how feasibl

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Tom Lane
mlw <[EMAIL PROTECTED]> writes: > This attitude sucks. If you want a product to be used, you must put the > effort into making it usable. > [snip] AFAICT, you are flaming Greg for recommending the exact same thing you are recommending. Please calm down and read again. re

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Tom Lane
Justin Clift <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Uh ... do we have a basis for recommending any particular sets of >> parameters for these different scenarios? This could be a good idea >> in the abstract, but I'm not sure I know enough to fill in the details. > Without too much hack

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Josh Berkus
Tom, Justin, > > Uh ... do we have a basis for recommending any particular sets of > > parameters for these different scenarios? This could be a good idea > > in the abstract, but I'm not sure I know enough to fill in the details. Sure. Mostly-Read database, few users, good hardware, complex q

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Justin Clift
Tom Lane wrote: Uh ... do we have a basis for recommending any particular sets of parameters for these different scenarios? This could be a good idea in the abstract, but I'm not sure I know enough to fill in the details. A lower-tech way to accomplish the same result is to document these alter

Re: [HACKERS] Changing the default configuration (was Re:

2003-02-11 Thread Greg Copeland
On Tue, 2003-02-11 at 11:23, mlw wrote: > Greg Copeland wrote: > > > > > > >I'd personally rather have people stumble trying to get PostgreSQL > >running, up front, rather than allowing the lowest common denominator > >more easily run PostgreSQL only to be disappointed with it and move on. > > >

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Justin Clift
Josh Berkus wrote: Tom, Justin, What if we supplied several sample .conf files, and let the user choose which to copy into the database directory? We could have a "high read performance" profile, and a "transaction database" profile, and a "workstation" profile, and a "low impact" profile

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Tom Lane
Josh Berkus <[EMAIL PROTECTED]> writes: > What if we supplied several sample .conf files, and let the user choose which > to copy into the database directory? We could have a "high read > performance" profile, and a "transaction database" profile, and a > "workstation" profile, and a "low impac

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Kaare Rasmussen
> What if we supplied several sample .conf files, and let the user choose > which to copy into the database directory? We could have a "high read Exactly my first thought when reading the proposal for a setting suited for performance tests. > performance" profile, and a "transaction database"

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Rod Taylor
On Tue, 2003-02-11 at 12:10, Steve Crawford wrote: > A quick-'n'-dirty first step would be more comments in postgresql.conf. Most This will not solve the issue with the large number of users who have no interest in looking at the config file -- but are interested in publishing their results. --

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Josh Berkus
Tom, Justin, > > What I would really like to do is set the default shared_buffers to > > 1000. That would be 8 meg worth of shared buffer space. Coupled with > > more-realistic settings for FSM size, we'd probably be talking a shared > > memory request approaching 16 meg. This is not enough RAM

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread mlw
Greg Copeland wrote: I'd personally rather have people stumble trying to get PostgreSQL running, up front, rather than allowing the lowest common denominator more easily run PostgreSQL only to be disappointed with it and move on. After it's all said and done, I would rather someone simply s

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Justin Clift
Tom Lane wrote: What I would really like to do is set the default shared_buffers to 1000. That would be 8 meg worth of shared buffer space. Coupled with more-realistic settings for FSM size, we'd probably be talking a shared memory request approaching 16 meg. This is not enough RAM to bother a

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread mlw
Tom Lane wrote: "Merlin Moncure" <[EMAIL PROTECTED]> writes: May I make a suggestion that maybe it is time to start thinking about tuning the default config file, IMHO its just a little bit too conservative, It's a lot too conservative. I've been thinking for awhile t

Re: [HACKERS] Changing the default configuration (was Re: [pgsql-advocacy]

2003-02-11 Thread Greg Copeland
On Tue, 2003-02-11 at 10:20, Tom Lane wrote: > "Merlin Moncure" <[EMAIL PROTECTED]> writes: > > May I make a suggestion that maybe it is time to start thinking about > > tuning the default config file, IMHO its just a little bit too > > conservative, > > It's a lot too conservative. I've been thi