Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: file size monitoring

by kennethk (Abbot)
on Sep 03, 2013 at 17:50 UTC ( #1052156=note: print w/replies, xml ) Need Help??

in reply to file size monitoring

What have you tried? What worked? What didn't? We're happy to help design and debug, but we won't do your work for you.

I'm not familiar with 'HP OVO product' and so don't know the necessary reporting formats, and didn't see any affiliated modules on CPAN. I also don't know what definition of megabyte you are using. I would expect -s will be useful, as will opendir and readdir. That chunk may look something like (untested):

my $dir = 'somewhere'; opendir my $dh, $dir or die $!; while (my $file = readdir $dh) { print "Too big: $file\n" if -s "$dir/$file" > 1024**2 }

You may also want to look at File::Find.

#11929 First ask yourself `How would I do this without a computer?' Then have the computer do it the same way.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1052156]
[LanX]: holli: LOL
[LanX]: moritz: why ? family?
[LanX]: or other language?
[moritz]: LanX because of usability issues, and the lack of evolvement
[holli]: lol to the robust charme or to the data transfer?
[holli]: it works fine with Lynx though :)
[LanX]: it's easier to patch then to migrate to a PHP board, there are many semantics like linking , authorisation, templates ,...
[LanX]: I've only seen 30% of the semi professional documentation
[holli]: i was just thinking of the bare content.
[LanX]: Plenty of "templates" realised with CGI-HTML-function

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (7)
As of 2017-11-20 19:29 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (292 votes). Check out past polls.