[linux-lvm] Discussion: performance issue on event activation mode

David Teigland teigland at redhat.com
Mon Jun 7 21:30:03 UTC 2021


On Mon, Jun 07, 2021 at 10:27:20AM +0000, Martin Wilck wrote:
> Most importantly, this was about LVM2 scanning of physical volumes. The
> number of udev workers has very little influence on PV scanning,
> because the udev rules only activate systemd service. The actual
> scanning takes place in lvm2-pvscan at .service. And unlike udev, there's
> no limit for the number of instances of a given systemd service
> template that can run at any given time.

Excessive device scanning has been the historical problem in this area,
but Heming mentioned dev_cache_scan() specifically as a problem.  That was
surprising to me since it doesn't scan/read devices, it just creates a
list of device names on the system (either readdir in /dev or udev
listing.)  If there are still problems with excessive scannning/reading,
we'll need some more diagnosis of what's happening, there could be some
cases we've missed.

Dave




More information about the linux-lvm mailing list