Path: usenet.cise.ufl.edu!huron.eel.ufl.edu!usenet.eel.ufl.edu!rill.news.pipex.net!pipex!cpk-news-hub1.bbnplanet.com!cam-news-hub1.bbnplanet.com!news.bbnplanet.com!news.mathworks.com!uunet!in3.uu.net!news.neta.com!not-for-mail From: Dan Sugalski Newsgroups: comp.lang.perl.announce,comp.lang.perl.modules Subject: Announcing: VMS::Device 0.01 Followup-To: comp.lang.perl.modules Date: 2 Jun 1998 18:46:11 GMT Organization: OSSHE Lines: 43 Approved: merlyn@stonehenge.com (comp.lang.perl.announce) Message-ID: <6l1h9j$q4f$1@news.neta.com> Reply-To: SUGALSKD@osshe.edu NNTP-Posting-Host: gadget.cscaper.com X-Disclaimer: The "Approved" header verifies header information for article transmission and does not imply approval of content. Xref: usenet.cise.ufl.edu comp.lang.perl.announce:69 comp.lang.perl.modules:1941 Announcing: VMS::Device 0.01 This is the first public release of VMS::Device. With this module you can list devices (by class, type, and/or name, with wild cards) and fetch information about those devices. It essentially provides the functionality of the DCL lexicals F$DEVICE and F$GETDVI. For example, with this little program: #! perl -w use VMS::Device qw(device_list device_info); foreach my $devname (device_list("*", "DISK")) { $DevHash = device_info($devname); $FreeBlocks = $DevHash->{FREEBLOCKS}; $MaxBlocks = $DevHash->{MAXBLOCK}; next unless $DevHash->{MOUNTCNT}; next unless $MaxBlocks; $PctFree = int(($FreeBlocks/$MaxBlocks) * 100); if ($PctFree < 10) { print "Only $PctFree\% on $devname ($FreeBlocks of $MaxBlocks)\n"; } } you can list out all the disks on your system that have less than 10% free space left. Future releases of VMS::Device will include the capabilities to mount, dismount, allocate, deallocate, and initialize devices, but that code's not done yet. Available on CPAN at $CPAN/modules/by-author/Dan_Sugalski/VMS-Device-0_01.zip, via the web at http://www.sidhe.org/misc/VMS-Device-0_01.zip, or via ftp at ftp://ftp.sidhe.org/VMS-Device-0_01.zip. The module's only been tested on OpenVMS Alpha 7.1, so it's undoubtedly got Vax and prior version issues. (Hey, it's a first beta release!) Please, if you try it and it doesn't work, send me some mail and I'll do what I can to fix it. .