Welcome! Log In Create A New Profile

Advanced

Pogoplug E02 upgrading U-boot. Bad block detected.

Posted by hachigo 
Pogoplug E02 upgrading U-boot. Bad block detected.
October 15, 2014 11:28PM
Hi,

I was reading the guide on how to update the uBoot for Pogoplug E02. And I've detected bad block.

1. What should I do?
2. Also is it safe to upgrade the uBoot from Archlinux on usb or do I need to unplug all usbs?


[root@alarm ~]# dmesg | grep -i 'bad'
[    7.269250] Scanning device for bad blocks
[    7.301153] Bad eraseblock 366 at 0x000002dc0000
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 12:46AM
hachigo Wrote:
-------------------------------------------------------
> Hi,
>
> I was reading the guide on how to update the uBoot
> for Pogoplug E02. And I've detected bad block.
>
> 1. What should I do?
> 2. Also is it safe to upgrade the uBoot from
> Archlinux on usb or do I need to unplug all usbs?
>
>
>
> [root@alarm ~]# dmesg | grep -i 'bad'
> [    7.269250] Scanning device for bad blocks
> [    7.301153] Bad eraseblock 366 at
> 0x000002dc0000
>

1. This bad block is way out in other areas in NAND (the address is 0x000002dc0000). mtd0 is the 1st 1M.
2. Install u-boot from Arch USB.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 12:56AM
I've made it all the way through the guide. I think It has installed, I'm not entirely sure.

Netconsole setup isn't working, I followed the directions on Jeff's guide. I'm booting directly into the Archlinux usb. The pogoplug just blinks orange without the USB plugged in, is this normal behavior? The pogoplug would boot before without a USB plugged in and I could ssh into it, this time I can't.
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 01:20AM
hachigo Wrote:
-------------------------------------------------------
> I've made it all the way through the guide. I
> think It has installed, I'm not entirely sure.
>
> Netconsole setup isn't working, I followed the
> directions on Jeff's guide. I'm booting directly
> into the Archlinux usb. The pogoplug just blinks
> orange without the USB plugged in, is this normal
> behavior? The pogoplug would boot before without a
> USB plugged in and I could ssh into it, this time
> I can't.

It is best that you post the log of your installation if not sure.

Normal. Without USB it will try to boot into Pogo OS. With USB it will boot into Debian.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 01:31AM
Here is the screen output (I'm not sure where the logs are kept).

[root@alarm ~]# flash_erase /dev/mtd0 0 4
Erasing 128 Kibyte @ 60000 -- 100 % complete 
[root@alarm ~]# nandwrite /dev/mtd0 uboot.2014.07-tld-1.pogo_e02.mtd0.kwb 
Writing data to block 0 at offset 0x0
Writing data to block 1 at offset 0x20000
Writing data to block 2 at offset 0x40000
Writing data to block 3 at offset 0x60000

Here is my fw_env.config

# MTD device name	Device offset	Env. size	Flash sector size	Number of sectors
/dev/mtd0		0xc0000		0x20000		0x20000

And here is output for fw_printenv. I changed the arcNumber back to 3542 from 2097. I still don't get the netconsole uBoot banner though.

[root@alarm ~]# fw_printenv 
ethact=egiga0
bootdelay=3
baudrate=115200
mainlineLinux=yes
console=ttyS0,115200
led_init=green blinking
led_exit=green off
led_error=orange blinking
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
mtdids=nand0=orion_nand
partition=nand0,2
stdin=serial
stdout=serial
stderr=serial
rescue_installed=0
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs ro rootfstype=ubifs $mtdparts $rescue_custom_params
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; nand read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
force_rescue=0
force_rescue_bootcmd=if test $force_rescue -eq 1 || ext2load usb 0:1 0x1700000 /rescueme 1 || fatload usb 0:1 0x1700000 /rescueme.txt 1; then run rescue_bootcmd; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && ubifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; fi
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if test $usb_scan_done -eq 0 && ext2load usb $usb 0x800000 /boot/uImage 1; then usb_scan_done=1; echo "Found bootable drive on usb $usb"; setenv usb_device $usb; setenv usb_root /dev/$dev; fi; done
usb_scan_list=1 2 3 4
usb_scan_1=usb=0:1 dev=sda1
usb_scan_2=usb=1:1 dev=sdb1
usb_scan_3=usb=2:1 dev=sdc1
usb_scan_4=usb=3:1 dev=sdd1
usb_init=run usb_scan
usb_device=0:1
usb_root=/dev/sda1
usb_rootdelay=10
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
bootcmd=usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd; usb stop; run rescue_bootcmd; run pogo_bootcmd; reset
ethaddr= [ "deleted" ]
usb_rootfstype=ext3
machid=dd6
arcNumber=3542
serverip=192.168.1.98
ipaddr=192.168.1.95
if_netconsole=ping $serverip
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
preboot=run if_netconsole start_netconsole

Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 02:46AM
What do you use for netconsole server? another Linux box or Windows/Mac? does the server "see" the Pogo E02 (can ping it). And once you booted into Arch on Pogo E02, can you ping the netconsole server box?

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 16, 2014 03:00AM
I thought it was necessary in case I break something as per the instructions.

10. Set up netconsole. It's important to set up neconsole if you don't already have serial console connected.

I'm trying to learn as much Linux as I can with this pogoplug and I'm more than likely going to breaking somethings as I go.

As for the netconsole, it turns out I skipped installing the default boot environments because I thought it was already default (I just recently put Arch on it.) I finally got netconsole working after installing the default boot environments.

Thank you for your help. Really appreciate it.
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 18, 2014 10:26PM
hachigo,

> I thought it was necessary in case I break
> something as per the instructions.
>
> I'm trying to learn as much Linux as I can with
> this pogoplug and I'm more than likely going to
> breaking somethings as I go.
>

Something got lost in the translation :)) By

