Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File owner information #22

Open
ravi-visionet opened this issue Nov 2, 2021 · 3 comments
Open

File owner information #22

ravi-visionet opened this issue Nov 2, 2021 · 3 comments
Assignees
Labels
enhancement New feature or request wontfix This will not be worked on

Comments

@ravi-visionet
Copy link

Hi,

Appreciate the filestat exporter.

Would it be possible to get owner of the file?

Thanks
Ravi

@michael-doubez michael-doubez added the enhancement New feature or request label Nov 2, 2021
@michael-doubez
Copy link
Owner

Hello,

What are you trying to monitor ?

This would be tricky to make work on non-posix system (windows).

Let say we restrict it to POSIX systems, there are two options:

  1. Display system info (user, group ...) as an info metric: info would be in the label.
    Note: the value would be the timestamp of the file because any chmod on the file would duplicate the metric during the staleness time (~5min)
    filestat_file_info{file="a_file.txt",user="me",group="friends"} <timestamp of file>
    
  2. Expose system info as a gauge metric: uid if the value of the metric (effective name of the user could be exposed in another metrics)
     filestat_file_uid{file="a_file.txt"}  42
     filestat_user_uid{name="me"} 42
    

I'd rather choose the option 2 since I could always use uid as an index on windows.

@michael-doubez michael-doubez self-assigned this Nov 2, 2021
@ravi-visionet
Copy link
Author

Hello,

What are you trying to monitor ?

This would be tricky to make work on non-posix system (windows).

Let say we restrict it to POSIX systems, there are two options:

  1. Display system info (user, group ...) as an info metric: info would be in the label.
    Note: the value would be the timestamp of the file because any chmod on the file would duplicate the metric during the staleness time (~5min)
    filestat_file_info{file="a_file.txt",user="me",group="friends"} <timestamp of file>
    
  2. Expose system info as a gauge metric: uid if the value of the metric (effective name of the user could be exposed in another metrics)
     filestat_file_uid{file="a_file.txt"}  42
     filestat_user_uid{name="me"} 42
    

I'd rather choose the option 2 since I could always use uid as an index on windows.

Hi Michael,

Thanks for the details.

The goal is to monitor Linux & windows files ( size, last modified/accessed, owner of the file)

I am trying to monitor the Owner and Group of the specific file/folder. Currently I am able to monitor only file size and last modified info.

Please refer the below Grafana widget, is there any way that we can get the owner and group details as well.

file

@michael-doubez michael-doubez added the wontfix This will not be worked on label Feb 28, 2023
@kverma95
Copy link

@ravi-visionet , Can you share the json file ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants