Operating System - OpenVMS
1827295 Members
3961 Online
109717 Solutions
New Discussion

Re: Fragmentation of disk drive

 
Mrityunjoy Kundu
Frequent Advisor

Fragmentation of disk drive

How can i check the fragmentation of any disk drive,and is it possible to defrag the volume without dismounting the device.
10 REPLIES 10
Ian Miller.
Honored Contributor

Re: Fragmentation of disk drive

There are free utilities such as DFU and reporting programs that come with HP DFO.
Executive software also do a free fragmentation reporting utility - see
http://www.executive.com/freeware/freeware.asp

You can see if file fragmentation is having an affect by looking at window turns and split I/O rate in the MONITOR utility.
____________________
Purely Personal Opinion
Karl Rohwedder
Honored Contributor

Re: Fragmentation of disk drive

The DFU utility (from HP, found on the freeware archives) can create reports on disk usage, containing fragmentation indexes for the files and for the free space.
It also allows for the defragmentation of individual files (more like COPY/CONTIG does).
To defragment complete disks under load you may use the HP product 'Disk File Optimizer',but that costs money.

regards Kalle
Wim Van den Wyngaert
Honored Contributor

Re: Fragmentation of disk drive

And note that open files are not defragmented. So, close as much as possible. Restart long running processes that are generating big log files as much as possible because they might lock small segments scattered all over the disk thus preventing free space consolidation.

Wim
Wim
comarow
Trusted Contributor

Re: Fragmentation of disk drive

Almost all the defragmenters have a free tool that lets you check fragmentation.

This includes DFO.

Not all fragmentation is bad, since it uses the last freed block to use a block. Thus, some mixture of free space, contrary to popular wisdom, will improve performance.

Larger cluster sizes and RMS extent sizes will help prevent fragmentation and improve performance at the cost of some disk space.
Disk space is cheap. Cheaper than user time.

As mentioned, large log files are real killers. Especially if they do not pre-allocate space and are being written to a bit at a time. Closing the utilities associated with Accountng.dat, errlog.sys and operator.log can creating new versions of these file, with a larger extent can really help over time.
Jim Lahman_1
Advisor

Re: Fragmentation of disk drive

This might be a little off topic, but in the days before defrag utils, I'd perform a restore from an image backup. Doesn't this still apply?

Jim
Cheers!
Jan van den Ende
Honored Contributor

Re: Fragmentation of disk drive

@Jim,

>>>
This might be a little off topic, but in the days before defrag utils, I'd perform a restore from an image backup. Doesn't this still apply?
<<<

Yeah, it still applies... _IF_ you can afford the off-line time (of for system disk, Down time).
Many, many of the sites using VMS nowadays, are doing that BECAUSE of the 24*7, or 24*365 capabilities, and _THEN_ that option is a little bit out of the question.

Just my EUR 0,02

(notice, even the decimal COMMA is un-english!)

Proost.

Have one on me.

jpe
Don't rust yours pelled jacker to fine doll missed aches.
Andy Bustamante
Honored Contributor

Re: Fragmentation of disk drive

Before you start scheduling downtime, is fragmentation having an impact? Use monitor to check window turn rate and split transfer rates:

$ monitor fcp
$ monitor io

A disk can be severely fragmented and not create a performance issue if it doesn't create significant i/o. Purging log files is usually enough to defrag a system disk.

Andy
If you don't have time to do it right, when will you have time to do it over? Reach me at first_name + "." + last_name at sysmanager net
Wim Van den Wyngaert
Honored Contributor

Re: Fragmentation of disk drive

Don't forget to monitor the "maximum free extent" on the disk. This is what gives most problems (on my site anyway). Under 10000 blocks is a red alert here. And I have seen that during defragments, this value was VERY low, so a threat to the well being of the production environment.

Wim
Wim
Ziggy Filek
Frequent Advisor

Re: Fragmentation of disk drive

You can directly check fragmentation state of any file by executing

$ PIPE DUMP/HEADER | TYPE SYS$INPUT /PAGE

and look for the list of retrieval pointers looking like this:


Map area
Retrieval pointers
Count: 36 LBN: 1280646

Each "Count ... LBN..." line is one fragment. Multiple "Count:..."lines mean fragmented file. I have seen files with hundreds and hundreds of pointers to fragments...

Ziggy
Hein van den Heuvel
Honored Contributor

Re: Fragmentation of disk drive

DFU is a really easy and effective tool here.

$define dfu$nosmg yes
$dfu sea/frag=min=100 sys$disk:

>> I have seen files with hundreds and hundreds of pointers to fragments...

I'll see your hundreds of pointers and raise you hundred fifty headers.

:-)

>> $ PIPE DUMP/HEADER | TYPE SYS$INPUT /PAGE

Too much work! Try this:

$ perl -e "foreach (`dump/head/bloc=cou=0 $ARGV[0]`) { $h++ if /^Check/; $m++ if /Count:/} print qq($h headers, $m pointers.\n)"

More :-)
Hein.