Quote

What do you use for netconsole server

I meant what program do you run for netconsole server (Windows, Mac, Linux nc, netcat, bsdnetcat, ...)! not what purpose do you use netconsole for :))

I thought it's funny how the proposition "for " put in the wrong place would have a totally different meaning :)

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
October 23, 2014 06:40AM
Oh lol. Sorry I misunderstood. I am using linux. I can't seem to get it to work for mac or windows.

As a side note, my usb doesn't boot anymore after installing the default environment image. Hopefully I can fix the env parameters with netconsole when I get some free time. I saw another thread where the user had the same problem, so hopefully I can fix it using information there before my TTL usb cable comes.

Thanks for your help again.
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
February 01, 2015 01:56PM
Hi again.

I just bought a second pogo e02. I am trying to install the newest update uboot again and wanted to make sure my bad eraseblock is not within the first 1M of my NAND. Here is my output from dmesg.

[root@alarm ~]# dmesg | grep -i 'bad'
[    3.137387] Scanning device for bad blocks
[    3.157177] Bad eraseblock 206 at 0x0000019c0000
[    3.169361] Bad eraseblock 306 at 0x000002640000
[    3.177605] Bad eraseblock 354 at 0x000002c40000
[    3.185098] Bad eraseblock 392 at 0x000003100000
[    3.236921] Bad eraseblock 1015 at 0x000007ee0000


Also how do I interpret this information for future reference? Can you tell me at least what to google, I'm not sure how to make it a specific question google understands.. It gives me a bunch of search results about fixing a bad eraseblock and the like.

Thank you.
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
February 01, 2015 02:10PM
hachigo,

The info can be found in my thread about how to backup and restore NAND (it's in my signature):
http://forum.doozan.com/read.php?3,16789,16789#msg-16789

Specific explanation:

NAND block is 128K, so the 1st 1M of NAND contains block 0 to block 7. You bad block starts at 206, therefore they are way out of 1M.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
February 01, 2015 02:11PM
If you convert 19c0000 hex into decimal you get 27000832 or roughly 27M
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
February 01, 2015 02:18PM
Thank you all. I had no idea. I am really just starting to delve into this computer stuff coming from a bioscience background, it's a bit of a learning curve.
Re: Pogoplug E02 upgrading U-boot. Bad block detected.
February 01, 2015 02:22PM
hachigo Wrote:
-------------------------------------------------------
> Thank you all. I had no idea. I am really just
> starting to delve into this computer stuff coming
> from a bioscience background, it's a bit of a
> learning curve.

Cool! have you heard of neural networks? would be cool to play with it on these plugs :) (the low power cost of these plugs would make it ideal to try)

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: