From 8080ae417c1b999eb9d7e3742d62268339f96767 Mon Sep 17 00:00:00 2001 From: Simon Schampijer Date: Wed, 07 Nov 2012 17:50:54 +0000 Subject: When rebuilding the index use the index in the tmpfs Signed-off-by: Simon Schampijer Acked-by: Martin Langhoff --- diff --git a/src/carquinyol/datastore.py b/src/carquinyol/datastore.py index a859dfe..d9bd56b 100644 --- a/src/carquinyol/datastore.py +++ b/src/carquinyol/datastore.py @@ -171,8 +171,7 @@ class DataStore(dbus.service.Object): temp_index_path]) index_du = int(index_du.split('\t')[0]) # disk available, in bytes - index_path = layoutmanager.get_instance().get_index_path() - stat = os.statvfs(index_path) + stat = os.statvfs(temp_index_path) da = stat.f_bavail * stat.f_bsize if da > (index_du * 1.2) and da > MIN_INDEX_FREE_BYTES: # 20% room for growth logger.warn('Attempting to move tempfs index to disk') -- cgit v0.9.1