/build/static/layout/Breadcrumb_cap_w.png

Email Notification for Low Disk Space (server)

I created a notification in SMA to email the IT team whenever servers reach 90%+ used space. But the email that is sent from Reporting > Notifications isn't the most useful. All it includes is System Description, MAC Address and IP Address.

I don't know SQL, although I can usually fiddle my way to getting some things I want, but this one is outside my wheelhouse. Any help would be appreciated.

I'd like to include the drives in the system that has low disk space, not just the C: drive.

SELECT MACHINE.NAME AS SYSTEM_NAME, SYSTEM_DESCRIPTION, MACHINE.IP, MACHINE.MAC, MACHINE.ID as TOPIC_ID FROM MACHINE  LEFT JOIN MACHINE_DISKS ON (MACHINE_DISKS.ID = MACHINE.ID) WHERE ((MACHINE_DISKS.PERCENT_USED > '90') AND (OS_NAME like '%Server%'))  GROUP BY MACHINE.ID 

When the email comes in, it gives a table Computer Name, System Description, MAC Address, IP Address.

I don't really need description, MAC, or IP. What I'd rather have is a table that includes: 

Name, Drive, Space Left in GB.



0 Comments   [ + ] Show comments

Answers (3)

Posted by: binuani 2 years ago
Fourth Degree Green Belt
1

this is what we use

SELECT MACHINE_DISKS.PERCENT_USED AS MACHINE_DISKS_PERCENT_USED, MACHINE.NAME AS SYSTEM_NAME FROM MACHINE_DISKS JOIN MACHINE ON (MACHINE.ID = MACHINE_DISKS.ID) WHERE   MACHINE_DISKS.PERCENT_USED > '90' AND MACHINE_DISKS.NAME LIKE '%Drive C:%'

Posted by: hurmoth 2 years ago
White Belt
0

Unfortunately I still don't get an email with the information we're looking for. Still shows Description, MAC, and IP Address. I'm probably overlooking something simple.

AD7ptfuIbOPoAAAAAElFTkSuQmCC

Posted by: IgorAngelini 2 years ago
Second Degree Blue Belt
0

Try:

SELECT MACHINE.NAME AS SYSTEM_NAME,
SUBSTRING (MACHINE_DISKS.NAME, 1, 8) AS "DRIVE LETTER",
MACHINE_DISKS.PERCENT_USED

FROM MACHINE

LEFT JOIN MACHINE_DISKS
ON MACHINE_DISKS.ID = MACHINE.ID

WHERE MACHINE_DISKS.PERCENT_USED > '90'
AND OS_NAME like '%Server%'


See if it helps


Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