Re: Need to find out which process is hitting hda

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема Re: Need to find out which process is hitting hda
Дата
Msg-id b42b73150712132054k16d6a4c7pb9ddff3985728fc7@mail.gmail.com
обсуждение исходный текст
Ответ на Need to find out which process is hitting hda  (Ow Mun Heng <Ow.Mun.Heng@wdc.com>)
Ответы Re: Need to find out which process is hitting hda  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Dec 13, 2007 6:06 AM, Ow Mun Heng <Ow.Mun.Heng@wdc.com> wrote:
> I'm using centos 5 as the OS so, there's no fancy dtrace to look at
> which processes is causing my disks to thrash.
>
> I have 4 disks in the box. (all ide, 7200rpm)
>
> 1 OS disk [hda]
> 2 raided (1) disks [hdb/hdc]
> 1 pg_xlog disk (and also used as an alternate tablespace for [hdd]
> temp/in-transit files via select, insert into tmp table. delete from tmp
> table, insert into footable select * from tmp table)
>
> Problem now I see from both atop and iostat, the Device: (iostat -dx 10)
>
>                  rrqm/s   wrqm/s   r/s   w/s   rsec/s   wsec/s avgrq-sz avgqu-sz   await  svctm  %util
> hda              98.60    14.69 121.98 15.08  1775.02  2908.29    34.17    47.53  551.67   7.29  99.95
> hdb               0.70     4.20 16.48  2.30   304.50    51.95    18.98     0.21   10.94   8.45  15.86
> hdc               0.00     3.40 12.49  2.00   223.78    43.16    18.43     0.07    5.04   4.42   6.40
> hdd               0.00    56.94  0.50  3.70    53.55   485.91   128.57     0.02    5.48   3.95   1.66
> md0               0.00     0.00 29.57 11.89   526.67    95.10    15.00     0.00    0.00   0.00   0.00
>
> the number of writes and reads on hda is much greater than expected and I'm not sure who/what is causing it.

there are a few things that I can think of that can can cause postgres
to cause i/o on a drive other than the data drive:
* logging (eliminate this by moving logs temporarily)
* swapping (swap is high and changing, other ways)
* dumps, copy statement (check cron)
* procedures, especially the external ones (perl, etc) that write to disk

my seat-of-the-pants guess is that you are looking at swap.

of course, a runaway program other than postgres can be the cause

merlin

В списке pgsql-general по дате отправления:

Предыдущее
От: Ken Johanson
Дата:
Сообщение: Re: RETURNING clause: how to specifiy column indexes?
Следующее
От: Stefan Schwarzer
Дата:
Сообщение: Re: UNION not working... why?