diff --git a/src/node_device/node_device_udev.c b/src/node_device/node_device_udev.c index f100fd2e54..a69dc11753 100644 --- a/src/node_device/node_device_udev.c +++ b/src/node_device/node_device_udev.c @@ -1764,6 +1764,13 @@ static int nodeStateInitialize(bool privileged, udev_monitor_enable_receiving(priv->udev_monitor); + /* mimic udevd's behaviour and override the systems rmem_max limit in case + * there's a significant number of device 'add' events + */ + if (geteuid() == 0) + udev_monitor_set_receive_buffer_size(priv->udev_monitor, + 128 * 1024 * 1024); + /* We register the monitor with the event callback so we are * notified by udev of device changes before we enumerate existing * devices because libvirt will simply recreate the device if we