Quote:
Originally Posted by xeleema
Hey, that looks pretty handy! I've never heard of pv up till now.
For anyone else wondering what that is, it's "pipe viewer" ( homepage here). Looks like a handy little bugger. 
|
Very. With a little imagination it can become a very neat tool.
For example: copying a file with progress...
Code:
pv somefile.txt > /location/somefile.txt
Drive Read test
Code:
pv /dev/zero > /dev/null
Zipping a file with progress
Code:
pv some_file_to_compress.txt | gzip > file_compressed.gz
Copy a file over an SSH tunnel with progress
Code:
pv output.dat | gzip | ssh -p 22 root@3.2.12.12 "cat > /backups/dir/output.tar.gz"
Import a SQL backup with progress (Awesome IMHO)
Code:
pv db.sql | mysql database_name