Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

I need to ingest logs from Windows Servers using MiNiFi - tailfile processor error unable to open file

Highlighted

I need to ingest logs from Windows Servers using MiNiFi - tailfile processor error unable to open file

New Contributor

Hi All, I am trying to collect logs from a windows server using MiNiFi Agent method - I have minifi running, template created and transformed to config.yml on the windows server. Tailfile processor has started in NiFi but shows an error "Unable to open file: will attempt to access the file again after the yield duration has elapsed. I have recreated this scenario on multiple different windows servers so clearly I am missing something in the process. Can someone provide me the missing step - I feel it is permissions of the Minifi process on the windows server as far as being able to access the desired log file(s) but nothing in the setup documentation for Minifi speaks to the topic of permissions on a windows server target.. Thanks in advance for your help.

3 REPLIES 3
Highlighted

Re: I need to ingest logs from Windows Servers using MiNiFi - tailfile processor error unable to open file

Hello @John King!
Not sure if the issue persists, but I have a few questions related to your issue:

- Are you running MiNifi as a service or agent (through bat)
- If you're running through bat, are you running the cmd/PowerShell as administrator?

Btw, could you enable the DEBUG mode for the TailFile? And share with us the logs?
E.g.

<logger name="org.apache.nifi.processors.standard.TailFile" level="DEBUG"/>

Lastly, If you're able to make a quick test and install cygwin in the windows server, are you able to tail the file with the same user that's running minifi?

Hope this helps

Re: I need to ingest logs from Windows Servers using MiNiFi - tailfile processor error unable to open file

New Contributor

Hi Vinicius, so I can try adding the debugger but I am also experiencing strange things with respect to defining the log file name and the base directory name. I have no issues with Minifi on Linux servers but on the windows server I am experiencing challenges.

In the tail file processor what is the standard for defining the log file name and the base directory name - I cannot find that anywhere in minifi documentation. If I wrap the log file name with ${logfile.log} and also wrap the base directory with the ${basedir} I get the unable to open log file error, If I take the ${...} away I get error about Java attributes.

I really just would like to get what the standard needs to be for defining the log file and base dir. That would help to eliminate the syntax as the cause...

Thanks

Highlighted

Re: I need to ingest logs from Windows Servers using MiNiFi - tailfile processor error unable to open file

@john_e_king 

Are you still facing this issue?

Don't have an account?
Coming from Hortonworks? Activate your account here