removed user agent, removed cookie dump and exit, moved log initialization up