Current Issue


Table of contents

CD-ROM

Sys Admin and The Perl Journal CD-ROM version 12.0

Version 12.0 delivers every issue of Sys Admin from 1992 through 2006 and every
issue of The Perl Journal from 1996-2002 in one convenient CD-ROM!

Order now!

Sys Admin Magazine > Archives > 2002 > September

Finding Old Things

Randal L. Schwartz

One of the great things about the Perl community is seen in the many ways that Perl information can be obtained to solve typical tasks or to get past those sticky little problems. Besides the professional documentation, there’s also the myriad of man pages that come with the Perl distribution itself, and the CPAN modules. And with a little searching on the Net, you can quickly find very active support for Perl in the way of Usenet newsgroups, mailing lists, and a few Web communities.

The most active Perl Web community that I participate in is known as the Perl Monastery, at http://perlmonks.org. Each day, a few hundred active users and a few thousand visitors post and answer questions and chat in the “chatterbox”. In my past role as a systems administrator, it seems like I was always under pressure to solve problems in annoyingly brief amounts of time. Therefore, the Monastery is a welcome resource, because questions often get answered within minutes, so help is just a browser-reload or two away.

Recently, a relatively new Monk (as we call the participants) who goes by the name “Aquilo” asked for help with a script that:

recurses through a directory structure and checks if more than half of the files in that directory have been used in the past 180 days. The path of directories which are predominately unused is appended to a list of directories which will be used to archive them.

Aquilo gave some sample code that performed directory recursion in the traditional beginner way. I say traditional, because one of Perl’s “rites of passage” seems to be to “write a directory recursion routine”. Generally, these solutions are not as flexible or efficient or portable as Perl’s built-in File::Find module, but beginners generally aren’t aware of this module.<>




MarketPlace

"Six Sigma" Certification
Villanova Six Sigma Certification 100% Online Program - Free Info.

PMP Certification-Online
Nation's Leading Online PMP Course From Villanova-Find Out More Now.

Flowcharts from C/C++ code -- Free trial download
Understand C/C++ code in less time. A new team member ? Inherited legacy code ? Get up to speed faster with Crystal Flow for C/C++. Code-formatting improves readability. Flowcharts are integrated with code browser. Export flowcharts to Visio.

Automate Software Builds with Visual Build Pro
Easily create an automated, repeatable process for building and deploying software.

Wanna see your ad here?