3 Replies Latest reply on Nov 30, 2015 7:47 AM by Vijay Raje

    Disk Space Alert for Linux Box

      Hello Fellow Community members....

      I need your help..  I am running Soalrwinds IP Monitor 9 and need to set up a disk space alert for a Linux box.

      Basically the apache logs are filling up the /var partition and I would like a monitor to email me when it gets above 80%.

      However I can only see support for a disk space monitor on a windows based machine.

      Is there anyway to monitor disk space on a box running linux?

      Many thanks for your time


        • Re: Disk Space Alert for Linux Box

          Hi Tribeca--

          I'm going to let the product manager know about this one in case it needs to be a feature request.

          Also, have you tried searching the IPmonitor forum? When I did, it brought up many posts that you might find useful.


          • Re: Disk Space Alert for Linux Box


            ipMonitor can be used to monitor all sorts of Linux properties via the SNMP calls.  On the Linux system you need to have the net-snmp packages installed and configured to allow SNMP access from your monitoring system's subnet or specific IP (also want to make sure you set the snmpd to autostart on reboot).

            Not sure which version of Linux you are running, but here are the commands run and changes I made on our CentOS (5.x) systems to monitor this (we are running ipMonitor 10, but the snmp works on 9 also).

            (install net-snmp-utils which will also install net-snmp & net-snmp-libs) 
            yum install net-snmp-utils

            (always back up the original conf file just in case)
            cp /etc/snmp/snmpd.conf /etc/snmp/snmpd.conf.orig

            (edit the snmp.conf file to allow access from your ipMonitor system (sorry about formatting, this is cut/paste from conf file))
            vi /etc/snmp/snmpd.conf

            [Note: Modify subnet and community here]
            # First, map the community name "public" into a "security name"
            #  sec.name                    source                                   community
            com2sec notConfigUser  ***subnet or host here***   ***community here***

            [Note: This already existed in my config based on above security name]
            # Second, map the security name into a group name:
            #       groupName      securityModel securityName
            group   notConfigGroup v1           notConfigUser
            group   notConfigGroup v2c           notConfigUser

            [Note: Define the allowed SNMP OID levels. I add the last entry ".1" since want to see all]
            # Third, create a view for us to let the group have rights to:
            # Make at least  snmpwalk -v 1 localhost -c public system fast again.
            #       name           incl/excl     subtree         mask(optional)
            view    systemview    included   .
            view    systemview    included   .
            view    systemview    included   .1

            [Note: This already existed in my config]
            # Finally, grant the group read-only access to the systemview view.
            # group   context  sec.model  sec.level               prefix   read            write   notif
            access  notConfigGroup  ""      any       noauth    exact  systemview  none  none

            These lines above will allow you to define the read only access for the SNMP and restrict access to your ipMonitor system or subnet depending on how you do this (check the man pages for snmpd for more specifics).

            Once that is done, if you are running a local software firewall on the Linux system, you will need to open it to allow UDP port 161 from the ipMontor host or subnet as desired.

            Then start up the snmpd process and set it to autostart on reboot:

            /etc/init.d/snmpd start

            /sbin/chkconfig snmpd on

            There are other ways to do this, this is just what I have done that works for our Linux systems.

            Once you have the SNMP working on the linux system, you can add monitors for specifics that are already provided (check under the SNMP monitor sets in "Add Monitor")  like disk space, bandwidth, etc, or use the custom snmp wizard to monitor anything exposed via SNMP OID.  You can start from the OID that it gives you automatically in the wizard, or reduce the OID string by one or a few fields and see all sorts of details (the shorter the OID, the more you see, the longer it takes to view and find what you want).

            Hope that helps.