Fix 2938 (cache invalidation on restart)

fixes #2938