Does anyone have a script to check disk space usage.
My backup directory keeps filling up with archivelog files and
I need a script to let me know by email or pager when the filesystem is 80% full.
Thank you! (1 Reply)
I noticed that whenever something is printed from my workstation, the available disk space in the /dev/dsk/c0t0d0s0 decreases considerably. Hence, after using my workstation for sometime, I encounter an error message: "Filesystem Full" that prevents me from printing any further.
Is there a way to... (16 Replies)
Hi there all,
#!/usr/bin/ksh
Set -x
MIN_MB_FREE="100MB" # Min. MB of Free FS Space
MAX_PERCENT="85%" # Max. FS percentage value
FSTRIGGER="1000MB" # Trigger to switch from % Used to MB Free
WORKFILE="/tmp/df.work" # Holds filesystem data
>$WORKFILE #... (0 Replies)
my root filesystem is eventually full "/dev/rdsk/c1d0s0" as a result i cannot boot to the operating system, i booted into the fail safe mode to check the space using df -h command i discover that it is eventually full. Also to my amazement i found that i cannot see the filesystem which mounted on... (1 Reply)
Hello everybody, a very basic question.
Inspite of me deleting huge files in a filesystem(AIX 5.3) in oracle folder, the filesystem when i check using df -k still shows 100% full. Does that mean there is a process still pointing to the files which i deleted. how do i work around this.
Thanks!... (3 Replies)
I'd like to create a cron script that checks filesystems. For example if it reaches 95% USED, I'd like it to send me an email. Can this be possible for up to say 4 filesystems using the df -k command? Any samples to get me started would be much appreciated. (7 Replies)
Hi all,
I got an error when running this script (from BigAdmin community)
the error is
test: argument expected
my server version is
SunOS XXX 5.8 Generic_117350-46 sun4u sparc SUNW,Sun-Fire-V890
any idea on it?
#! /usr/bin/ksh
###
### This script can be run from cron to... (9 Replies)
Hello Scripts Guru
I had created a shell script to monitor the threshold of the file system, but some where it is not giving the correct output. Request to all to hel me out
I am getting the following output
/dev/vg00/lvol3 mounted on 1865224 10% / is 2097152%
/dev/vg00/lvol1 mounted on... (2 Replies)
In our shop we have to run a batch cycle. Every so often while we are running batch we get a filesystem full situation that causes batch to stop or slow down. Anyway, the practiced procedure is to look for large files and zip them. This takes a lot of time. We are in a sun solaris environment. What... (1 Reply)
I am on SCO UNIX, I need to write a script to monitor root file system. For some reason it's not working for me.
#!/bin/sh
df -B / | awk '{ print $5 " " $1 }' | while read output;
do
echo $output
if ; then
echo "Running out of space \ HOSTNAME"
# mail -s "Alert: Almost out of... (8 Replies)
Discussion started by: samnyc
8 Replies
LEARN ABOUT DEBIAN
ocf_heartbeat_filesystem
OCF_HEARTBEAT_FILESY(7) OCF resource agents OCF_HEARTBEAT_FILESY(7)NAME
ocf_heartbeat_Filesystem - Manages filesystem mounts
SYNOPSIS
Filesystem [start | stop | monitor | meta-data | validate-all]
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 type of filesystem to be mounted. (required, string, no default)
options
Any extra options to be given as -o options to mount. .sp 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/)
run_fsck
Specify how to decide whether to run fsck or not. .sp "auto" : decide to run fsck depending on the fstype(default) "force" : always run
fsck regardless of the fstype "no" : do not run fsck ever. (optional, string, default auto)
fast_stop
Normally, we expect no users of the filesystem and the stop operation to finish quickly. If you cannot control the filesystem users
easily and want to prevent the stop action from failing, then set this parameter to "no" and add an appropriate timeout for the stop
operation. (optional, boolean, default yes)
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 p_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 UNKNOWN 03/09/2014 OCF_HEARTBEAT_FILESY(7)