updated log generation and vars