Welcome! Log In Create A New Profile

Advanced

Accidently set arcNumber=, now wont boot.

Posted by linuxtechie 
Accidently set arcNumber=, now wont boot.
September 16, 2011 01:05AM
Folks,

I accidently (my kid was playing around, while I was looking around for the number, she apparently even managed to reboot the machine, me and my luck) managed to set arcnumber to nothing. Now its not able to boot. I have tried a reset as well, but guess thats also is not working.

Any help please.

+LT
Re: Accidently set arcNumber=, now wont boot.
September 16, 2011 10:42AM
You will have to correct this with a serial connection.
Re: Accidently set arcNumber=, now wont boot.
September 16, 2011 06:50PM
Just curious: The original *nix that comes with the Dockstar (and its associated devices) doesn't require an arcNumber. (Does it?) I wonder if you could put that kernel on a thumb drive and boot that up, at least far enough to log in and reset the arcNumber.

And, when you get it booting again, make sure you set up netconsole if you don't have to wire up the serial connection.
Re: Accidently set arcNumber=, now wont boot.
September 17, 2011 03:47AM
Got it back by attaching a serial cable, reverted to ever working 2097. I ended up using a generic usb cable as following:

cp210x: KQ-UBA WT048000317. Nope its not Prolific one.


I was wondering how do I go about installing netconsole? Is it already installed in my debian installation? FYI, I have the latest kernel.

Thanks again guys!

+LT

kraqh3d Wrote:
-------------------------------------------------------
> You will have to correct this with a serial
> connection.



Edited 1 time(s). Last edit at 09/17/2011 03:52AM by linuxtechie.
Re: Accidently set arcNumber=, now wont boot.
September 17, 2011 09:49AM
@restamp
Good catch. I never noticed that. I just checked blparam and arcNumber is definitely not in the old environment. I can't seem to mount the old uImage partition from nand though to get the file so I made a copy of /dev/mtd1 with dd. File reports it as a uImage. If I have time later tonight, I'll attempt to boot it with the standard debian uInitrd. If it boots, I'll whack the arcNumber variable and see what happens.

mtd1.img: u-boot legacy uImage, Linux-2.6.22.18, Linux/ARM, OS Kernel Image (Not compressed), 1976384 bytes, Mon Aug 31 19:31:05 2009, Load Address: 0x00008000, Entry Point: 0x00008000, Header CRC: 0xADD4F978, Data CRC: 0xB9030BC5
Re: Accidently set arcNumber=, now wont boot.
September 17, 2011 04:23PM
restamp Wrote:
-------------------------------------------------------
> Just curious: The original *nix that comes with
> the Dockstar (and its associated devices) doesn't
> require an arcNumber. (Does it?) I wonder if you
> could put that kernel on a thumb drive and boot
> that up, at least far enough to log in and reset
> the arcNumber.
>
> And, when you get it booting again, make sure you
> set up netconsole if you don't have to wire up the
> serial connection.

restamp, if this works, does that mean potentially we can restore the stock FW without needing the serial connection? I meant if UBoot is not too messed up?
Re: Accidently set arcNumber=, now wont boot.
September 17, 2011 11:55PM
@bodhi: Well, Jeff Doozan showed us how to replace the firmware on these Plug boxes using only the OS that was initially loaded on them (along with downloadable executables compiled to run on it), so if it is possible to craft an external device which boots into this environment, then yes, it follows that that setup could be used to restore the initial OS onto the device's internal NAND memory. But, the same could be said of virtually any OS that can be booted on the device. I was merely suggesting to linuxtechie that, since his problem was that his uBoot environment no longer had a valid arcNumber in it, that he might try booting a version of *nix that didn't require an arcNumber to boot.

(FWIW, I have avoided altering the OS on the NAND of my Plugs any more than is necessary to effect the uBoot upgrade and Debian download, choosing insted to retain what came with them. The default seems to be robust on boots and capable of allowing access to the uBoot and its environment, and if I need to deal with modifications to the OS I normally run on the Plugs -- say I get it into a state where it will no longer sanely boot -- I can always physically take it to a desktop machine and work on it there. YMMV.)
Re: Accidently set arcNumber=, now wont boot.
September 18, 2011 06:21PM
@restamp,

It would be nice to be able to "restore the initial OS onto the device's internal NAND memory" :-) I've always been wondering at the point where Jeff's UBoot is checking for the rescue system, can the original Pogoplug be restored using the attached USB device? pardon my ignorance here, perhaps it's not possible to do that in some instances?

U-Boot 2010.09 (Oct 23 2010 - 11:51:16)
Marvell-PinkPogo by Jeff Doozan
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 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 **
Re: Accidently set arcNumber=, now wont boot.
September 18, 2011 11:04PM
I am reasonably certain you could write something other than the rescue image to the NAND. I'm less certain you could actually succeed at booting the default uImage off of a thumb drive, as you'd probably get bitten by something along the lines of the default kernel not having the proper drivers built into it to interact with the root partition on the thumb drive. But, it would be an interesting experiment to try.
Re: Accidently set arcNumber=, now wont boot.
September 19, 2011 09:09AM
I didn't get around to trying to boot the standard Pogoplug uImage file via USB. I see two issues. The default root location is /dev/mtd2 (which is jffs2.) I was going to manual change the bootargs to load the kernel from USB, but point root to the standard location. I expect that to work. The trick will be getting that root partition to exist on USB.

I believe mtd3 is unused by Pogoplug, so it could be used to hold a small Linux OS who's purpose is solely to restore backups copies of mtd0 (uboot), mtd1 (uImage) and mtd2 (rootfs) stored on it. It's like 200MB, and those other three nand partitions are only 1, 4, and 32MB respectively.
Re: Accidently set arcNumber=, now wont boot.
September 25, 2011 07:23PM
restamp & kraqh3d,

I'm intrigued by the idea! Take it a step further, let' say I have a mipsel-based device with an older UBoot, and I want to run mipsel Debian on it (with rootfs on a USB stick). Is this doable? I understand that will be a lot of works, but it would a good learning experiment that I'm interested in.

bodhi
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
October 07, 2011 07:46PM
@kraqh3d:

Do you have a backup of original Dockstar firmware (partitions mtd0, mtd1, and mtd2)? If you have can you upload them and give us a link?
I am not able to boot to original OS even after removing the USB stick installed with Debian. I need the Pogoplug web service badly. So i want to flash the original firmware except uboot.

Many Thanks
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
October 10, 2011 08:52AM
Sorry I never got around to testing this. My Dockstar hosts all my media. I can't just take it off line to experiment as something is always playing via Xbmc. And I've not yet found an acceptable price on eBay for a second one. Yes I do have backup copies of those three mtd partitions. If you can boot an alternate OS, then you should be able to nandwrite the image back. Where could I upload the backup image of the rootfs?
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
October 11, 2011 01:08AM
Thanks for the response.

Can you upload to public file sharing websites like mediafire, etc. and post the link here?

Thanks in advance
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
October 13, 2011 08:59AM
Ranganadh!
I'm with you. I am surprised there is no where we can reinstall the dockstar nand back on dockstar. Jeff has recovery nand so obviously just substituting dockstar nand should work.
Even if you get his backup nand how can you get it to work?
If one of you guys were able to use the recovery nand type script and get dockstar nand back on , please post link or something.
I do have my backup of nands from my dockstars but without serial access dont' know how to load it back on dockstar.
I would need very clear cut instructions. or copy and paste .

thanks guys.
Re: Accidently set arcNumber=, now wont boot.
October 13, 2011 04:07PM
Assuming you have backups of the original mtd1 and mtd2 partitions, and can boot into an alternate linux environment (with the correct mtdparts parameter of course), I would expect you should be able to just write the backup copies back to those partitions. It should be nothing more than this:

flash_eraseall /dev/mtd1
nandwrite /dev/mtd1 mtd1.dd.bkup
flash_eraseall /dev/mtd2
nandwrite /dev/mtd2 mtd2.dd.bkup

(I have not tried this and take no responsibility if you brick your device!)
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
October 13, 2011 04:45PM
@rgtaa,

can you upload the files in this forum (if you have account) or any other place that you prefer and post the link here?

Thank you
Ranganadh
Re: Accidently set arcNumber=, now wont boot.
November 10, 2011 04:36AM
@restamp & kraqh3d,

Well, it is my turn :-) I've made the same mistake with the GoFlex Net (used but working perfectly). I've installed UBoot and booted with an old Dockstar Debian USB image (arch number 2097). Next, I set arc number to 3089 (bad move), and then was interrupted so did not start installation for the new Debian kernel immediately (I blame the wine!). Murphy's law holds true as the power went down later!!! and now the GoFlex box does not boot and I can no longer ssh into it.

I recalled reading restamp's suggestion about another *nix:
http://forum.doozan.com/read.php?4,5913,5916#msg-5916

and kraqh3d said:
http://forum.doozan.com/read.php?4,5913,5919#msg-5919

Instead of using serial cable, I'd like to try restamp's suggestion to use "The original *nix that comes with the Dockstar" to be able to log in and change arc number back. I think it would be a good exercise to do this.

Could you point me to where can I get that version?

Thanks,
bodhi
Re: Accidently set arcNumber=, now wont boot.
November 12, 2011 01:58PM
kraqh3d Wrote:
-------------------------------------------------------
> @restamp
> Good catch. I never noticed that. I just checked
> blparam and arcNumber is definitely not in the old
> environment. I can't seem to mount the old
> uImage partition from nand though to get the file
> so I made a copy of /dev/mtd1 with dd. File
> reports it as a uImage. If I have time later
> tonight, I'll attempt to boot it with the standard
> debian uInitrd. If it boots, I'll whack the
> arcNumber variable and see what happens.
>
> mtd1.img: u-boot legacy uImage, Linux-2.6.22.18,
> Linux/ARM, OS Kernel Image (Not compressed),
> 1976384 bytes, Mon Aug 31 19:31:05 2009, Load
> Address: 0x00008000, Entry Point: 0x00008000,
> Header CRC: 0xADD4F978, Data CRC: 0xB9030BC5

@kraqh3d,

I'd like to try this if you have not already done so! could you make the mtd1.img file available? (I'll pm you my email if you'd prefer).

Thanks very much,
bodhi
Author:

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: