add logs on rebuild database