Re: Multi-processors

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

 



On Fri, Sep 19, 2008 at 5:55 AM, c k <shreeseva.learning@xxxxxxxxx> wrote:
> Hello PG Community,
> Does PG uses multiple processors/cores if available by default on various
> OSes?

Yes, see attached top extract from my primary db server at work

> What are the limitations on using multiple processors/cores and main
> memory?

Do you mean how many CPUs and how much memory?  no real limits on a 64
bit machine. Note that it's often better to let the os do the majority
of caching, depending on your work load.  This is especially true in
OLTP where the cost of pgsql maintaining a large buffer is higher than
the benefit it provides, but the kernel can cache much larger datasets
faster, in my experience.
top - 08:27:03 up 38 days, 19:10,  1 user,  load average: 3.67, 4.26, 4.39
Tasks: 316 total,   8 running, 308 sleeping,   0 stopped,   0 zombie
Cpu0  : 10.4%us,  0.9%sy,  0.0%ni, 88.7%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Cpu1  : 21.6%us,  5.2%sy,  0.0%ni, 73.3%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Cpu2  :  4.3%us,  1.7%sy,  0.0%ni, 93.1%id,  0.0%wa,  0.0%hi,  0.9%si,  0.0%st
Cpu3  : 14.8%us,  0.9%sy,  0.0%ni, 83.5%id,  0.0%wa,  0.0%hi,  0.9%si,  0.0%st
Cpu4  : 51.3%us,  2.6%sy,  0.0%ni, 46.1%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Cpu5  : 47.8%us,  2.6%sy,  0.0%ni, 48.7%id,  0.0%wa,  0.0%hi,  0.9%si,  0.0%st
Cpu6  : 57.4%us,  2.6%sy,  0.0%ni, 40.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Cpu7  : 62.6%us,  4.3%sy,  0.0%ni, 26.1%id,  0.0%wa,  0.9%hi,  6.1%si,  0.0%st
Mem:  33031252k total, 30858572k used,  2172680k free,   521644k buffers
Swap:  9767480k total,     8032k used,  9759448k free, 27457352k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND                                                         
13827 postgres  16   0 8353m 112m 103m R   37  0.3   0:01.37 postgres: webguy www 10.0.0.59(43081) SELECT                    
11115 postgres  15   0 8363m 2.0g 2.0g R   32  6.3   7:44.41 postgres: webguy www 10.0.0.58(42066) SELECT                    
13651 postgres  15   0 8358m 426m 416m S   25  1.3   0:04.70 postgres: webguy www 10.0.0.52(59220) idle                      
13746 postgres  15   0 8360m 396m 384m S   20  1.2   0:03.44 postgres: webguy www 10.0.0.58(53244) idle                      
13775 postgres  15   0 8357m 403m 394m S   20  1.3   0:03.25 postgres: webguy www 10.0.0.59(38550) idle                      
13840 postgres  15   0 8355m 138m 130m S   16  0.4   0:01.81 postgres: webguy www 10.0.0.58(60554) idle                      
13813 postgres  16   0 8357m 372m 362m R   13  1.2   0:02.44 postgres: webguy www 10.0.0.59(41723) SELECT                    
13893 postgres  15   0 8349m  28m  25m S   10  0.1   0:00.14 postgres: webguy www 10.0.0.52(47776) idle                      
13598 postgres  15   0 8360m 566m 553m S    9  1.8   0:12.42 postgres: webguy www 10.0.0.59(55696) idle                      
13854 postgres  15   0 8355m  92m  84m S    9  0.3   0:00.90 postgres: webguy www 10.0.0.59(44909) idle                      
13718 postgres  15   0 8358m 437m 426m S    8  1.4   0:08.55 postgres: webguy www 10.0.0.59(34177) idle                      
13794 postgres  15   0 8354m  32m  27m S    8  0.1   0:00.26 postgres: webguy www 10.0.0.153(36273) idle                     
13820 postgres  15   0 8358m 194m 184m S    8  0.6   0:02.03 postgres: webguy www 10.0.0.58(58962) idle                      
13791 postgres  15   0 8359m 258m 246m S    7  0.8   0:04.30 postgres: webguy www 10.0.0.59(40007) idle                      
13439 postgres  15   0 8358m 604m 594m S    6  1.9   0:10.06 postgres: webguy www 10.0.0.58(33212) idle                      
13570 postgres  16   0 8359m 322m 311m S    6  1.0   0:09.51 postgres: webguy www 10.0.0.58(41747) idle                      
13736 postgres  15   0 8359m 300m 289m S    6  0.9   0:04.50 postgres: webguy www 10.0.0.59(36212) idle                      
13809 postgres  15   0 8351m 229m 219m R    5  0.7   0:02.05 postgres: webguy www 10.0.0.58(57974) SELECT          

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux