Created
July 20, 2012 09:11
-
-
Save ctavan/3149764 to your computer and use it in GitHub Desktop.
Cloning harddisks over the network using dd and nc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# clone harddisk from one machine to harddisk on another machine over the network | |
# on the target: | |
nc -l -p 7000 | gunzip | dd of=/dev/sda & | |
# on the source: | |
dd if=/dev/sda | gzip | nc <TARGET_IP> 7000 -q 10 & | |
# progress (on the source): | |
# get pid | |
pgrep dd -l | |
# get stats | |
kill -USR1 <PID> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment