Move a pool to POOL_REJECTING to be disabled only after 3 minutes of continuous rejec...
authorCon Kolivas <kernel@kolivas.org>
Fri, 4 May 2012 23:31:48 +0000 (09:31 +1000)
committerCon Kolivas <kernel@kolivas.org>
Fri, 4 May 2012 23:31:48 +0000 (09:31 +1000)
cgminer.c

index 21d90d1..cf42784 100644 (file)
--- a/cgminer.c
+++ b/cgminer.c
@@ -1723,13 +1723,13 @@ static bool submit_upstream_work(const struct work *work, CURL *curl)
                }
 
                /* Once we have more than a nominal amount of sequential rejects,
-                * at least 10 and more than the current utility rate per minute,
+                * at least 10 and more than 3 mins at the current utility,
                 * disable the pool because some pool error is likely to have
                 * ensued. */
                if (pool->seq_rejects > 10 && opt_disable_pool && total_pools > 1) {
                        double utility = total_accepted / ( total_secs ? total_secs : 1 ) * 60;
 
-                       if (pool->seq_rejects > utility) {
+                       if (pool->seq_rejects > utility * 3) {
                                applog(LOG_WARNING, "Pool %d rejected %d sequential shares, disabling!",
                                       pool->pool_no, pool->seq_rejects);
                                pool->enabled = POOL_REJECTING;