Problem with SD card corruption on Dreamcatcher

Got my new Dreamcatcher up and running and works fine until I do an ‘apt-get upgrade’ - I consistently get scsi errors and the card gets corrupted during the installation portion of the upgrade, when its pretty disk-heavy. Its a new Sandisk EVO 32gb, power is from 2 USB3 ports of my laptop (one into each of the micro-USB connectors) which should max at 1.5-1.6a total, onlu WiFi adapter plugged in, so I don’t think power is the issue. Are there any general suggestions for which make/model/speed/capacity SD card to use for the Armbian OS to avoid this? Also welcome any ‘X card works for me during apt-get upgrade’ or any other suggestions. I’ll be testing another known good card this evening as well as a 2a adapter.

I got mine today; but have not powered up yet. I believe that only one of the micro USB ports will accept power for the dreamcatcher. The other port, labeled “OTG” is I think for an on-the-go connection to a cell phone for example. I don’t think the dreamcatcher will take power from that port.

Taking all that into account, and that you are powering from a laptop, I think it is possible you are under powering the dreamcatcher. My guess is that your 2amp adapter will clean this problem up. I asked for “official” guidance on the power requirements in another thread. I didn’t want to power up without knowing the dreamcatcher’s power demands.

Definitely keep us posted. As more of us receive the dreamcatchers, we will all be going thru the same or similar learning curve. We should talk it out to help the documentation get better.

Both take power, they’re bridged. You can test by only plugging in your laptop to the OTG port, it will power and run fine off a single USB port from either of my laptops, one is USB2 and the other USB3 - until I try to upgrade. :slight_smile: Don’t be shy about it, its just a small ARM computer like a RaspberryPi, power that thing up! Worst case you corrupt your card and you have to re-write the IMG file to it.

yeah good point :slight_smile: usb_pwr and usb_otg are connected paralel from 5V line point of view, can use any of them to power the board. However only usb_otg has the usb data connection

Am I right first you issued “sudo apt update” and then “sudo apt upgrade” ?

Powering from laptop a bit risky… can you give it a try from a proper (1.5…2A) adapter?
You can use rufus to format and scan your sdcard for errors.

We have seen a few issues when the sd card image got corrupted but that usually happens when there is no proper shut down event (suggestion: short press of the power button initialize shut down event just like a normal PC would do)

a side note…dont use the quick format, I had a few issues that way… i fix my issue by (full erase) the sd card before you flash the img. i use on windows 10. SD_FORMAT prog. . Just my 2 cents

Q? Per your suggestion. Is the short press to shutdown available on the dreamcatcher now? I have been issuing sudo poweroff.

Correct, apt update && apt upgrade - downloads everything fine but ext4 errors during the install of perl-base, always on perl-base for some reason, and perl-base isn’t the first update to get installed either, its like the 3rd or so. I’ll give the adapter a shot. I have an inline USB volt/ammeter and the voltage never drops below 5.00 and the ext4 errors happen when the amps hit 0.61. USB3 should be rated at 800ma though. Now this SD card won’t even show up in my laptop, so maybe the card was just bad from the outset and is really toast now. I’ll do more testing and update the thread when I have time. Thanks all!

2a USB battery got me further but still got ext4 errors during the upgrade. Voltage went as low as 4.89 and amps as high as 0.65 throughout the upgrade.

