Sponsored Content
Full Discussion: Disk space threshold report
Top Forums Shell Programming and Scripting Disk space threshold report Post 302842165 by Just Ice on Thursday 8th of August 2013 01:52:23 PM
Old 08-08-2013
first off, assistance you receive on this website is offered by unpaid volunteers on their own time -- that includes me -- so it would be good to maintain a professional tone ...

second, your issue is that your report is empty except for the Filesystem line and i have given you the fix for it which is to grep it out (see red font in prior post) ... if you run the df -g | awk '+$4 >= 70 {print}' by itself and no filesystem is over the threshold, you will only get the Filesystem line ... if you run the same command and a filesystem reaches the threshold, the Filesystem line will get printed with the actual filesystem info that hit the threshold ...

you need to reread the script as given and test as well as understand each line before you demand help
These 3 Users Gave Thanks to Just Ice For This Post:
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Out of disk space?

Hi I'm trying to install gcc and the installation program tells me that I'm out of disk space! I have just installed the os (using the default settings for partitions and sizes) and have only installed apache on the machine. Can it really be out of disk space already? How do I check how much... (4 Replies)
Discussion started by: alfabetman
4 Replies

2. Filesystems, Disks and Memory

Disk Space -

I know I have posted this question before, but I still just don't understand how to determine disk space. This server is an IBM RS6000 running on AIX version 4.2.1. I in essence need to know the following if anyone can assist me. 1) I need to know how many drives are configured in the... (2 Replies)
Discussion started by: Docboyeee
2 Replies

3. UNIX for Dummies Questions & Answers

available disk space on disk device???

Hello, Can someone please tell me which command to use to determine the available disk space on a given disk device? I have to write a shell script that compresses files and stores them in a specific location but I am not sure how "conservative" I should be? Thanks in advance! Al. (4 Replies)
Discussion started by: alan
4 Replies

4. HP-UX

Disk Space

Hi Experts. I had 100% disk full , even though i have removed 2 GB space still dbf command shows 100%. How to rectify that. Appreciate your prompt help. Thanks (1 Reply)
Discussion started by: test10002
1 Replies

5. Shell Programming and Scripting

Disk Space

HI ... I am New to the Unix...I am trying to write a script to check the disk space. But i am not able to write it. I know the command to check the disk space df -k,but unable to write the script..Can any body help me... Thanks in advance... (3 Replies)
Discussion started by: Kingkon
3 Replies

6. Shell Programming and Scripting

Disk Space

Hi This is my script for disk space monitoring clear if then echo "You must be root user to execute the script" fi ALERT_LEVEL=10 CONSUMPTION_LEVEL= `df -k | awk {'print $5'} | cut -d '%' -f1 | sed "1 d"` for i in $CONSUMPTION_LEVEL do FILE_SYSTEM=`df -k | awk {'print $1'} |... (3 Replies)
Discussion started by: chrs0302
3 Replies

7. Red Hat

disk space

when i check /export directory of my machine gets filled up (85%) i removed some old logs. but after cleaning df -k command still shows that /export is still 85% full. Is there a way to force df to reflect actual free space without rebooting? My machine is a production one and can't... (8 Replies)
Discussion started by: aboorkuma
8 Replies

8. Shell Programming and Scripting

Check space of directories and send email if it has reached threshold limit

Hi, I need help in writing unix script for checking space of some directories on the system and also send an email when it reaches the threshold limit. I have written the followng code; #!/bin/ksh ADMIN="me@somewhere.com" # set alert level 80% is default THRESHOLD=80 df | grep -E... (5 Replies)
Discussion started by: jmathew99
5 Replies

9. Shell Programming and Scripting

disk space

Hi, I am new to shell scripting, and want to monitor disk space using shell script continously on server, which will shoot mail after crossing threshold limit Please suggest. Regards Manoj (1 Reply)
Discussion started by: manoj.solaris
1 Replies
OCF_HEARTBEAT_FILESY(7) 					OCF resource agents					   OCF_HEARTBEAT_FILESY(7)

NAME
ocf_heartbeat_Filesystem - Manages filesystem mounts SYNOPSIS
Filesystem [start | stop | notify | monitor | validate-all | meta-data] DESCRIPTION
Resource script for Filesystem. It manages a Filesystem on a shared storage medium. The standard monitor operation of depth 0 (also known as probe) checks if the filesystem is mounted. If you want deeper tests, set OCF_CHECK_LEVEL to one of the following values: 10: read first 16 blocks of the device (raw read) This doesn't exercise the filesystem at all, but the device on which the filesystem lives. This is noop for non-block devices such as NFS, SMBFS, or bind mounts. 20: test if a status file can be written and read The status file must be writable by root. This is not always the case with an NFS mount, as NFS exports usually have the "root_squash" option set. In such a setup, you must either use read-only monitoring (depth=10), export with "no_root_squash" on your NFS server, or grant world write permissions on the directory where the status file is to be placed. SUPPORTED PARAMETERS
device The name of block device for the filesystem, or -U, -L options for mount, or NFS mount specification. (required, string, no default) directory The mount point for the filesystem. (required, string, no default) fstype The optional type of filesystem to be mounted. (required, string, no default) options Any extra options to be given as -o options to mount. For bind mounts, add "bind" here and set fstype to "none". We will do the right thing for options such as "bind,ro". (optional, string, no default) statusfile_prefix The prefix to be used for a status file for resource monitoring with depth 20. If you don't specify this parameter, all status files will be created in a separate directory. (optional, string, default .Filesystem_status/) SUPPORTED ACTIONS
This resource agent supports the following actions (operations): start Starts the resource. Suggested minimum timeout: 60. stop Stops the resource. Suggested minimum timeout: 60. notify Suggested minimum timeout: 60. monitor Performs a detailed status check. Suggested minimum timeout: 40. Suggested interval: 20. validate-all Performs a validation of the resource configuration. Suggested minimum timeout: 5. meta-data Retrieves resource agent metadata (internal use only). Suggested minimum timeout: 5. EXAMPLE
The following is an example configuration for a Filesystem resource using the crm(8) shell: primitive example_Filesystem ocf:heartbeat:Filesystem params device=string directory=string fstype=string op monitor depth="0" timeout="40" interval="20" SEE ALSO
http://www.linux-ha.org/wiki/Filesystem_(resource_agent) AUTHOR
Linux-HA contributors (see the resource agent source for information about individual authors) resource-agents 1.0.3 07/05/2010 OCF_HEARTBEAT_FILESY(7)
All times are GMT -4. The time now is 05:39 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy