add log to trace the bug of doesn't send mail sometime.