Posted by
duanev on
Jan 29, 2017; 9:34am
URL: https://itus.accessinnov.com/Current-state-of-Sheild-recovery-knowledge-tp1249p1352.html
Ho! Some success! I managed to get ymodem to work and upload both u-boot-octeon_rhino_itus7x.bin and then ItusrestoreImage (described at the end of this post). The restore images runs for a while but the watchdog timer triggers a hard reset after a few tens of seconds of "inactivity". If I don't punch the enter key while the restore image is booting I get this:
...
[ 4664.532058] em_nbyte: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4664.532103] em_text: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4664.532144] em_u32: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4664.532193] ifb: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTE^M
*** NMI Watchdog interrupt on Core 0x00 ***^M
$0 0x0000000000000000 at 0x0000000014009ce0^M
v0 0x0000000000000001 v1 0x00000000000003e8^M
...
(reset)
which is about 500 lines of complaints about version mismatches, and then a watchdog interrupt. I'm using the May 21, 2015 uboot but I don't know how to use the octboot2.bin roadrunner42 speaks of ...
I next tried the 'octwd stop' command prior to booting (which did nothing - something turns the watchdog back on while the kernel is starting), and then pressing the enter key every few seconds during boot - which gave me a shell prompt:
...
[ 4105.408093] Freeing unused kernel memory: 32136K (ffffffff8089e000 - ffffffff82800000)^M
[ 4107.488274] init: Console is alive^M
[ 4107.503942] init: - watchdog -^M
[ 4108.519650] init: - preinit -^M
Press the [f] key and hit [enter] to enter failsafe mode^M
Press the [1], [2], [3] or [4] key and hit [enter] to select the debug level^M
[ 4108.594160] mmc0: Skipping voltage switch^M
[ 4108.640250] mmc0: host does not support reading read-only switch. assuming write-enable.^M
[ 4108.662273] mmc0: new high speed SDHC card at address 59b4^M
[ 4108.680711] mmcblk0: mmc0:59b4 USD00 30.0 GiB ^M
[ 4108.698393] mmcblk0: p1^M
^M
^M
[ 4110.681366] procd: - early -^M
[ 4110.696562] procd: - watchdog -^M
[ 4111.388193] procd: - ubus -^M
[ 4112.403957] procd: - init -^M
Please press Enter to activate this console.^M
^M
^M
^M
BusyBox v1.23.2 (2015-08-19 20:18:50 PDT) built-in shell (ash)^M
^M
=========================================================================^M
| ___ _____ _ _ ____ _ _ _ _ |^M
| |_ _|_ _| | | / ___| | \ | | ___| |___ _____ _ __| | _____ |^M
| | | | | | | | \___ \ | \| |/ _ \ __\ \ /\ / / _ \| '__| |/ / __| |^M
| | | | | | |_| |___) | | |\ | __/ |_ \ V V / (_) | | | <\__ \ |^M
| |___| |_| \___/|____/ |_| \_|\___|\__| \_/\_/ \___/|_| |_|\_\___/ |^M
| ____ _ _ ___ _____ _ ____ ,-~~-.___. |^M
| / ___|| | | |_ _| ____| | | _ \ / | ' \ |^M
| \___ \| |_| || || _| | | | | | | ( ) 0 |^M
| ___) | _ || || |___| |___| |_| | \_/-, ,----' |^M
| |____/|_| |_|___|_____|_____|____/ ==== // |^M
| v1.0 / \-'~; /~~~(O) |^M
| / __/~| / | |^M
| Powered by OpenWrt -==( _____| (_________| |^M
=========================================================================^M
^M
^M
-^M
root@?:/# [ 4114.157680] arc4: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4114.181807] af_alg: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4114.205456] arc4: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
^M
root@?:/# [ 4114.229405] af_alg: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4114.253653] arc4: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
[ 4114.277083] af_alg: version magic '3.10.20-rt14 SMP mod_unload OCTEON 64BIT ' should be '3.10.20 SMP mod_unload OCTEON 64BIT '^M
...
and when the complaints stopped I was able to run a few commands ... until the system spontaneously reboots:
...
root@Shield:/# df^M
Filesystem 1K-blocks Used Available Use% Mounted on^M
tmpfs 499396 48 499348 0% /tmp^M
tmpfs 512 0 512 0% /dev^M
/dev/mmcblk0p1 31460352 32 31460320 0% /overlay^M
root@Shield:/# [ 4279.584354] br-lan: port 1(eth1) entered disabled state^M
[ 4279.601891] br-lan: port 2(eth2) entered disabled state^M
[ 4279.640582] device eth1 left promiscuous mode^M
[ 4279.657100] br-lan: port 1(eth1) entered disabled state^M
[ 4279.675522] device eth2 left promiscuous mode^M
[ 4279.692031] br-lan: port 2(eth2) entered disabled state^M
[ 4279.751412] reboot: Restarting system^M
^M
OCTEON eMMC stage 1 bootloader^M
^M
Partition: 1, start: 0x0000000000000800, size: 0x0000000000200001^M
OCTBOOT2BIN not found^M
...
This seems to be due to the update script which is supposed to run in the restore image, and of course reboot when it is done. But nothing gets restored... so I'm going to have to figure out how to kill the script so I can fix some things manually. If I connect the eth0 port to my network I can ping out from the Shield until the reboot, but curl fails with this:
curl: error while loading shared libraries: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory
which is quite surprising - if the restore script depends on curl I would expect all the dependent shared libs to be in the restore image.
Ymodem
So to get ymodem to work with screen, first cd to the directory with the Shield binary images and then run screen and use ctrl-a followed by ':' when the loady command begins to send 'C' characters:
# screen /dev/ttyUSB0 115200
(boot Shield)
Octeon sff7000# setenv loadaddr 0x400000
Octeon sff7000# loady
Press ctrl-a and ':' and then type 'exec !! sz -Y u-boot-octeon_rhino_itus7x.bin'. ymodem should commence in a few seconds and give you a running block transfer count... and finally:
Sending:
Ymodem sectors/kbytes sent: 0/ 0k
Transfer complete
Modem - CRC mode, 8(SOH)/1111(STX)/0(CAN) packets, 6 retries
## Total Size = 0x00115ef0 = 1138416 Bytes
Octeon sff7000#
Then type:
Octeon sff7000# go 0x00400000
to execute uboot (stage 3). Once the stage 3 boot stops, repeat this process for the ItusrestoreImage downloaded from dropbox (mentioned in other threads on this forum - search for its md5sum df253dc31c8001337a537d59dcd5996d ):
Octeon cust_private_rhino_itus7x(ram)# setenv loadaddr 0x400000
Octeon cust_private_rhino_itus7x(ram)# loady
ctrl-a:exec !! sz -Y ItusrestoreImage
(wait 61 minutes! lol)
Octeon cust_private_rhino_itus7x(ram)# octwd stop ??
Octeon cust_private_rhino_itus7x(ram)# bootoctlinux 0x400000 numcores=2 mem=0
press enter several times to activate console during boot ...
Wish I knew all the command line options that bootoctlinux accepts, they might be kernel command line args ...