Welcome! Log In Create A New Profile

Advanced

Altered Uboot env, PPV4, need to revert to initial env

Posted by t3ch42 
Altered Uboot env, PPV4, need to revert to initial env
April 10, 2013 10:07AM
Hi, with the help of bodhi and shv, I was able to get my pogoplug series 4 to flash the custom uboot. I was unable to boot with a second usb drive plugged in and attempted to change some of the usb_boot env and usb_root settings in uboot.

I was hoping that someone might be able to help identify what command I would need to revert my env back to normal. I've tried, but I don't think that I am chaining them together right. Every time I make a change, it seems to get worse.

Follows is my printenv listing.
rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params

Environment size: 2966/131068 bytes
Pogov4> printenv
printenv

arcNumber=3960
baudrate=115200
bootargs=console=ttyS0,115200 root=/dev/sda1 rootdelay=10 rootfstype=ext2 mtdpar
ts=orion_nand:2M(u-boot),3M(uImage),3M(uImage2),8M(failsafe),112M(root)
bootcmd=usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd;
 usb stop; run mmc_bootcmd
bootdelay=10
console=ttyS0,115200
ethact=egiga0
ethaddr=02:50:43:5c:3f:bd
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
if_netconsole=ping $serverip
ipaddr=192.168.1.99
led_error=orange blinking
led_exit=green off
led_init=green blinking
machid=F78
mainlineLinux=yes
mmc_bootcmd=mmc init; mmc init;ext2load mmc 0:1 0x00800000 /boot/uImage; if ext2
load mmc 0:1 0x01100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm
 0x800000; fi
mtddevname=uImage2
mtddevnum=2
mtdids=nand0=orion_nand
mtdparts=mtdparts=orion_nand:2M(u-boot),3M(uImage),3M(uImage2),8M(failsafe),112M
(root)
ncip=192.168.1.252
partition=nand0,2
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
preboot=run if_netconsole start_netconsole
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; na
nd read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
rescue_installed=0
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs
ro rootfstype=ubifs $mtdparts $rescue_custom_params
serverip=192.168.1.252
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; se
tenv stdout nc; setenv stderr nc; version;
stderr=nc
stdin=nc
stdout=nc
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && u
bifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm
0x800000 0x1100000; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0
:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext
2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; el
se bootm 0x800000; fi
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_device=0:1
usb_init=run usb_scan
usb_root=/dev/sda1
usb_rootdelay=10
usb_rootfstype=ext2
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if t
est $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; se
tenv usb_root /dev/$dev; fi; done
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_scan_list=1 2 3 4
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_
rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params

Environment size: 2966/131068 bytes
Pogov4>
My other exploits were listed here

here is my boot log.
U-Boot 2011.12 (Apr 08 2012 - 19:03:41)
Cloud Engines-Pogoplug v4/Mobile:MMC version
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 2 USB Device(s) found
       scanning bus for storage devices... 1 Storage Device(s) found
Loading file "/rescueme" from usb device 0:1 (usbda1)
** File not found /rescueme
reading /rescueme.txt

** Unable to read "/rescueme.txt" from usb 0:1 **
incorrect device type in data
Partition data not found!
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
1 bytes read
Found bootable drive on usb 0:1
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
2185768 bytes read
Loading file "/boot/uInitrd" from usb device 0:1 (usbda1)
6938844 bytes read
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-3.3.2-kirkwood-shv
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2185704 Bytes = 2.1 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-3.3.2-kirkwood-shv
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    6938780 Bytes = 6.6 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK
Using machid 0xf78 from environment

Starting kernel ...

edit...I edited my post as I had not had a successful boot after last night, but tried again today from a different computer and was successful.



Edited 1 time(s). Last edit at 04/10/2013 10:10AM by t3ch42.
Re: Altered Uboot env, PPV4, need to revert to initial env
April 10, 2013 09:58PM
In response to my own question, I proceeded as if I hadn't updated the uboot. I booted into debian, placed the flashing tools and kwb file in my tmp directory and went through the initial setup.

Maybe not the cleanest, but it erased the mistakes I made.

Just need to do a little more research into uboot I think.
Re: Altered Uboot env, PPV4, need to revert to initial env
April 11, 2013 12:02AM
@t3ch42,

You're probably looking for this:
http://forum.doozan.com/read.php?3,8044,8152#msg-8152

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Altered Uboot env, PPV4, need to revert to initial env
April 11, 2013 05:29PM
Thanks! That worked. Now to get the other hard drives to boot in order and consistently and I'll be happy.

Will do more research into that aspect as well.

Thanks again,
T3ch42
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: