This is an old revision of the document!
rgetz@brain:~/newest$ time wget http://swdownloads.analog.com/cse/2014_R2-2015_02_06.img.xz --2014-12-15 17:12:33-- http://swdownloads.analog.com/cse/2014_R2-2015_02_06.img.xz Resolving swdownloads.analog.com (swdownloads.analog.com)... 81.196.26.153, 81.196.26.177 Connecting to swdownloads.analog.com (swdownloads.analog.com)|81.196.26.153|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 787801476 (755M) [application/octet-stream] Saving to: `2014_R2-2014_R2-2015_02_06.img.xz' 100%[=======================================================================================================================================================================>] 787,801,476 1.94M/s in 6m 52s 2014-12-15 17:19:26 (1.83 MB/s) - `2014_R2-2014_R2-2015_02_06.img.xz' saved [787801476/787801476] real 6m53.573s user 0m0.740s sys 0m32.342sYeah, it takes an hour (or more if your connection is slow). At least you can drive down to your favourite coffee store, and indulge yourself.
rgetz@brain:~/newest$ md5sum 2014_R2-2015_02_06.img.xz bb76031fcd68fd9b1a175a2f7fd3e053 2014_R2-2015_02_06.img.xz
xz
file is a compressed file, you need to uncompress it, and check the md5sum:rgetz@brain:~/newest$ time unxz 2014_R2-2015_02_06.img.xz real 1m17.40s user 74.44s sys 2.11sNow is the time you eat the doughnut that you bought when you were out.
rgetz@brain:~/newest$ md5sum 2014_R2-2015_02_06.img 132d03a2888db34f10f0ebbcb3100ae7 2014_R2-2015_02_06.img rgetz@brain:~/newest$ ls -l 2014_R2-2015_02_06.img -rw-rw-r-- 1 rgetz rgetz 7948206080 Feb 6 16:44 2014_R2-2015_02_06.img rgetz@brain:~/newest$ ls -lh 2014_R2-2015_02_06.img -rw-rw-r-- 1 rgetz rgetz 7.5G Feb 6 16:44 2014_R2-2015_02_06.img
It is recommended to use Etcher to write to your SD card but other options exist. Only the process for Etcher is covered here.
Insert your target SD card and launch Etcher. With Etcher:
At this point the SD card is still not bootable. Go back to Preparing the image.
Now that everything looks OK, write the file to your SD Card.
This will depend on your system, where your SD card installed itself. You also need to do this as root, since normal users shouldn't be able to randomly write files to block devices.
rgetz@brain:~/newest$ sudo umount /dev/mmcblk0p1
if
) to the storage device (output file or of
):rgetz@brain:~/newest$ time sudo dd if=2014_R2-2015_02_06.img of=/dev/mmcblk0 bs=4194304 [sudo] password for rgetz: 0+60640 records in 0+60640 records out 7948206080 bytes (7.9 GB) copied, 571.766 s, 13.9 MB/s real 7m54.11s user 0.29s sys 8.94sNow, you have have that slice of pizza that you got too… :)
rgetz@brain:~/newest$ sync
Since it's possible that the write process of a disk image can have some issues (if the target had a sector marked as bad, dd will not notice, and write on top of it), the safest thing to do is to run a file system consistency check on things. If you are unsure of how to use this tool, check the man page.
Most Linux kernels will need to have a physical eject between the steps above, and the steps below.
rgetz@brain:~/images$ sudo umount /dev/mmcblk0p1 rgetz@brain:~/images$ sudo umount /dev/mmcblk0p2. If this errors, with a
umount: /dev/mmcblk0p2: not mounted
, that's OK. If it errors with umount: /dev/mmcblk0p2: not found
, that means you have no disk inserted, or did a typo in the path.rgetz@brain:~/images$ sudo fsck -y /dev/mmcblk0p1 fsck from util-linux 2.20.1 dosfsck 3.0.13, 30 Jun 2012, FAT32, LFN /dev/mmcblk0p1: 158 files, 76420/130812 clusters rgetz@brain:~/images$ sudo fsck -y /dev/mmcblk0p2 fsck from util-linux 2.20.1 e2fsck 1.42.5 (29-Jul-2012) /dev/mmcblk0p2: clean, 157918/452480 files, 717760/1808128 blocks
At this point the SD card is still not bootable. Go back to Preparing the image.