def doRollover(self): # pylint: disable=C0103
    if self.stream:
      self.stream.flush()
      self.stream.close()
      self.stream = None

    # Reopen file
    # TODO: Handle errors?
    self.stream = open(self.baseFilename, "a")

    # Don't reopen on the next message
    self._reopen = False
Reopens the log file.
dataset/ETHPy150Open ganeti/ganeti/lib/utils/log.py/_ReopenableLogHandler.doRollover