Title: Log limit question
Last modified: March 25, 2018

---

# Log limit question

 *  Resolved [eginventors](https://wordpress.org/support/users/eginventors/)
 * (@eginventors)
 * [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/)
 * I have a high-traffic site, and the table wp_popularpostssummary is getting huge,
   
   now my question is if I enable Log limit for example 30 days, is that mean that
   post views for more than 30 days will LOST and will be zero?
 * and if yes, what is the suggestion from your side to prevent or just not to increase
   the table size dramatically?
 * Thank you
    -  This topic was modified 8 years, 2 months ago by [eginventors](https://wordpress.org/support/users/eginventors/).

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * (@hcabrera)
 * [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/#post-10112861)
 * Hi [@eginventors](https://wordpress.org/support/users/eginventors/),
 * The size of the table -according to people who know more than me in this area-
   [isn’t really important](https://stackoverflow.com/questions/1276/how-big-can-a-mysql-database-get-before-performance-starts-to-degrade):
 * > The most important scalability factor is RAM. If the indexes of your tables
   > fit into memory and your queries are highly optimized, you can serve a reasonable
   > amount of requests with a average machine.
 * I believe WPP’s database tables are properly indexed and I’m pretty sure WPP’s
   database queries have been optimized as much as possible as well.
 * If you’re noticing performance issues then chances are your server’s RAM isn’t
   enough to handle the amount of requests it currently gets. In that case, enabling
   the [Log Limit](https://github.com/cabrerahector/wordpress-popular-posts/wiki/7.-Performance#data-logging)
   feature can help since it’ll reduce the size of the database table by automatically
   deleting rows older than _N_ days (so yes, this data will be lost and “will be
   zero”).
 * Alternatively, you could also try enabling the [Data Sampling](https://github.com/cabrerahector/wordpress-popular-posts/wiki/7.-Performance#data-sampling)
   feature. It’ll write a lot less to the database and the table should be more 
   compact as well.
 * Hope that helps!
 *  Thread Starter [eginventors](https://wordpress.org/support/users/eginventors/)
 * (@eginventors)
 * [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/#post-10112882)
 * Many Thanks
    -  This reply was modified 8 years, 2 months ago by [eginventors](https://wordpress.org/support/users/eginventors/).
 *  Thread Starter [eginventors](https://wordpress.org/support/users/eginventors/)
 * (@eginventors)
 * [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/#post-10113311)
 * Hello, just want to be sure, and sorry if it seems a stupid question,
 * My website has posts with high rate reading and also posts with a low rate reading,
 * so I set Data Sampling to 50 ,
 * now the question
 * if the post with low rate reading, let’s say it will continue count 50 view after
   a month due to its low rate reading,
 * does the plugin will really count the reading 50 view over a month period OR 
   it will maybe lose counting and begin from 0 due to the long period ( month )
   and low rate reading?
 *  Plugin Author [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * (@hcabrera)
 * [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/#post-10117008)
 * Somehow I missed your new comments!
 * Everytime someone visits any of your posts, it’ll increase its views count by
   50 regardless of time:
 * > **How does Data Sampling work?**
   > Every time someone visits one of your posts / pages, WPP will generate random
   > number between 1 and _N_, being _N_ the sample rate. If the random number turns
   > out to be 1, then the views count of that post / page will be incremented by
   > _N_.
   > The general idea is that in theory it should take _N_ tries to hit number 1(
   > the probability of that is 1/N). In the long run, it’ll increase the views 
   > count value by 1 for each visit without constantly querying the database.
 * Do make sure to use the right sampling rate for your site:
 * > The default value is 100, recommended for sites with 125k / 250k visits per
   > day.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Log limit question’ is closed to new replies.

 * ![](https://ps.w.org/wordpress-popular-posts/assets/icon-256x256.png?rev=1232659)
 * [WP Popular Posts](https://wordpress.org/plugins/wordpress-popular-posts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-popular-posts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-popular-posts/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-popular-posts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-popular-posts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-popular-posts/reviews/)

## Tags

 * [database](https://wordpress.org/support/topic-tag/database/)
 * [performance](https://wordpress.org/support/topic-tag/performance/)
 * [size](https://wordpress.org/support/topic-tag/size/)
 * [table](https://wordpress.org/support/topic-tag/table/)

 * 4 replies
 * 2 participants
 * Last reply from: [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * Last activity: [8 years, 2 months ago](https://wordpress.org/support/topic/log-limit-explain/#post-10117008)
 * Status: resolved