Skip to content

Instantly share code, notes, and snippets.

@vignesh0025-zz
Created December 25, 2015 12:07
Show Gist options
  • Save vignesh0025-zz/543391cb8b4cc99e5421 to your computer and use it in GitHub Desktop.
Save vignesh0025-zz/543391cb8b4cc99e5421 to your computer and use it in GitHub Desktop.
Commands to img backup a drive and mount it
Take Image
----------
sudo dd if=/dev/sdb of=~/USB_image
where '/dev/sdb' is your usb drive as listed by 'sudo fdisk -l'
Restore Image
-------------
sudo dd if=~/USB_image of=/dev/sdb
Mount Image
-----------
mount ~/USB_image /mnt/USB_image -o loop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment