Filesys::DiskSpace(3pm) User Contributed Perl Documentation Filesys::DiskSpace(3pm)NAME
Filesys::DiskSpace - Perl df
SYNOPSIS
use Filesys::DiskSpace;
($fs_type, $fs_desc, $used, $avail, $fused, $favail) = df $dir;
DESCRIPTION
This routine displays information on a file system such as its type, the amount of disk space occupied, the total disk space and the number
of inodes. It tries "syscall(SYS_statfs)" and "syscall(SYS_statvfs)" in several ways. If all fails, it "croak"s.
OPTIONS
$fs_type
[number] type of the filesystem.
$fs_desc
[string] description of this fs.
$used
[number] size used (in Kb).
$avail
[number] size available (in Kb).
$ffree
[number] free inodes.
$fused
[number] inodes used.
Installation
See the INSTALL file.
COPYRIGHT
Copyright (c) 1996-1999 Fabien Tassin. All rights reserved. This program is free software; you can redistribute it and/or modify it under
the same terms as Perl itself.
AUTHOR
Fabien Tassin <fta+cpan@sofaraway.org>
NOTES
This module was formerly called File::Df. It has been renamed into Filesys::DiskSpace. It could have be Filesys::Df but unfortunatly
another module created in the meantime uses this name.
Tested with Perl 5.003 under these systems :
- Solaris 2.[4/5]
- SunOS 4.1.[2/3/4]
- HP-UX 9.05, 10.[1/20] (see below)
- OSF1 3.2, 4.0
- Linux 2.0.*, 2.2.*
Note for HP-UX users :
if you obtain this message :
"Undefined subroutine &main::SYS_statfs called at Filesys/DiskSpace.pm
line XXX" and if you are using a hp9000s700, then edit the syscall.ph file
(in the Perl lib tree) and copy the line containing "SYS_statfs {196;}"
outside the "if (defined &__hp9000s800)" block (around line 356).
perl v5.14.2 2012-04-12 Filesys::DiskSpace(3pm)
Check Out this Related Man Page
Perl::Critic::Policy::Modules::RequireEndWithOne(3pm) User Contributed Perl Documentation Perl::Critic::Policy::Modules::RequireEndWithOne(3pm)NAME
Perl::Critic::Policy::Modules::RequireEndWithOne - End each module with an explicitly "1;" instead of some funky expression.
AFFILIATION
This Policy is part of the core Perl::Critic distribution.
DESCRIPTION
All files included via "use" or "require" must end with a true value to indicate to the caller that the include was successful. The
standard practice is to conclude your .pm files with "1;", but some authors like to get clever and return some other true value like
"return "Club sandwich";". We cannot tolerate such frivolity! OK, we can, but we don't recommend it since it confuses the newcomers.
CONFIGURATION
This Policy is not configurable except for the standard options.
AUTHOR
Chris Dolan "cdolan@cpan.org"
Some portions cribbed from Perl::Critic::Policy::Modules::RequireExplicitPackage.
COPYRIGHT
Copyright (c) 2005-2011 Chris Dolan and Imaginative Software Systems. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of this license
can be found in the LICENSE file included with this module.
perl v5.14.2 2012-06-07 Perl::Critic::Policy::Modules::RequireEndWithOne(3pm)
Hi,
I'm a teacher in Germany and I want to set up a classroom with Linux 8.1 PCs. Every User should have a Max of 100 MB available space. Now I need a script which tells everyone how much diskspace is used in a certain subdirectory.
It should work like that: User enters a command like... (1 Reply)
Hi,
Somebody can help me to retrieve the command to use in Solaris 8 to display the space free on a Virtual disk created by VVM ?
Thanks very much,
Fabien Renaux (1 Reply)
Does anyone know a way to determine the maximum filesize on a file system on Solaris, HP-UX, AIX, Linux, and OSF1 using the command line?
TIA (2 Replies)
Hi All,
I am failry new to Perl.I am trying to install a Perl module (Filesys::df.pm) in an IBM AIX5.3 server.But I could not succeed in that.I am getting the following error:
abcd3dev# make
cc_r -c -D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE -qmaxmem=16384 -qnoansialias... (6 Replies)
#!/usr/bin/perl
use strict;
use warnings;
use Filesys::DiskSpace;
# file system to monitor
my $dir = "/opt";
# warning level
my $warning_level=10;
# email setup
my $to='mail@mail.com';
my $subject='Low Disk Space';
# get df
my ($fs_type, $fs_desc, $used, $avail, $fused,... (1 Reply)
Hi,
While am preparing the script for diskspace for different partitions different threshhold limit. am getting below error:
./test.sh: syntax error at line 5: `space=$' unexpected
Script
====
#!/bin/sh
df -h |grep -v '/oradata2'|grep -v '/orabkp' |grep -v '/oradata5' | awk '{ print $5... (7 Replies)
Hi I have a script that Checks
DiskSpace
Few Daemons status
Few FileAgent Status
I need to have a summary of the results on the top like this
DiskSpace:Ok/Not OK
Few Daemons status:Ok/Not OK
Few FileAgent Status:Ok/Not OK
The actual Script like the if conditions should be followed by... (5 Replies)
Hi,
I'm looking for a Perl module which can recursively list remote Windows shares from within a Linux machine.
I've tried Filesys::SmbClient ans Filesys:SmbClientPars but they just list the current directory
Thank You for your help (4 Replies)
Hi,
I have an issue with a PERL5 script that calls MQCONN. I get this error on this Perl step when connecting to my Q manager: "Undefined Undefined subroutine &main::MQCONN called at ./quelog.pl "
I use this code:$Hconn = MQCONN($QMGR,$CompCode,$Reason);
In my .profile:
export... (2 Replies)