Search Postgresql Archives

Re: High I/O writes activity on disks causing images on browser to lag and not load

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

 



In response to Jennifer Trey <jennifer.trey@xxxxxxxxx>:
> 
> I have finally found out why I have had images that lag on the website. It
> seems to be that postgre is doing allot of I/O activity and the images is
> somehow suffering because of this.
> The strange part about this is that it seems to be allot more disk writes
> than disk reads. Even though 99.9% of my application traffic is DB read.
> Looking up in tables and presenting.
> Why is postgre doing all this writing? Should it not be I/O reads?

Possible causes:
* Table reads sometimes result in the updating of hint-bits, which equate
  to disk writes.  This should not happen often, however, and not continually.
  http://wiki.postgresql.org/wiki/Hint_Bits
* If you are doing complex queries with sorting and don't have enough RAM,
  PostgreSQL will have to create temporary files.  See the config variable
  log_temp_files:
  http://www.postgresql.org/docs/8.3/static/runtime-config-logging.html
* You have other logging settings set too high and PostgreSQL is tying
  up disk I/O writing log data.
* Your application is more write-intensive than you realize.

> I would now like to move the DB activity to another disk if possible?

That's only going to help if the machine has enough I/O capability to
process both disks.  Adding more RAM might be a better (and cheaper)
solution.

> Would
> I have to re-install PostgreSQL from scratch?

No.  You can just pick up the data directory and relocate it, then config
PostgreSQL to look for the data directory in the new location, or create
a symlink.

-- 
Bill Moran
http://www.potentialtech.com
http://people.collaborativefusion.com/~wmoran/

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[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