fix #4507: add patch to automatically increase NOFILE soft limit

In many configurations, e.g. multiple vNICs with multiple queues or
with many Ceph OSDs, the default soft limit of 1024 is not enough.
QEMU is supposed to work fine with file descriptors >= 1024 and does
not use select() on POSIX. Bump the soft limit to the allowed hard
limit to avoid issues with the aforementioned configurations.

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
This commit is contained in:
Fiona Ebner
2024-02-05 14:13:17 +01:00
committed by Thomas Lamprecht
parent 676adda3c6
commit 86460aef76
6 changed files with 129 additions and 9 deletions
@@ -823,7 +823,7 @@ index 8073f5edf5..dc1ececc9c 100644
DEF("daemonize", 0, QEMU_OPTION_daemonize, \
"-daemonize daemonize QEMU after initializing\n", QEMU_ARCH_ALL)
diff --git a/softmmu/vl.c b/softmmu/vl.c
index c9e9ede237..3f2681aded 100644
index ba6ad8a8df..ddeace306e 100644
--- a/softmmu/vl.c
+++ b/softmmu/vl.c
@@ -164,6 +164,7 @@ static const char *accelerators;
@@ -847,7 +847,7 @@ index c9e9ede237..3f2681aded 100644
}
if (replay_mode != REPLAY_MODE_NONE) {
replay_vmstate_init();
@@ -3194,6 +3201,9 @@ void qemu_init(int argc, char **argv)
@@ -3196,6 +3203,9 @@ void qemu_init(int argc, char **argv)
case QEMU_OPTION_loadvm:
loadvm = optarg;
break;