logging works with remveing old data