cvmfs / collectd-cvmfs

Collectd Plugin to Monitor CvmFS Clients
Apache License 2.0
5 stars 3 forks source link

Use fqrn attribute to check if repo really mounted #16

Closed traylenator closed 4 years ago

traylenator commented 4 years ago

Rather than relying on scandir only to check if repository is mounted actually check an attribute.

[ "x$(attr -qg fqrn /cvmfs/cms.cern.ch)" = "xcms.cern.ch" ]

This avoids having to solve the problem in #14

traylenator commented 4 years ago

@luisfdez okay?

traylenator commented 4 years ago

This is not okay, the attr call should be done in the thread, changing.

traylenator commented 4 years ago

Although we don't use a thread for the xattr so I guess then it is okay. Does not hang.

luisfdez commented 4 years ago

Looks good to me @traylenator, it should produce more accurate mount time metrics.