Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    xinetd doesn't read "included directory"

    Scheduled Pinned Locked Moved pfSense Packages
    4 Posts 1 Posters 876 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      karls0
      last edited by

      Re: Check_MK on pfSense 2.4 w/ Update-persistence

      After reloading filters, I get following in Status | System logs | General:
      Unable to read included directory: /opt/etc/xinetd.d [file=/var/etc/xinetd.conf] [line=1]
      /var/etc/xinetd.conf contains:

      includedir /opt/etc/xinetd.d
      

      /opt/etc/xinet.d has rights set to 775:

      drwxrwxr-x  2 root  wheel  512 Dec  6 15:36 xinet.d
      

      The file /opt/etc/xinetd/check_mk is from above post. The important part is:

      service check_mk
      {
          type           = UNLISTED
          port           = 6556
          socket_type    = stream
          protocol       = tcp
          wait           = no
          user           = root
          server         = /opt/bin/check_mk_agent
      
          # If you use fully redundant monitoring and poll the client
          # from more then one monitoring servers in parallel you might
          # want to use the agent cache wrapper:<br />
      
          #server         = /usr/bin/check_mk_caching_agent
      
          # configure the IP address(es) of your Nagios server here:
          only_from      = 127.0.0.1 192.168.129.12 192.168.129.33
      
          # Don't be too verbose. Don't log every check. This might be
          # commented out for debugging. If this option is commented out
          # the default options will be used for this service.
          log_on_success =
      
          disable        = no
      }
      

      So to me everything looks fine, but since the xinetd-rule is not beeing loaded, I can't connect to the check_mk_agent from my monitoring-server.
      Any help appreciated,
      Karl

      K 1 Reply Last reply Reply Quote 0
      • K
        karls0 @karls0
        last edited by

        @karls0
        Hi, today I tried again.
        First I found, that the line

        fclose($xinted_fd);
        

        is twice in the file '/etc/inc/filter.inc' - in line 2256 and in 2479. I added the line to include '/opt/etc/xinetd.d' before both of them. Nothing changed after reloading the filter. There are the same error-messages in the log.

        When I start xinetd by hand

        xinetd -f /var/etc/xinetd.conf
        

        it starts and I can get my checks from the monitor-host. After rebooting, xinetd is not running any more :-((
        Any ideas?
        Thanks in advance, Karl

        K 1 Reply Last reply Reply Quote 0
        • K
          karls0 @karls0
          last edited by

          @karls0 Sorry, I forgot to mention, that I worked according to
          https://forum.netgate.com/topic/99612/pfsense-2-3-check_mk-working-with-xinetd/2

          K 1 Reply Last reply Reply Quote 0
          • K
            karls0 @karls0
            last edited by karls0

            @karls0 Just to remember it:
            After reloading filters, I get following in Status | System logs | General:
            Unable to read included directory: /opt/etc/xinetd.d [file=/var/etc/xinetd.conf] [line=1]

            When I tried "less" and typed in the whole path (without the Tab-key) I got the message "/opt/etc/xinetd.d/check_mk: No such file or directory" So there must be an invisible character in the path. Therefore I deleted the directory /opt/etc/xinetd.d and created it new. I copied the file "check_mk" back into it and now xinetd runs :-))

            Sorry, I cannot mark my post as resolved - if anyone can, please do it.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.