Postgresql tuning in Mac OS

A special forum dedicated to our PT4 for Mac OS X users

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Postgresql tuning in Mac OS

Postby KobeBryantLA » Sat Aug 24, 2013 2:43 pm

Hello,

I have a Mac Mini Late 2012 with 16 GB RAM, PT4 running in Mac OS and a huge 150 GB Database. As you can imagine it works very slow with the default settings. What changes in config files do you recommend to increase the performance? Is there any FAQ for this?
KobeBryantLA
 
Posts: 12
Joined: Sun Aug 31, 2008 10:58 am

Re: Postgresql tuning in Mac OS

Postby kraada » Sun Aug 25, 2013 2:12 pm

Our database tuning should work for OS X as well - you can access it via the Housekeeping button in the Database Management window - it should take care of everything you need.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Postgresql tuning in Mac OS

Postby KobeBryantLA » Sun Aug 25, 2013 2:28 pm

kraada wrote:Our database tuning should work for OS X as well - you can access it via the Housekeeping button in the Database Management window - it should take care of everything you need.

I used it Windows, but in Mac OS there is no such button in Database Management window.
KobeBryantLA
 
Posts: 12
Joined: Sun Aug 31, 2008 10:58 am

Re: Postgresql tuning in Mac OS

Postby kraada » Sun Aug 25, 2013 8:43 pm

I'll ask our Mac guy tomorrow what he recommends for you.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Postgresql tuning in Mac OS

Postby KobeBryantLA » Tue Aug 27, 2013 5:25 am

kraada wrote:I'll ask our Mac guy tomorrow what he recommends for you.

Any news?
KobeBryantLA
 
Posts: 12
Joined: Sun Aug 31, 2008 10:58 am

Re: Postgresql tuning in Mac OS

Postby kraada » Tue Aug 27, 2013 9:49 am

Use the numbers listed here -- you'll have to make the changes manually though. To do this, open Applications -> Utilities -> Terminal and type:
sudo nano /Library/PostgreSQL/9.0/data/postgresql.conf

After making the changes, ctrl+x exits the program (save the changes when prompted) and reboot your machine and that should do it.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Postgresql tuning in Mac OS

Postby KobeBryantLA » Thu Aug 29, 2013 10:05 am

I set parameters like this
Code: Select all
shared_buffers = 2048MB   
work_mem = 256MB
maintenance_work_mem = 1024MB   

Changed sysctl.conf to
Code: Select all
kern.sysv.shmall=537466   
kern.sysv.shmmax=2201460736
kern.sysv.shmmin=1
kern.sysv.shmmni=256
kern.sysv.shmseg=64

But still have bad performance.
Any thoughts?
Attachments
Снимок экрана 2013-08-29 в 18.01.34.png
Снимок экрана 2013-08-29 в 18.01.34.png (21.78 KiB) Viewed 5314 times
KobeBryantLA
 
Posts: 12
Joined: Sun Aug 31, 2008 10:58 am

Re: Postgresql tuning in Mac OS

Postby kraada » Thu Aug 29, 2013 11:50 am

Purging is one of our slowest operations. How are import speeds for you? If you're purging enough data it may actually be faster to export what you want and reimport the data you want to keep into a new database.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Postgresql tuning in Mac OS

Postby KobeBryantLA » Fri Aug 30, 2013 3:47 pm

kraada wrote:Purging is one of our slowest operations. How are import speeds for you? If you're purging enough data it may actually be faster to export what you want and reimport the data you want to keep into a new database.

Thanks for advise. Speed is about 82 h/s.
KobeBryantLA
 
Posts: 12
Joined: Sun Aug 31, 2008 10:58 am

Re: Postgresql tuning in Mac OS

Postby WhiteRider » Fri Aug 30, 2013 4:19 pm

That sounds reasonable.
WhiteRider
Moderator
 
Posts: 54018
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK


Return to PT4 for macOS

Who is online

Users browsing this forum: No registered users and 25 guests

cron
highfalutin