Tuesday, October 1, 2013

Want to know what dd is doing?

From another terminal type kill -USR1 $pid, where pid=`pidof dd`. This causes dd to spit out data speeds and amounts transferred so far. you might wrap it up in something like:  
pid=`pidof dd` 
while [[ -d /proc/$pid ]]; 
do kill -USR1 $pid && sleep 5; 
done
Apparently pidof is deprecated or something?? If you only have one dd process running on your machine you might try pkill -USR1 -n -x dd the problem here being that you will keep asking for the pid of dd, and might get new ones. The -n is for the newest process, -o for the oldest, and leave it out completely to send to all running dd processes, like this:

pkill -USR1 -x dd 
enjoy.

No comments:

Post a Comment

THIS PAGE IS NO LONGER MAINTAINED, ALL CONTENT HAS BEEN MOVED TO http://rosrants.com. PLEASE VISIT http://rosrants.com IF YOU WISH TO LEAVE COMMENTS.

Note: Only a member of this blog may post a comment.