Re: [INFO] - vm.dirty_ratio/background_ratio
От | Victor Yegorov |
---|---|
Тема | Re: [INFO] - vm.dirty_ratio/background_ratio |
Дата | |
Msg-id | CAGnEboi83_TcZqJzuGcs6vFASSZ1EoN8m2Q8yXWWj466nOOEiA@mail.gmail.com обсуждение исходный текст |
Ответ на | [INFO] - vm.dirty_ratio/background_ratio ("drum.lucas@gmail.com" <drum.lucas@gmail.com>) |
Ответы |
Re: upsert example about postgres9.5
|
Список | pgsql-admin |
2016-04-05 2:27 GMT+03:00 drum.lucas@gmail.com <drum.lucas@gmail.com>:
I've got a 128GB server with SATA disks.. and I'm having I/O issue.......[root@741293-03 ~]$ sysctl -a | grep dirty
vm.dirty_background_ratio = 20
vm.dirty_background_bytes = 0
vm.dirty_ratio = 25
vm.dirty_bytes = 0
vm.dirty_writeback_centisecs = 500
vm.dirty_expire_centisecs = 3000
I think you should lower your `dirty_background_ratio`, 'cos currently kernel will start writing down dirty data from the cache when 20% of `Active` (as reported by /proc/vmstat) is filled,
on 128GB server this can be a lot. You should base your settings on your IO subsystem capabilities — somewhere around the size of the cache of your RAID array.
If you really have IO issues, consider checking more kernel parameters:
sysctl -a|egrep '^vm.(dirty|swap|over)'
and also check `pg_stat_bgwriter` data, it shows accumulated data about IO performed by checkpoints, bgwriter and individual backends.
For reference, I really like the following pages:
Victor Y. Yegorov
В списке pgsql-admin по дате отправления: