cleanup cachefile handling