How to Back Up/Image your SD Card on Linux

preview_player
Показать описание
In this tutorial, I show you the process of backing up your SD card in Linux, so you can restore it to a new SD card or just save it for recovering later. We'll use the dd command, and I'll show a couple of different methods.

🙌 Support me on Patreon and get early access to new content!

🛒 Affiliate store for Linux compatible hardware/accessories (commission earned):

💻 Check out the Tiny Pilot KVM for your Homelab (commission earned):

🐦 Follow me on Twitter!

📖 Check out jay's latest book, Mastering Ubuntu Server 3rd Edition. Available now!

Wiki article for this video:

PiShrink:

👨 More about me:

💽 How to create a bootable flash drive for installing Linux:

🐧 Which distro do I use?

🔐 How to better secure OpenSSH:

☁️ How to create a cloud Linux server with Linode:
Рекомендации по теме
Комментарии
Автор

Great tutorial! I'm new to working with SD cards and need to create a bootable image of one to send to my team and was struggling with read errors. It seems like there's more reddit threads than real docs on how to do this. You're a lifesaver thank you.

andyblendermann
Автор

This is the best video on drive backups I have ever seen. Thanks a ton for this.

ganeshputtige
Автор

Finally I found someone who doesn't click and talk too fast. An you know what your doing and explain everything ty

eagleeyeviewimages
Автор

Brilliant video, clear and concise with a few good extra linux tips along the way. I have just subscribed to your channel.

daisukedais
Автор

thanks for the info. you presented the information with the patience of a great teacher, it shows that you are well informed in the subject matter and wanting to share your knowledge. a huge thumbs up

fixinnstuff
Автор

Excellent tutorial. And it's complete and very accurate. Great job LearnLinuxTV. :)

jancatalinnicoara
Автор

I can't seem to post where to find PiSafe. It is on that opensource developers website that starts with git and ends with hub. Then RichardMidnight then pi-safe. - peace

richardreed
Автор

14:50 can you help me which video that you show how to restore the sd card?
in my case, i just want to only read file in sdcard.img and save them

irsyadkhairullah
Автор

my dude! thanks for sharing this ! I really appreciate it ! <3

BonesofGoldSkateboarding
Автор

Great Video. It's full of information and it's nice when you show some another possibility to do the same thing. Thanks a lot.

themagicadriel
Автор

Thank you. This is just what I need to back up my gps memory card.

papuchobello
Автор

Thanks so much! It was so helpful and precise

alicejames
Автор

You did a great job explaining this. Thank you!

FF
Автор

Great tutorial, great teacher. Thanks you!

FranciscoJimenez-uzpl
Автор

This was very well explained. Thanks heaps for your time.

muzguz
Автор

NO! Use this form instead: sudo dd if=/dev/mmcblk0 of=sdcard.img bs=512 conv=noerror, sync status=progress. Not all SD cards are the same and one brand 8GB SD card may actually be smaller than another brand 8GB card. If you use a large block size and subsequently put the image on a new SD card you can get a not enough space error. Also, the large block size can result in extra random bytes from RAM added to the end of the image which are not part of the application you are backing up. A subsequent imaging of a new card may result in the application not running because the app doesn't like what's in the extra bytes - I've had this happen and fixed it with the smaller block size. Also do use the "status=progress" option. Large SD cards take a while to back up to an image and you don't want to have the system appear to be hanging - might cause you to kill the process needlessly. The smaller 512 block size will take longer to image than the 4M block size but it's worth the wait to get a good image. Also, probably best to test the image is good by writing it to another SD and trying the new SD card in the device.

bobb
Автор

You can use PiSafe to easily create a compressed image of your SD card or USB stick. Then restore it to a different device any time you like.

richardreed
Автор

QUESTION: Restoration to a new card --- size must be the same or larger than the original.
Only older clone programs, metadata from the original used to be copied to the image as well.
When that image was restored to new media and that media was physically larger than the original, the metadata would tell the computer OS that the new media had been transformed to (logically) the same size as the original media, rendering any larger data space unusable.
Q: does the dd command do the same here? or will the full data space still be available after the "restoration" function is complete...

THX

shARyn
Автор

Tried this process and after restore SD card won't boot my R Pi :( any clues why?

yuriw
Автор

There is one important step in restoring the .img file to another SD card which this video overlooks. The host did not need to do this because he did not take the SD card out or put in a new one. So His SD card is already unmounted. If you are doing this for real, you will need to unmount the dd card you just inserted in the computer using the umount cmd as before. He should have mentioned this and he should add this info to his notes.

OriginalSocalgranny