Re: [beagleboard] flashing BBB with image made from /opt/scripts/tools/beag.... and getting kernel panic

413 views
Skip to first unread message
Message has been deleted

Robert Nelson

unread,
May 25, 2016, 8:49:55 PM5/25/16
to Beagle Board


On Wed, May 25, 2016 at 7:42 PM, Matt99eo <mattmahe...@gmail.com> wrote:
Trying to clone a Debian Jesse distro (4.1.21)
I made a uSD using the beaglebone-black-make-microSD-flasher-from-eMMC.sh

What am I missing here?

When I insert this into another BBB it crashes before flashing completion.  Here is what I see when a serial debug cable is connected:


Starting eMMC Flasher from microSD media
Version: [1.20160222: deal with v4.4.x+ back to old eeprom location...]
-----------------------------
Checking for Valid bbb-eeprom header
Valid bbb-eeprom header found [335]
-----------------------------
copying: [/dev/mmcblk0] -> [/dev/mmcblk1]
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  3.7G  0 disk
`-mmcblk0p1  179:1    0  3.7G  0 part /
mmcblk1      179:8    0  3.7G  0 disk
-----------------------------
df -h | grep rootfs:
-----------------------------
Erasing: /dev/mmcblk1
108+0 records in
108+0 records out
113246208 bytes (113 MB) copied, 16.1838 s, 7.0 MB/s
[   31.654940] random: nonblocking pool is initialized
108+0 records in
108+0 records out
113246208 bytes (113 MB) copied, 4.25127 s, 26.6 MB/s
Erasing: /dev/mmcblk1 complete
-----------------------------
Writing bootloader to [/dev/mmcblk1]
dd if= of=/dev/mmcblk1 count=1 seek=1 bs=128k

^^ that should have been:

dd if=/opt/backup/uboot/MLO of=/dev/mmcblk1.......

Which means the "beaglebone-black-make-microSD-flasher-from-eMMC.sh" script failed to get a network connect to grab a good bootloader:


Regards,

--
Robert Nelson
https://rcn-ee.com/

Aparna Velampudi

unread,
Mar 7, 2017, 12:30:36 PM3/7/17
to BeagleBoard
I used microSD flasher script and got this issue:



-----------------------------
Starting eMMC Flasher from microSD media
Version: [1.20151007: gpt partitions with raw boot...]
-----------------------------
Checking for Valid bbb-eeprom header
[   10.824227] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000200
[   10.824227]
[   10.833427] CPU: 0 PID: 1 Comm: init-eMMC-flash Not tainted 4.4.36-ti-r72 #1
[   10.840504] Hardware name: Generic AM33XX (Flattened Device Tree)
[   10.846669] [<c001acb8>] (unwind_backtrace) from [<c0015a14>] (show_stack+0x20/0x24)
[   10.854461] [<c0015a14>] (show_stack) from [<c05b9d38>] (dump_stack+0x9c/0xb0)
[   10.861730] [<c05b9d38>] (dump_stack) from [<c015d6d0>] (panic+0xfc/0x290)
[   10.868645] [<c015d6d0>] (panic) from [<c00472e0>] (do_exit+0xa68/0xa8c)
[   10.875379] [<c00472e0>] (do_exit) from [<c004739c>] (do_group_exit+0x4c/0xe0)
[   10.882636] [<c004739c>] (do_group_exit) from [<c0047450>] (__wake_up_parent+0x0/0x30)
[   10.890596] [<c0047450>] (__wake_up_parent) from [<c0010e60>] (ret_fast_syscall+0x0/0x44)
[   10.898822] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000200
[   10.898822]
[   22.270170] random: nonblocking pool is initialized

Robert Nelson

unread,
Mar 7, 2017, 12:35:45 PM3/7/17
to Beagle Board, Aparna Velampudi
On Tue, Mar 7, 2017 at 11:30 AM, Aparna Velampudi
<aparnav...@gmail.com> wrote:
> I used microSD flasher script and got this issue:
>
>
>
> -----------------------------
> Starting eMMC Flasher from microSD media
> Version: [1.20151007: gpt partitions with raw boot...]

version_message="1.20161216: more fixes..."

https://github.com/RobertCNelson/boot-scripts/blob/master/tools/eMMC/functions.sh#L8

only a little out of date..

run git pull on /opt/scripts/

Aparna Velampudi

unread,
Mar 7, 2017, 12:48:00 PM3/7/17
to BeagleBoard, aparnav...@gmail.com
just did that, but now when i'm trying to run that script:

/opt/scripts/tools/eMMC/beaglebone-black-make-microSD-flasher-from-eMMC.sh: line 27: syntax error near unexpected token `<<<'

Robert Nelson

unread,
Mar 7, 2017, 12:52:10 PM3/7/17
to Beagle Board, Aparna Velampudi
On Tue, Mar 7, 2017 at 11:47 AM, Aparna Velampudi
<aparnav...@gmail.com> wrote:
> just did that, but now when i'm trying to run that script:
>
> /opt/scripts/tools/eMMC/beaglebone-black-make-microSD-flasher-from-eMMC.sh:
> line 27: syntax error near unexpected token `<<<'

looks like local changes...

git reset HEAD --hard
git pull

Aparna Velampudi

unread,
Mar 7, 2017, 1:24:40 PM3/7/17
to BeagleBoard, aparnav...@gmail.com
after  i did that, some more issues:


Tearing Down script environment
==> Unmounting /tmp
umount: /tmp: not mounted
==> Stopping Cylon LEDs ...
==> Setting LEDs to
==> Force writeback of eMMC buffers by Syncing: /dev/mmcblk0
/opt/scripts/tools/eMMC/functions.sh: line 250: 32380 Terminated              cylon_leds
----------------------------------------
100000+0 records in
100000+0 records out
51200000 bytes (51 MB) copied, 2.87516 s, 17.8 MB/s
----------------------------------------
===> Syncing: /dev/mmcblk0 complete
==> This script took 106 seconds to run
================================================================================
==> Setting LEDs to

Robert Nelson

unread,
Mar 7, 2017, 1:35:25 PM3/7/17
to Beagle Board, Aparna Velampudi
On Tue, Mar 7, 2017 at 12:24 PM, Aparna Velampudi
<aparnav...@gmail.com> wrote:
> after i did that, some more issues:
>
>
> Tearing Down script environment
> ==> Unmounting /tmp
> umount: /tmp: not mounted
> ==> Stopping Cylon LEDs ...
> ==> Setting LEDs to
> ==> Force writeback of eMMC buffers by Syncing: /dev/mmcblk0
> /opt/scripts/tools/eMMC/functions.sh: line 250: 32380 Terminated
> cylon_leds
> ----------------------------------------
> 100000+0 records in
> 100000+0 records out
> 51200000 bytes (51 MB) copied, 2.87516 s, 17.8 MB/s
> ----------------------------------------
> ===> Syncing: /dev/mmcblk0 complete
> ==> This script took 106 seconds to run
> ================================================================================
> ==> Setting LEDs to

that means it's done..

Aparna Velampudi

unread,
Mar 7, 2017, 2:26:07 PM3/7/17
to BeagleBoard, aparnav...@gmail.com
but after i tried to flash it on to another beaglebone, i got the following:

Begin: Loading essential drivers ... done.
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
Begin: Will now check  file system ... fsck from util-linux 2.25.2
Checking all file systems.
done.
Usage: mount [-r] [-w] [-o options] [-t type] [-f] [-i] [-n] device directory
done.
Target filesystem doesn't have requested /opt/scripts/tools/eMMC/init-eMMC-flasher-v3.sh.
Begin: Running /scripts/local-bottom ... done.
Begin: Running /scripts/init-bottom ... mount: No such file or directory
done.
Could not copy file: No such file or directory
No init found. Try passing init= bootarg.

Robert Nelson

unread,
Mar 7, 2017, 2:46:51 PM3/7/17
to Beagle Board, Aparna Velampudi
On Tue, Mar 7, 2017 at 1:26 PM, Aparna Velampudi
<aparnav...@gmail.com> wrote:
> but after i tried to flash it on to another beaglebone, i got the following:
>
> Begin: Loading essential drivers ... done.
> Begin: Running /scripts/init-premount ... done.
> Begin: Mounting root file system ... Begin: Running /scripts/local-top ...
> done.
> Begin: Running /scripts/local-premount ... done.
> Begin: Will now check file system ... fsck from util-linux 2.25.2
> Checking all file systems.
> done.
> Usage: mount [-r] [-w] [-o options] [-t type] [-f] [-i] [-n] device
> directory
> done.
> Target filesystem doesn't have requested
> /opt/scripts/tools/eMMC/init-eMMC-flasher-v3.sh.
> Begin: Running /scripts/local-bottom ... done.
> Begin: Running /scripts/init-bottom ... mount: No such file or directory
> done.
> Could not copy file: No such file or directory
> No init found. Try passing init= bootarg.

looks like a bug, copy the full serial boot log to

pastebin.com

Aparna Velampudi

unread,
Mar 7, 2017, 2:50:37 PM3/7/17
to BeagleBoard, aparnav...@gmail.com

Aparna Velampudi

unread,
Mar 7, 2017, 4:04:07 PM3/7/17
to BeagleBoard, aparnav...@gmail.com
I tried creating an image two more times but i've been getting the same error/issue

Aparna Velampudi

unread,
Mar 8, 2017, 3:40:08 PM3/8/17
to BeagleBoard, aparnav...@gmail.com
so, while I'm able to create an SD card image for my build, when I try to flash another beaglebone by holding down the user button, the error occurs (as explained above). However, with one version of the SD card image, while the SD card is loaded and booted, I'm able to run  /opt/scripts/tools/eMMC/init-eMMC-flasher-v3.sh and the eMMC flashes. I think there's a bug somewhere while trying to execute that file. It's odd because I ran the beaglebone-black-eMMC-SD-card-flasher code to create another SD card image, and I wasn't able to boot from SD card.
Reply all
Reply to author
Forward
0 new messages