more fixes and log cleanup