Search Postgresql Archives

Re: Can I have a look at your TuningWizard generated config file?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hmm.. not done quite yet it seems :(

I tried initially to set shared_buffers to 1024MB but I got this message : 

2009-08-01 15:04:46 CESTFATAL:  could not create shared memory segment: Invalid argument
2009-08-01 15:04:46 CESTDETAIL:  Failed system call was shmget(key=5432001, size=1106247680, 03600).
2009-08-01 15:04:46 CESTHINT:  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 1106247680 bytes), reduce PostgreSQL's shared_buffers parameter (currently 131072) and/or its max_connections parameter (currently 153).
        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.

Lowered it to 64MB and same thing happen. Changed to 128kB and the server started. 

Reading on shared_buffers thing on  http://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Server I can see that this seems to be something expected, but I am confused on how to fix this ... 

sysctl -a | grep -i shm
error: permission denied on key 'net.ipv4.route.flush'
error: permission denied on key 'net.ipv6.route.flush'
kernel.shmmax = 33554432
kernel.shmall = 2097152
kernel.shmmni = 4096
vm.hugetlb_shm_group = 0

I am running Ubuntu Server 9.04 so I am guessing I should be looking under Linux on  http://www.postgresql.org/docs/current/static/kernel-resources.html

I am confused about this part : 
$ sysctl -w kernel.shmmax=134217728
$ sysctl -w kernel.shmall=2097152

In addition these settings can be saved between reboots in /etc/sysctl.conf.

Should I just append that file with two lines : 

kernel.shmmax=10486808576
kernel.shmmall=?? What should be here? Leave it alone? I am thinking I shouldn't include this, only the above one... right?

Thanks in advance / Jen


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux