Find SD Device: Difference between revisions

From embeddedTS Manuals
(Created page with "For imaging the SD card we recommend using a Linux or similar operating system that allows you to access a block device using dd. We do not support rewriting the SD card from...")
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 2: Line 2:


If you are reprogramming the SD card from your workstation you will also need to determine the SD card device.  Once you have connected the SD card to your workstation you can usually find the correct block device in the output of "dmesg".  For example:
If you are reprogramming the SD card from your workstation you will also need to determine the SD card device.  Once you have connected the SD card to your workstation you can usually find the correct block device in the output of "dmesg".  For example:
  [  304.255153] usb 1-2: new high speed USB device using ehci_hcd and address 3
  [  304.390989] usb 1-2: New USB device found, idVendor=048d, idProduct=1336
  [  304.390992] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
  [  304.390994] usb 1-2: Product: Mass Storage Device
  [  304.390995] usb 1-2: Manufacturer: Generic 
  [  304.390997] usb 1-2: SerialNumber: 00000000000006
  [  304.391173] usb 1-2: configuration #1 chosen from 1 choice
  [  304.484178] Initializing USB Mass Storage driver...
  [  304.484606] scsi8 : SCSI emulation for USB Mass Storage devices
  [  304.484872] usb-storage: device found at 3
  [  304.484873] usb-storage: waiting for device to settle before scanning
  [  304.484912] usbcore: registered new interface driver usb-storage
  [  304.484915] USB Mass Storage support registered.
  [  309.484699] usb-storage: device scan complete
  [  309.494615] scsi 8:0:0:0: Direct-Access    Generic  Storage Device  0.00 PQ: 0 ANSI: 2
  [  309.496053] sd 8:0:0:0: Attached scsi generic sg2 type 0
   [  309.498834] sd 8:0:0:0: [sdb] 3862528 512-byte logical blocks: (1.97 GB/1.84 GiB)
   [  309.498834] sd 8:0:0:0: [sdb] 3862528 512-byte logical blocks: (1.97 GB/1.84 GiB)
   [  309.519814] sd 8:0:0:0: [sdb] Write Protect is off
   [  309.519814] sd 8:0:0:0: [sdb] Write Protect is off
Line 27: Line 11:
   [  309.559676] sd 8:0:0:0: [sdb] Attached SCSI removable disk
   [  309.559676] sd 8:0:0:0: [sdb] Attached SCSI removable disk


On this system my SD card block device is /dev/sdb, but your system will likely be different.  The block devices are allocated in order by the letter so the next USB drive connected would be /dev/sdc.  On some newer kernels you will see '/dev/mmcblk0' as the block device and '/dev/mmcblkop1' for the first partition.  For these examples I will use the '/dev/mmcblk0' format.
On this system my SD card block device is /dev/sdb, but your system will likely be different.  The block devices are allocated in order by the letter so the next USB drive connected would be /dev/sdc.  On some newer kernels you will see '/dev/mmcblk0' as the block device and '/dev/mmcblk0p1' for the first partition.  For these examples I will use the '/dev/mmcblk0' format.


{{Warning|Many distributions will name your hard drive something like /dev/sda or /dev/hda which will have the same naming scheme as an SD card or a USB drive.  Make sure you are aware which device is which before writing the disk.}}
{{Warning|Many distributions will name your hard drive something like /dev/sda or /dev/hda which will have the same naming scheme as an SD card or a USB drive.  Make sure you are aware which device is which before writing the disk.  Technologic Systems is not responsible for any data lost/destroyed because of improper command execution.}}

Latest revision as of 10:41, 14 February 2013

For imaging the SD card we recommend using a Linux or similar operating system that allows you to access a block device using dd. We do not support rewriting the SD card from Windows.

If you are reprogramming the SD card from your workstation you will also need to determine the SD card device. Once you have connected the SD card to your workstation you can usually find the correct block device in the output of "dmesg". For example:

 [  309.498834] sd 8:0:0:0: [sdb] 3862528 512-byte logical blocks: (1.97 GB/1.84 GiB)
 [  309.519814] sd 8:0:0:0: [sdb] Write Protect is off
 [  309.519818] sd 8:0:0:0: [sdb] Mode Sense: 03 00 00 00
 [  309.519819] sd 8:0:0:0: [sdb] Assuming drive cache: write through
 [  309.536025] sd 8:0:0:0: [sdb] Assuming drive cache: write through
 [  309.536029]  sdb: sdb1 sdb2 sdb3
 [  309.559672] sd 8:0:0:0: [sdb] Assuming drive cache: write through
 [  309.559676] sd 8:0:0:0: [sdb] Attached SCSI removable disk

On this system my SD card block device is /dev/sdb, but your system will likely be different. The block devices are allocated in order by the letter so the next USB drive connected would be /dev/sdc. On some newer kernels you will see '/dev/mmcblk0' as the block device and '/dev/mmcblk0p1' for the first partition. For these examples I will use the '/dev/mmcblk0' format.

WARNING: Many distributions will name your hard drive something like /dev/sda or /dev/hda which will have the same naming scheme as an SD card or a USB drive. Make sure you are aware which device is which before writing the disk. Technologic Systems is not responsible for any data lost/destroyed because of improper command execution.