logger error before exit

Change-Id: Id4d974c3df065db235ea2d2cfbcd5891d34883c6