Getting too many open files when using stream targets to Wowza CDN

We have been using WSE 4.8.x and have not see the following issue before.

We started using WSE 4.9.3 and have the following issue:
I have 12 RTSP streams connected to WSE. When I enable stream targets on all 12 streams I notice, using lsof -p that the number of file descriptors of type a_inode such as:

java 3137865 root 225u a_inode 0,16 0 2086 [eventpoll:226]
java 3137865 root 226u a_inode 0,16 0 2086 [eventfd:231]

increases as high as 36000 before gradually reducing to around 5000 and then goes up and down over time but never seems to go as high as the initial maximum.

When we added more streams we eventually started getting Too many open files errors in the WSE logs.

Now, the WSE startup scripts do ulimit -n 64000 and Ubuntu apparently has a hard limit of 1048576.

We want to have many more incoming RTSP streams that go to stream targets, probably as many as 50+

Can anyone explain what is happening?
Is the answer to modify the startup scripts to set the ulimit -n to a much higher values?

Thanks,
Jo

Hey Jonathan, Thanks for bringing this to the Wowza Community!

To thoroughly investigate the high file descriptor usage you’re seeing with stream targets in WSE 4.9.3, it would be best to open a support ticket. Our engineers can then take a closer look at your specific setup.

When you do, could you attach a ZIP file containing your conf/, logs/, transcoder/, and manager/logs folders? For future reference on preparing these files, please refer to the article: Prepare Wowza Streaming Engine config and log files for Support tickets. Please ensure the ZIP includes an access log with the Wowza server startup sequence.

Regards,
Vihari