Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-1414

TailFile can cause Too Many Open Files if Rolling Filename Pattern used

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 0.5.0
    • Extensions
    • None

    Description

      When using the TailFile processor, if the Rolling Filename Pattern is set, the Processor does not appear to properly close the file handles that it creates for the directory. As a result, if the Processor runs long enough, we start to see "IOException: Too many open files", which causes a lot of problems and requires a restart of NiFi.

      Performing an "lsof" while running TailFile to tail the logs in my logs directory results in 10's of thousands of entries like:

      java 14549 ec2-user *703r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *704r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *705r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *706r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *707r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *708r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *709r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs
      java 14549 ec2-user *710r DIR 202,1 4096 787749 /opt/nifi/nifi-0.4.2-SNAPSHOT/logs

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            markap14 Mark Payne
            markap14 Mark Payne
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Issue deployment