[PLUTO-help] Di nuovo su hd sata e dma
    Paolo Ornati 
    ornati a fastwebnet.it
       
    Sab 28 Maggio 2005 14:19:29 CEST
    
    
  
On Sat, 28 May 2005 14:15:42 +0200
Paolo Ornati <ornati a fastwebnet.it> wrote:
> Ho fatto un piccolo script che allego... per utilizzarlo serve una
> partizione dedicata (il motivo per cui smonto / monto la partizione è per
> buttare via tutta la cache associata a quella partizione che altrimenti
> comprometterebbe i test).
L'allegato è stato mangiato :-!  (perchè??)
Lo pasto qui:
#!/bin/bash
MP=/mnt/other	# mount point di una partizione
SIZE="512"
BIGFILE="$MP/bigfile"
flush_cache()
{
	echo "flushing cache"
	umount "$MP"
	mount  "$MP"
	sleep 1
}
mount "$MP"
if [ ! -f "$BIGFILE" ]; then
	echo -n "Creating BIG file... "
	dd if=/dev/zero of="$BIGFILE" bs=1M count="$SIZE"
	echo "ok!"
fi
flush_cache
echo "*** Leggo $SIZE MB ***"
time dd if="$BIGFILE" of=/dev/null bs=1M
flush_cache
echo "*** Copio $SIZE MB ***"
time cp "$BIGFILE" "${BIGFILE}2"
rm -f "${BIGFILE}2"
umount "$MP"
--
	Paolo Ornati
	Gentoo Linux
    
    
More information about the pluto-help
mailing list