Tool for batch compacting.

cbugg: close bug-481