Search Postgresql Archives

Vacuum problem

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

 



Hello!

Our 300GB database requires vacuum about once a week to prevent transaction id wrap around. Database is heavily updated and sometimes vacuuming takes over 12 hours.

We have a major problem with a table that tracks online users (user_online). A row is inserted when a user logs in and a "seen" stamp is updated every five minutes if he/she loads any pages. Periodical cron job deletes all idle users - rows that have "seen" older than 20 minutes. Frequent vacuuming is required to delete old row versions. We have usually about 20k users online.

However, database wide vacuum prevents user_online vacuum from deleting old row versions and the table gets incredibly bloated. Queries involving the user_online practically cease to work.

Any suggestions for this problem?

Btw, we have PostgreSQL 8.1.


    |\__/|
    ( oo )    Kari Lavikka - tuner@xxxxxx - (050) 380 3808
__ooO(  )Ooo_______ _____ ___ _ _  _   _    _      _                  _
      ""

---------------------------(end of broadcast)---------------------------
TIP 5: don't forget to increase your free space map settings

[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