fix errors issues with unchanged logging and log file growing too fast