]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Skip initialization for all cache_dirs except for one managed by this disker.
authorDmitry Kurochkin <dmitry.kurochkin@measurement-factory.com>
Tue, 1 Feb 2011 10:48:22 +0000 (13:48 +0300)
committerDmitry Kurochkin <dmitry.kurochkin@measurement-factory.com>
Tue, 1 Feb 2011 10:48:22 +0000 (13:48 +0300)
src/store_dir.cc

index 54f159df812505243325060553128883856c8058..6737974fac3a891699c41073eb08df3cf62afb33 100644 (file)
@@ -832,6 +832,12 @@ StoreHashIndex::init()
         *         above
         * Step 3: have the hash index walk the searches itself.
          */
+        if (IamDiskProcess() &&
+            i != KidIdentifier % Config.cacheSwap.n_configured) {
+            debugs(20, 3, HERE << " skipping init for cache_dir " <<
+                   dynamic_cast<const SwapDir &>(*store(i)).path);
+            continue;
+        }
         store(i)->init();
     }
 }