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

Do not ignore mountpoints that have the same mount path #6871

Merged

Conversation

Smjert
Copy link
Member

@Smjert Smjert commented Dec 30, 2020

Use a vector instead of an unordered_map keyed on the mount path,
since we can have multiple mount points on the same mount path
and since all the other use cases do not need such data layout.
Although multiple mount points on the same mount path will override
each other, we still want to be faithful to the information
that /proc/mounts gives us.

Moreover with autofs mounted filesystems, we will always have two
mount lines when the target filesystem is mounted, one for autofs
and one for the target filesytem.

Fixes #6865

Use a vector instead of an unordered_map keyed on the mount path,
since we can have multiple mount points on the same mount path
and since all the other use cases do not need such data layout.
Although multiple mount points on the same mount path will override
each other, we still want to be faithful to the information
that /proc/mounts gives us.

Moreover with autofs mounted filesystems, we will always have two
mount lines when the target filesystem is mounted, one for autofs
and one for the target filesytem.
@Smjert Smjert force-pushed the stefano/fix/missing-mountpoints-autofs branch from fb64557 to 2790d8b Compare December 30, 2020 15:55
@theopolis theopolis merged commit 4e20495 into osquery:master Dec 31, 2020
@mike-myers-tob mike-myers-tob deleted the stefano/fix/missing-mountpoints-autofs branch January 5, 2021 00:54
@thomas-merz
Copy link

Thank you all! 👏

@thomas-merz
Copy link

thomas-merz commented Jan 11, 2021

@Smjert When do we get this packaged as RPM and when will it be released on https://s3.amazonaws.com/osquery-packages/rpm/x86_64/ or https://osquery.io/downloads/official/ ?
I can't even find a 4.6.0 on s3.amazonaws.com but only on osquery.io 🤔

@thomas-merz
Copy link

Ping… I really would appreciate this fix as a new RPM release in the official repos being available for my 1000+ Linux Hosts (even if not all hosts use autofs on nfs) 🤔 Can you please give me an estimation when this fix will be made available as a new release?

@theopolis
Copy link
Member

Sorry for the delay, heads up that packages are available for download shortly after tags are published: https://osquery.io/downloads/official/4.6.0

@thomas-merz
Copy link

But how does it come, that no 4.6.0 is available on https://s3.amazonaws.com/osquery-packages/rpm/x86_64/ but 4.6.0 has been available since January 11th on osquery.io? That's not "shortly" for me… 🤔

@directionless
Copy link
Member

Hi. First, as an aside, this PR did not merge in 4.6.0, it should be in the next release.

Second, the package repositories we host tend to lag a bit. This lag is partly to give people a chance to test the new releases, and partly because we're humans. Generally if you're managing a large number of linux machines, I'd recommend hosting your own repos.

@thomas-merz
Copy link

We are already mirroring https://s3.amazonaws.com/osquery-packages but there's no 4.6.0 since Jan, 11th available. I thought this might be a bit too "laggy" or am I too impatient? 🤔
Latest version we are getting from this repo is osquery-4.5.1-1.linux.x86_64.rpm from 2020-10-09 23:00. Our last sync is from 2021-02-02T21:01:27Z.

@directionless
Copy link
Member

"too impatient" carries a lot of value. We haven't pushed it to the stable repos because earlier this week we had a report of a potential crash. Though having been unable to reproduce, it will probably go out this week.

@thomas-merz
Copy link

Got 4.6.0-1 automatically in Feb 5th 👍🏻
Feb 05 03:39:50 Updated: osquery-4.6.0-1.linux.x86_64

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing NFS in output of osqueryi if mounted via AUTOFS
4 participants