Preparing to unpack …/initramfs-tools_0.120+deb8u3_all.deb …
Unpacking initramfs-tools (0.120+deb8u3) over (0.120+deb8u2) …
[ 1308.094054] EXT4-fs (mmcblk0p1): Delayed block allocation failed for inode 3979 at logical offset 0 with max blocks 3 with error 5
[ 1308.105907] EXT4-fs (mmcblk0p1): This should not happen!! Data will be lost
[ 1308.105907]
dpkg: unrecoverable fatal error, aborting:
unable to fsync updated status of `man-db’: Input/output error
E: Sub-process /usr/bin/dpkg returned an error code (2)

Next test will be a full format of the card with the 2a brick (did a quick format last time to only change one thing at a time to know which helped/didn’t).

I powered up my dreamcatcher today. I used a 5V/5amp power supply that I have for my drone. After futzing with the wireless for a while, I was able to apt update and apt upgrade. I’m using a 4gb g.skill micro sd card.

So far, I’m not seeing any power issues. But I will probably use a 5V/2amp supply once I find one.

@Syed, what can you tell us about the expected rating of the solar panel? I’m wondering what the Lantern nominal voltage and amp rating will be. I’m guessing the target is 5V/1.5a? Would there be a battery involved to achieve that? Just curious what we should expect, power supply wise, out of the solar panels.

Can you do another apt update && apt upgrade && shutdown -r now? I got through the first, rebooted, but then ran a second and after a reboot, it got stuck at a boot type prompt. Wondering if anyone else might have the same issue after doing another update.

which SD card slot are you using?

usually I run “poweroff” command, or as said more comfortable short pressing once the power button.

did you used the same SD card or changed to an other now?

Only ever used the OS slot so far. That samsung evo 32gb wouldn’t work, i managed to get it upgraded after a few scsi errors and fsck’s. I have since switched to another card that upgraded fine with no issues at all. But same issue, after completing the upgrade and issuing a shutdown -r now (which does go through the shutdown procedure) it will not boot anymore. I’m stuck with this output:

Found U-Boot script /boot/boot.scr
3550 bytes read in 221 ms (15.6 KiB/s)

Executing script at 43100000

U-boot loaded from SD
Boot script loaded from mmc
128 bytes read in 190 ms (0 Bytes/s)
4307052 bytes read in 632 ms (6.5 MiB/s)
6278160 bytes read in 685 ms (8.7 MiB/s)
Found mainline kernel configuration
** File not found /boot/dtb/sun5i-a13-dreamcatcher.dtb **
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
No FDT memory address configured. Please configure
the FDT address via "fdt addr " command.
Aborting!
** File not found /boot/dtb/overlay/-fixup.scr **

Loading init Ramdisk from Legacy Image at 43300000 …

Image Name: uInitrd
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 4306988 Bytes = 4.1 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum … OK
ERROR: Did not find a cmdline Flattened Device Tree
Could not find a valid device tree
SCRIPT FAILED: continuing…
MMC: no card present
mmc_init: -123, time 2
starting USB…
USB0: USB EHCI 1.00
USB1: USB OHCI 1.0
scanning bus 0 for devices… 1 USB Device(s) found
scanning usb for storage devices… 0 Storage Device(s) found

USB device 0: unknown device
No ethernet found.
missing environment variable: pxeuuid
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default-arm-sunxi
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default-arm
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default
No ethernet found.
Config file not found
No ethernet found.
No ethernet found.
=>

Is the problem a result of upgrading to Armbian 5.30? My dreamcatcher failed to boot as well after the u-boot and kernel update.

its not you i think its 5.30 is jacked up… alot of people talking about that update that None can do ssh. ect…
try another version of it and see if that will help.

Ya, let me see what I can do here.

OK, first problem: ** File not found /boot/dtb/sun5i-a13-dreamcatcher.dtb **

Copy this file out of the img file w/Linux: (Fix the paths for your system and mountpoints)
sudo mount -o loop,offset=1048576 Armbian_5.27_Dreamcatcher_Debian_jessie_next_4.10.14_20170602.img mnt/
sudo cp -P mnt/boot/dtb/sun5i-a13-dreamcatcher.dtb /media/username/b47d4bd8-beaf-463c-baf8-b9d65f754be3/boot/dtb/

After doing that, I get further in the boot process but seems something else is up with the kernel itself? Can’t dig further right now, dinner time. :slight_smile:

U-Boot SPL 2017.03-armbian (May 07 2017 - 22:36:09)
DRAM: 512 MiB
CPU: 1008000000Hz, AXI/AHB/APB: 3/2/2
Trying to boot from MMC1

U-Boot 2017.03-armbian (May 07 2017 - 22:36:09 +0000) Allwinner Technology

CPU: Allwinner A13 (SUN5I)
Model: Outernet A13-dreamcatcher
I2C: ready
DRAM: 512 MiB
MMC: SUNXI SD/MMC: 0, SUNXI SD/MMC: 1
*** Warning - bad CRC, using default environment

In: serial@01c28400
Out: serial@01c28400
Err: serial@01c28400

U-Boot 2017.03-armbian (May 07 2017 - 22:36:09 +0000) Allwinner Technology

CPU: Allwinner A13 (SUN5I)
Model: Outernet A13-dreamcatcher
I2C: ready
DRAM: 512 MiB
MMC: SUNXI SD/MMC: 0, SUNXI SD/MMC: 1
*** Warning - bad CRC, using default environment

In: serial@01c28400
Out: serial@01c28400
Err: serial@01c28400
Net: No ethernet found.
Hit any key to stop autoboot: 0
38518 bytes read in 153 ms (245.1 KiB/s)
Unknown command ‘bmp’ - try 'help’
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1…
Found U-Boot script /boot/boot.scr
3550 bytes read in 221 ms (15.6 KiB/s)

Executing script at 43100000

U-boot loaded from SD
Boot script loaded from mmc
128 bytes read in 190 ms (0 Bytes/s)
4307052 bytes read in 633 ms (6.5 MiB/s)
6278160 bytes read in 686 ms (8.7 MiB/s)
Found mainline kernel configuration
23262 bytes read in 867 ms (25.4 KiB/s)
** File not found /boot/dtb/overlay/-fixup.scr **

Loading init Ramdisk from Legacy Image at 43300000 …

Image Name: uInitrd
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 4306988 Bytes = 4.1 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum … OK

Flattened Device Tree blob at 43000000

Booting using the fdt blob at 0x43000000
Loading Ramdisk to 49be4000, end 49fff82c … OK
reserving fdt memory region: addr=43000000 size=6000
Loading Device Tree to 49bdb000, end 49be3fff … OK

Starting kernel …

OK, skip that copy of the dtb file, use the shotgun approach instead and rename boot on your sd card and copy the boot folder out of the img file. Mine boots again, only failure during startup was:
[FAILED] Failed to start Load Kernel Modules.
See ‘systemctl status systemd-modules-load.service’ for details.
This means no wlan0 and probably other things as well.

Next step, need to downgrade the kernel packages from 5.30 to 5.27, but I can’t find them anywhere, I can only find 5.26… Can anyone help? Once I have the .deb files, I would copy to the sdcard, boot back up and install them, thus downgrading. I thought I could find them here: http://apt.armbian.com/pool/main/l/ but there’s no folder for linux-4.10.14-sunxi… I need:
linux-dtb-next-sunxi_5.27_armhf.deb
linux-firmware-image-next-sunxi_5.27_armhf.deb
linux-headers-next-sunxi_5.27_armhf.deb
linux-image-next-sunxi_5.27_armhf.deb

Maybe its easier to start over and lock these packages so they don’t get upgraded but allowing everything else to upgrade…dunno, open to suggestions. Figures this 5.30 update just came out today when I got this thing working finally… :slight_smile:

Hmm. This kind of brings up a good point. For a system that we want to be pretty stable, relying on non-Outernet controlled software updates could be a concern.

Perhaps a goal for the mid to long term is to customize the apt sources for the “Outernet armbian image”. Something to make sure that updates are pulled from an Outernet controlled repository, to try to ensure stability after OS updates. An alternative might be Outernet decide to disable updates altogether, and just release updated Outernet images every so often. Put the configuration and data on the “data” SD card, and plan for the OS SD card to be reimaged every so often. I tend to thing the first option is a little better.