sk181317 - "unable to watch directory /etc/routed-mc-enable: init: Too many open files" error in clish when configuring dynamic routing

"unable to watch directory /etc/routed-mc-enable: init: Too many open files" error in clish when configuring dynamic routing

Product

Maestro HyperScale Firewall, Security Gateways, VSX (Traditional)

Version

R80.40 (EOS), R81 (EOS), R81.10 (EOS), R81.20, R82, R82.10

OS

Gaia

Last Modified

2026-07-23

Symptoms

Cause

When the Gaia OS saves the configuration, the OS checks for the file named /etc/routed-mc-enable/instance- to determine whether multicast routing is enabled or not.

The error " Too many open files" in this case means that the routed process has exceeded the process' limit of open file descriptors.

Solution

This problem was fixed. The fix is included in:

If you choose not to upgrade, follow these instructions:

  1. Connect to the command line of the Security Gateway.

    • In a clustered environment, connect to each cluster member.
  2. Log in to Expert mode.

  3. Double the current value of the " optmem_max" parameter:

    [Expert@GwHostname:0]# echo -ne Old optmem_max value: "$(cat /proc/sys/net/core/optmem_max)\n""New optmem_max value: " $(bc -l <<< $(cat /proc/sys/net/core/optmem_max)*2)"\n" ; echo $(bc -l <<< $(cat /proc/sys/net/core/optmem_max)*2) > /proc/sys/net/core/optmem_max
    
  4. Double the current value of the " igmp_max_memberships" parameter:

    [Expert@GwHostname:0]# echo -ne Old igmp_max_memberships value: "$(cat /proc/sys/net/ipv4/igmp_max_memberships)\n""New igmp_max_memberships value: " $(bc -l <<< $(cat /proc/sys/net/ipv4/igmp_max_memberships)*2)"\n" ; echo $(bc -l <<< $(cat /proc/sys/net/ipv4/igmp_max_memberships)*2) > /proc/sys/net/ipv4/igmp_max_memberships
    
  5. If the new values did not resolve the issue, double them one more time.

    • Do not increase these values more than two times.

If increasing the values for "igmp_max_memberships" and "optmem_max" resolved the issue continue to step 7. 6. Contact Check Point Support to investigate this issue if increasing the value twice did not help. 7. If the new values resolved the issue, add the applicable commands to the " /etc/rc.d/rc.local" start-up shell script (Gaia OS overrides the user-defined settings in the /etc/sysctl.conf file):

  1. Back up the current script:
[Expert@GwHostname:0]# cp -v /etc/rc.d/rc.local{,_BKP}
  1. Update the script:
    1. [Expert@GwHostname:0]# echo "#Manual configuration based on sk181317" >> /etc/rc.d/rc.local
      
    2. [Expert@GwHostname:0]# echo "echo $(cat /proc/sys/net/core/optmem_max) > /proc/sys/net/core/optmem_max" >> /etc/rc.d/rc.local
      
    3. [Expert@GwHostname:0]# echo "echo $(cat /proc/sys/net/ipv4/igmp_max_memberships) > /proc/sys/net/ipv4/igmp_max_memberships" >> /etc/rc.d/rc.local
      
  2. To fix the Routed issue during the "VSX Push configuration" operation:
    1. Make the change only in the current session (does not survive reboot). Run in the context of VS0:

      [Expert@GwHostname:0]# echo -ne Old max_user_instances value: "$(cat /proc/sys/fs/inotify/max_user_instances)\n""New max_user_instances value: " $(bc -l <<< $(cat /proc/sys/fs/inotify/max_user_instances)*4)"\n" ; echo $(bc -l <<< $(cat /proc/sys/fs/inotify/max_user_instances)*4) > /proc/sys/fs/inotify/max_user_instances
      

      Example output:

      Old max_user_instances value: 128
      New max_user_instances value: 512
      

      To verify, run:

      [Expert@GwHostname:0]# cat /proc/sys/fs/inotify/max_user_instances
      
    2. Make the change permanent (to survive reboot): Add the applicable commands to the " /etc/rc.d/rc.local" start-up shell script (Gaia OS overrides the user-defined settings in the /etc/sysctl.conf file):

      1. [Expert@GwHostname:0]# echo "#Manual configuration based on sk181317" >> /etc/rc.d/rc.local
        
      2. [Expert@GwHostname:0]# echo "echo $(cat /proc/sys/fs/inotify/max_user_instances) > /proc/sys/fs/inotify/max_user_instances" >> /etc/rc.d/rc.local
        

NOTE

This solution has been verified for the specific scenario, described by the combination of Product, Version and Symptoms. It may not work in other scenarios.

Article Properties