User Tools

Site Tools


blog:copy_a_filesystem_from_one_computer_to_another_using_tar_and_netcat

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
blog:copy_a_filesystem_from_one_computer_to_another_using_tar_and_netcat [2009-10-12 10:00] brbblog:copy_a_filesystem_from_one_computer_to_another_using_tar_and_netcat [2009-10-12 10:18] (current) brb
Line 7: Line 7:
  
   cd /mnt/sda1   cd /mnt/sda1
-  tar -czpsf - . | pv -b | nc -l 3333+  tar -czpsf - . | pv -b | nc -l -p 3333
  
   * On the destination machine, mount the partition to receive the filesystem, and start the process:   * On the destination machine, mount the partition to receive the filesystem, and start the process:
  
   cd /mnt/sda1   cd /mnt/sda1
-  nc 192.168.10.101 3333 | pv -b | tar -xzpsf -+  nc 192.168.1.3333 | pv -b | tar -xzpsf -
  
 The nc (netcat) command is used for any kind of TCP connections between two hosts. The pv (progress viewer) command is used to display the progress of the transfer. tar is used to archive the files on the source machine and un-archive them on the destination. The nc (netcat) command is used for any kind of TCP connections between two hosts. The pv (progress viewer) command is used to display the progress of the transfer. tar is used to archive the files on the source machine and un-archive them on the destination.
blog/copy_a_filesystem_from_one_computer_to_another_using_tar_and_netcat.txt · Last modified: 2009-10-12 10:18 by brb