try following command > sudo ./setup_sdcard.sh --mmc /dev/sdX --uboot bone_dtb >
I was also getting same error, when I tried - > sudo ./setup_sdcard.sh --mmc /dev/sdX --uboot bone On Sunday, June 30, 2013 8:56:18 AM UTC+5:30, Crazy Monster wrote: > > Hi Robert, I am not having much luck with this .. I get the BLKRRPART: > Device or resource busy error and "ERROR: sector 3069841408 does not have > an msdos signature". Second time around, I did "dd if=/dev/zero > of=/dev/mmcblk0 bs=512 count=1" as it suggested but no luck (2nd round). > I then took out the SD card and reformatted as FAT32 with gparted, but > still no luck (3rd run below), its hung. Wonder why it says resource is > busy. I did have a tempfs mounted : > > tmpfs on /tmp/tmpfs type tmpfs (rw,size=3m) > and I ran the script from inside /tmp but I dont think that matters .. > > > root@arm:/tmp# ls > beaglebone-black-copy-eMMC-to-microSD.sh tmpfs > root@arm:/tmp# ./beaglebone-black-copy-eMMC-to-microSD.sh > update-initramfs: Generating /boot/initrd.img-3.8.13-bone21 > grep: /boot/config-3.8.13-bone21: No such file or directory > '/boot/initrd.img-3.8.13-bone21' -> '/boot/uboot/initrd.img' > Image Name: initramfs > Created: Sun Jun 30 02:54:14 2013 > Image Type: ARM Linux RAMDisk Image (uncompressed) > Data Size: 2709751 Bytes = 2646.24 kB = 2.58 MB > Load Address: 00000000 > Entry Point: 00000000 > umount: /dev/mmcblk0p1: not mounted > umount: /dev/mmcblk0p2: not mounted > 16+0 records in > 16+0 records out > 16777216 bytes (17 MB) copied, 0.142181 s, 118 MB/s > Checking that no-one is using this disk right now ... > BLKRRPART: Device or resource busy > > This disk is currently in use - repartitioning is probably a bad idea. > Umount all file systems, and swapoff all swap partitions on this disk. > Use the --no-reread flag to suppress this check. > > Disk /dev/mmcblk0: 60000 cylinders, 255 heads, 63 sectors/track > > sfdisk: ERROR: sector 3069370368 does not have an msdos signature > /dev/mmcblk0: unrecognized partition table type > Old situation: > No partitions found > New situation: > Units = mebibytes of 1048576 bytes, blocks of 1024 bytes, counting from 0 > > Device Boot Start End MiB #blocks Id System > /dev/mmcblk0p1 * 0+ 70- 71- 72261 e W95 FAT16 (LBA) > /dev/mmcblk0p2 70+ 1874- 1805- 1847475 83 Linux > /dev/mmcblk0p3 0 - 0 0 0 Empty > /dev/mmcblk0p4 0 - 0 0 0 Empty > Successfully wrote the new partition table > > Re-reading the partition table ... > BLKRRPART: Device or resource busy > The command to re-read the partition table failed. > Run partprobe(8), kpartx(8) or reboot your system now, > before using mkfs > If you created or changed a DOS partition, /dev/foo7, say, then use dd(1) > to zero the first 512 bytes: dd if=/dev/zero of=/dev/foo7 bs=512 count=1 > (See fdisk(8).) > root@arm:/tmp# ^C > > > > > root@arm:/tmp# dd if=/dev/zero of=/dev/mmcblk0 bs=512 count=1 > 1+0 records in > 1+0 records out > 512 bytes (512 B) copied, 0.00515201 s, 99.4 kB/s > root@arm:/tmp# > root@arm:/tmp# > root@arm:/tmp# ./beaglebone-black-copy-eMMC-to-microSD.sh > update-initramfs: Generating /boot/initrd.img-3.8.13-bone21 > grep: /boot/config-3.8.13-bone21: No such file or directory > '/boot/initrd.img-3.8.13-bone21' -> '/boot/uboot/initrd.img' > Image Name: initramfs > Created: Sun Jun 30 03:00:43 2013 > Image Type: ARM Linux RAMDisk Image (uncompressed) > Data Size: 2709750 Bytes = 2646.24 kB = 2.58 MB > Load Address: 00000000 > Entry Point: 00000000 > umount: /dev/mmcblk0p1: not mounted > umount: /dev/mmcblk0p2: not mounted > 16+0 records in > 16+0 records out > 16777216 bytes (17 MB) copied, 0.0885991 s, 189 MB/s > Checking that no-one is using this disk right now ... > BLKRRPART: Device or resource busy > > This disk is currently in use - repartitioning is probably a bad idea. > Umount all file systems, and swapoff all swap partitions on this disk. > Use the --no-reread flag to suppress this check. > > Disk /dev/mmcblk0: 60000 cylinders, 255 heads, 63 sectors/track > > sfdisk: ERROR: sector 3069546496 does not have an msdos signature > /dev/mmcblk0: unrecognized partition table type > Old situation: > No partitions found > New situation: > Units = mebibytes of 1048576 bytes, blocks of 1024 bytes, counting from 0 > > Device Boot Start End MiB #blocks Id System > /dev/mmcblk0p1 * 0+ 70- 71- 72261 e W95 FAT16 (LBA) > /dev/mmcblk0p2 70+ 1874- 1805- 1847475 83 Linux > /dev/mmcblk0p3 0 - 0 0 0 Empty > /dev/mmcblk0p4 0 - 0 0 0 Empty > Successfully wrote the new partition table > > Re-reading the partition table ... > BLKRRPART: Device or resource busy > The command to re-read the partition table failed. > Run partprobe(8), kpartx(8) or reboot your system now, > before using mkfs > If you created or changed a DOS partition, /dev/foo7, say, then use dd(1) > to zero the first 512 bytes: dd if=/dev/zero of=/dev/foo7 bs=512 count=1 > (See fdisk(8).) > root@arm:/tmp# nano ./beaglebone-black-copy-eMMC-to-microSD.sh > root@arm:/tmp# ./beaglebone-black-copy-eMMC-to-microSD.sh > + source=/dev/mmcblk1 > + destination=/dev/mmcblk0 > + check_running_system > + '[' '!' -f /boot/uboot/uEnv.txt ']' > + check_host_pkgs > + unset deb_pkgs > + dpkg -l > + grep dosfstools > + grep rsync > + dpkg -l > + grep u-boot-tools > + dpkg -l > + '[' '' ']' > + update_boot_files > ++ uname -r > + '[' '!' -f /boot/initrd.img-3.8.13-bone21 ']' > ++ uname -r > + update-initramfs -u -k 3.8.13-bone21 > update-initramfs: Generating /boot/initrd.img-3.8.13-bone21 > grep: /boot/config-3.8.13-bone21: No such file or directory > ++ uname -r > + '[' -f /boot/vmlinuz-3.8.13-bone21 ']' > ++ uname -r > + '[' -f /boot/initrd.img-3.8.13-bone21 ']' > ++ uname -r > + cp -v /boot/initrd.img-3.8.13-bone21 /boot/uboot/initrd.img > '/boot/initrd.img-3.8.13-bone21' -> '/boot/uboot/initrd.img' > ++ uname -r > + mkimage -A arm -O linux -T ramdisk -C none -a 0 -e 0 -n initramfs -d > /boot/initrd.img-3.8.13-bone21 /boot/uboot/uInitrd > Image Name: initramfs > Created: Sun Jun 30 03:02:45 2013 > Image Type: ARM Linux RAMDisk Image (uncompressed) > Data Size: 2709760 Bytes = 2646.25 kB = 2.58 MB > Load Address: 00000000 > Entry Point: 00000000 > + mount_n_check > + umount /dev/mmcblk0p1 > umount: /dev/mmcblk0p1: not mounted > + true > + umount /dev/mmcblk0p2 > umount: /dev/mmcblk0p2: not mounted > + true > + lsblk > + grep /dev/mmcblk0p1 > + repartition_emmc > + dd if=/dev/zero of=/dev/mmcblk0 bs=1M count=16 > 16+0 records in > 16+0 records out > 16777216 bytes (17 MB) copied, 0.143162 s, 117 MB/s > + LC_ALL=C > + sfdisk --force --DOS --sectors 63 --heads 255 --unit M /dev/mmcblk0 > Checking that no-one is using this disk right now ... > BLKRRPART: Device or resource busy > > This disk is currently in use - repartitioning is probably a bad idea. > Umount all file systems, and swapoff all swap partitions on this disk. > Use the --no-reread flag to suppress this check. > > Disk /dev/mmcblk0: 60000 cylinders, 255 heads, 63 sectors/track > > sfdisk: ERROR: sector 3069841408 does not have an msdos signature > /dev/mmcblk0: unrecognized partition table type > Old situation: > No partitions found > New situation: > Units = mebibytes of 1048576 bytes, blocks of 1024 bytes, counting from 0 > > Device Boot Start End MiB #blocks Id System > /dev/mmcblk0p1 * 0+ 70- 71- 72261 e W95 FAT16 (LBA) > /dev/mmcblk0p2 70+ 1874- 1805- 1847475 83 Linux > /dev/mmcblk0p3 0 - 0 0 0 Empty > /dev/mmcblk0p4 0 - 0 0 0 Empty > Successfully wrote the new partition table > > Re-reading the partition table ... > BLKRRPART: Device or resource busy > The command to re-read the partition table failed. > Run partprobe(8), kpartx(8) or reboot your system now, > before using mkfs > If you created or changed a DOS partition, /dev/foo7, say, then use dd(1) > to zero the first 512 bytes: dd if=/dev/zero of=/dev/foo7 bs=512 count=1 > (See fdisk(8).) > > > > root@arm:/tmp# lsblk > NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT > mmcblk1boot0 179:16 0 1M 1 disk > mmcblk1boot1 179:24 0 1M 1 disk > mmcblk0 179:0 0 1.9G 0 disk > |-mmcblk0p1 179:1 0 70.6M 0 part > `-mmcblk0p2 179:2 0 627.6M 0 part > mmcblk1 179:8 0 1.8G 0 disk > |-mmcblk1p1 179:9 0 64M 0 part /boot/uboot > `-mmcblk1p2 179:10 0 1.7G 0 part / > root@arm:/tmp# lsblk > NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT > mmcblk1boot0 179:16 0 1M 1 disk > mmcblk1boot1 179:24 0 1M 1 disk > mmcblk0 179:0 0 1.9G 0 disk > |-mmcblk0p1 179:1 0 70.6M 0 part > `-mmcblk0p2 179:2 0 627.6M 0 part > mmcblk1 179:8 0 1.8G 0 disk > |-mmcblk1p1 179:9 0 64M 0 part /boot/uboot > `-mmcblk1p2 179:10 0 1.7G 0 part / > root@arm:/tmp# > root@arm:/tmp# > root@arm:/tmp# lsblk > NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT > mmcblk1boot0 179:16 0 1M 1 disk > mmcblk1boot1 179:24 0 1M 1 disk > mmcblk0 179:0 0 1.9G 0 disk > |-mmcblk0p1 179:1 0 70.6M 0 part > `-mmcblk0p2 179:2 0 627.6M 0 part > mmcblk1 179:8 0 1.8G 0 disk > |-mmcblk1p1 179:9 0 64M 0 part /boot/uboot > `-mmcblk1p2 179:10 0 1.7G 0 part / > root@arm:/tmp# lsblk > NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT > mmcblk1boot0 179:16 0 1M 1 disk > mmcblk1boot1 179:24 0 1M 1 disk > mmcblk0 179:0 0 1.9G 0 disk > |-mmcblk0p1 179:1 0 70.6M 0 part > `-mmcblk0p2 179:2 0 627.6M 0 part > mmcblk1 179:8 0 1.8G 0 disk > |-mmcblk1p1 179:9 0 64M 0 part /boot/uboot > `-mmcblk1p2 179:10 0 1.7G 0 part / > root@arm:/tmp# > root@arm:/tmp# > root@arm:/tmp# > root@arm:/tmp# > > > > > root@arm:/tmp# ls /dev/mmcblk* > mmcblk0 mmcblk0p1 mmcblk0p2 mmcblk1 mmcblk1boot0 > mmcblk1boot1 mmcblk1p1 mmcblk1p2 > root@arm:/tmp# ./beaglebone-black-copy-eMMC-to-microSD.sh > + source=/dev/mmcblk1 > + destination=/dev/mmcblk0 > + check_running_system > + '[' '!' -f /boot/uboot/uEnv.txt ']' > + check_host_pkgs > + unset deb_pkgs > + dpkg -l > + grep dosfstools > + grep rsync > + dpkg -l > + grep u-boot-tools > + dpkg -l > + '[' '' ']' > + update_boot_files > ++ uname -r > + '[' '!' -f /boot/initrd.img-3.8.13-bone21 ']' > ++ uname -r > + update-initramfs -u -k 3.8.13-bone21 > update-initramfs: Generating /boot/initrd.img-3.8.13-bone21 > grep: /boot/config-3.8.13-bone21: No such file or directory > ++ uname -r > + '[' -f /boot/vmlinuz-3.8.13-bone21 ']' > ++ uname -r > + '[' -f /boot/initrd.img-3.8.13-bone21 ']' > ++ uname -r > + cp -v /boot/initrd.img-3.8.13-bone21 /boot/uboot/initrd.img > '/boot/initrd.img-3.8.13-bone21' -> '/boot/uboot/initrd.img' > ++ uname -r > + mkimage -A arm -O linux -T ramdisk -C none -a 0 -e 0 -n initramfs -d > /boot/initrd.img-3.8.13-bone21 /boot/uboot/uInitrd > Image Name: initramfs > Created: Sun Jun 30 03:09:51 2013 > Image Type: ARM Linux RAMDisk Image (uncompressed) > Data Size: 2709744 Bytes = 2646.23 kB = 2.58 MB > Load Address: 00000000 > Entry Point: 00000000 > + mount_n_check > + umount /dev/mmcblk0p1 > umount: /dev/mmcblk0p1: not mounted > + true > + umount /dev/mmcblk0p2 > umount: /dev/mmcblk0p2: not mounted > + true > + grep /dev/mmcblk0p1 > + lsblk > + repartition_emmc > + dd if=/dev/zero of=/dev/mmcblk0 bs=1M count=16 > 16+0 records in > 16+0 records out > 16777216 bytes (17 MB) copied, 0.0803752 s, 209 MB/s > + LC_ALL=C > + sfdisk --force --DOS --sectors 63 --heads 255 --unit M /dev/mmcblk0 > Checking that no-one is using this disk right now ... > BLKRRPART: Device or resource busy > > This disk is currently in use - repartitioning is probably a bad idea. > Umount all file systems, and swapoff all swap partitions on this disk. > Use the --no-reread flag to suppress this check. > > Disk /dev/mmcblk0: 60000 cylinders, 255 heads, 63 sectors/track > > sfdisk: ERROR: sector 3069308928 does not have an msdos signature > /dev/mmcblk0: unrecognized partition table type > Old situation: > No partitions found > New situation: > Units = mebibytes of 1048576 bytes, blocks of 1024 bytes, counting from 0 > > Device Boot Start End MiB #blocks Id System > /dev/mmcblk0p1 * 0+ 70- 71- 72261 e W95 FAT16 (LBA) > /dev/mmcblk0p2 70+ 1874- 1805- 1847475 83 Linux > /dev/mmcblk0p3 0 - 0 0 0 Empty > /dev/mmcblk0p4 0 - 0 0 0 Empty > > > > On Mon, Jun 24, 2013 at 10:06 AM, Ratin <rat...@gmail.com <javascript:>>wrote: > >> For some reason it had an "error write failed" , and would not let me >> login (during the time it was trying to do the copy to eMMC) so I couldnt >> tell if it succeeded or not. I will do some more digging. >> >> >> >> On Wed, Jun 19, 2013 at 1:23 PM, Robert Nelson >> <robert...@gmail.com<javascript:> >> > wrote: >> >>> On Tue, Jun 18, 2013 at 8:20 PM, Ratin <rat...@gmail.com <javascript:>> >>> wrote: >>> > Found this - but not sure if this will work for Ubuntu .. seems to be >>> for >>> > Angstrom >>> > >>> > >>> https://github.com/beagleboard/meta-beagleboard/blob/master/contrib/bone-flash-tool/emmc-prepare.sh >>> > >>> > I will try dd, but I guess I have to first zero out unused spaces with >>> "dd >>> > if=/dev/zero of=/0bits bs=20" >>> >>> Okay, just pushed a new script out: >>> >>> https://github.com/RobertCNelson/tools/blob/master/scripts/beaglebone-black-copy-eMMC-to-microSD.sh >>> >>> After unifying everything in the older one, the only difference >>> between the two scripts is, source & destination are reversed... >>> Still need to do a quick error check that the 'mmc' device actually >>> exists... but other wise it works.. >>> >>> Regards, >>> >>> -- >>> Robert Nelson >>> http://www.rcn-ee.com/ >>> >> >> > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.