Author Topic: May Have Bricked 3100  (Read 10952 times)

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« on: September 07, 2005, 06:01:01 am »
I'm not sure exactly whch forum to post this in as the problem I am having is not exaclty OpenBSD specific, however it did happen when I tried to install OpenBSD.

Well, I think I may have just partially bricked my new C3100.  I tried installing OpenBSD and accidentally said yes to using the whole disk for OpenBSD, then exited FDISK without making any changes, and rebooted to retry.  Now, it refuses to boot.  I'm thinking there should be a way to recover from this, as all I've lost is simply hard drive data.  I can get into the diag menu and tried re-flashing the backup of the NAND ROM provided by Tri-Soft on their website, but unsurprisingly, no dice.  I would imagine one way to recover would be to simply get a hard drive image, put it on a CF card and try restoring that from the diag menu and starting all over again.

However, this does make me wonder just exactly how the 3100 boots.  The 3000 does not have enough flash to hold the OS, and would have to have critical pieces of the OS in hard drive.  However, I would imagine that the 3100 would be similar to the 1000, in that most of the OS(at least the important parts and booting bits) would be in the flash and only extras such as applications and data would be on the hard drive.  This is obviously false, or else I'd still have a working Zaurus.  If anyone has detailed information as to how the 3100 boots up, I would love to hear it.  As well, how much seperation between flash and hard drive is there?  And why can't we just put a tiny version of OpenBSD in a flash image and use that to jumpstart the OS?  Otherwise(to my understanding anyway) the 128MB flash rom would remain original and OpenBSD would only have access to the hard drive.

Thanks for any input/advice.

koen

  • Hero Member
  • *****
  • Posts: 1008
    • View Profile
    • http://dominion.thruhere.net/koen/cms/
May Have Bricked 3100
« Reply #1 on: September 07, 2005, 06:15:16 am »
Note that is virtually impossible to brick a PXA based zaurus, since they all have an emergency ROM (a real ROM) chip which can restore data.
Forums are not bugtrackers!!! Smart questions
Ångström release team
iPAQ h2210, iPAQ h5550, iPAQ hx4700, Zaurus SL-C700, Nokia 770, all running some form of GPE
My blog

barryg

  • Jr. Member
  • **
  • Posts: 60
    • View Profile
    • http://web.kssp.upd.edu.ph/barry/zaurus/
May Have Bricked 3100
« Reply #2 on: September 07, 2005, 07:19:23 am »
Good Day!

Quote
I would imagine one way to recover would be to simply get a hard drive
image, put it on a CF card and try restoring that from the diag menu and
starting all over again.
This is covered in INSTALL.zaurus[0], and this posts[1].


Quote
However, this does make me wonder just exactly how the 3100 boots.

        <SNIP>
The primary boot loader (ctl d+b) is loaded from rom, which then boots
Linux from flash.

If zbsdmod.o is loaded, boot loader loads it which in turn boots up
OpenBSD.  You can boot to Linux by entering reboot on the boot> prompt.
This has been sufficiently documented in INSTALL.zaurus[0].


Quote
And why can't we just put a tiny version of OpenBSD in a flash
image and use that to jumpstart the OS?  Otherwise(to my understanding
anyway) the 128MB flash rom would remain original and OpenBSD would only
have access to the hard drive.

There is no BSD licensed flash file system, hence OpenBSD using Linux to
boot.

Quote
Thanks for any input/advice.


Instructions are already in INSTALL.zaurus[0], do go over them.
And you did not provide sufficient info to diagnose your
problem (fdisk,disklabel and dmesg)

Mabuhay! barryg

[0]
ftp://ftp.openbsd.org/pub/OpenBSD/snapsho.../INSTALL.zaurus

[1]
https://www.oesf.org/forums/index.php?showtopic=14586
https://www.oesf.org/forums/index.php?showtopic=14765

--
Barry Dexter A. Gonzaga, bofh

obscurite

  • Full Member
  • ***
  • Posts: 125
    • View Profile
May Have Bricked 3100
« Reply #3 on: September 07, 2005, 10:19:17 am »
barryg is correct of course, all of this is in the INSTALL.zaurus - although when I got stuck it took me about 4 hours to realize it.

This is a repeat of what's in INSTALL.zaurus, but it might help anyway:
You can always get back to single user mode in the ROM based linux by removing the battery and power for a while, and then holding b + d while you plut it in and turn it back on (then log in as root). Once there, you can insmod zbsdmod.o and cp bsd.rd /proc/zboot. This will immediately send you into the OpenBSD installer.

Let us know how it goes!
C3100, 5500, former C860 owner

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #4 on: September 07, 2005, 04:47:12 pm »
Hmm, well, I did read through INSTALL.zaurus[0] but couldn't find information that made sense for my situation, I'll keep reading it and try to figure it out.

At the moment, there is no information from fdisk, disklabel or dmesg, as I don't get that far, when I tried reboot at the bootloader prompt, I just got HDD errors.

Now, after re-flashing NAND, I get an HDD1 error during the first Sharp boot-up screen. "HDD1 Error!!"

However, if there is a way to load the openbsd installer from single user mode, then I'm gonna keep playing and see if I can do it that way.

Thanks for verifying the info is in the INSTALL.zaurus[0], at least if a solution exists I can stop worrying.

barryg

  • Jr. Member
  • **
  • Posts: 60
    • View Profile
    • http://web.kssp.upd.edu.ph/barry/zaurus/
May Have Bricked 3100
« Reply #5 on: September 07, 2005, 08:45:58 pm »
Good Day!

Quote
Hmm, well, I did read through INSTALL.zaurus[0] but couldn't find
information that made sense for my situation, I'll keep reading it and
try to figure it out.
INSTALL.zaurus, line 753.


Quote
Now, after re-flashing NAND, I get an HDD1 error during the first Sharp
boot-up screen. "HDD1 Error!!"
Not needed, should have read through posts I linked earlier.

Quote
However, if there is a way to load the openbsd installer from single
user mode, then I'm gonna keep playing and see if I can do it that way.
Also on the thread i linked earlier, do go over them again.  

Quote
Thanks for verifying the info is in the INSTALL.zaurus[0], at least if a
solution exists I can stop worrying.


Mabuhay! barryg


--
Barry Dexter A. Gonzaga, bofh

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #6 on: September 07, 2005, 09:29:42 pm »
Well, the insmod trick did work.  However, it took me a while to figure out exactly what to do and how to do it.

I've put the whole OpenBSD distro on my CF card, booted into single user mode using the B+D key combination.

Then I went to my CF card and used:
# insmod zbsdmod.o
# cp bsd.rd /proc/zboot

Which got me back to the install script, now to start over again

Thanks for pointing me in the right direction, for some reason I couldn't find that info in the install instructions when I looked.  Although I've never done much with a system like the Zaurus, I have installed OpenBSD for X86 many times, but of course, things are much easier when you can boot off of a CD or floppy.

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #7 on: September 08, 2005, 06:19:17 am »
Well, I've managed to get myself into another problem that I can't find a way out of.  After successfully installing the OpenBSD sets, I am now unable to boot into OpenBSD.  However, this is not because of a conflict with the SD or CF slots, or anything similar.  I think my major mistake was to NAND flash the Zaurus after quitting the OpenBSD install the first time.

From what I've been able to gather, the .ipk that comes with the OpenBSD sets writes to the NAND flash installing a bootloader.  However, since I re-flashed the NAND, there is no more bootloader and I can't launch the installed OpenBSD.  I have been able to boot to single user mode, and did successfully install OpenBSD that way, but I am unable to find a way to even launch the installation that way.  When I go into single use mode, it sees the hdc4 as 1 openbsd partition but since it cannot see the slices, it won't let me use zboot from there(not that I'm even sure it would work, but gave it a shot anyway.)

I have tried the rc.rofilesys trick, but it hasn't helped, is this because of a lack of bootloader?  I'm thinking that one way to solve my problem, would be to simply grab a NAND flash backup from someone that already has OpenBSD installed on their C3100.  Would this work?  Or, is there perhaps a way to install the bootloader from either the single user linux, or from the OpenBSD installer?  I've considered just re-running ipkg, but I can't seem to locate it anywhere on the single user linux I have.

BTW, for posting fdisk, disklabel and dmesg info, is there an easier way to do it than manually typing them all out on another computer?

Again, thanks in advance for any tips that could help me out.

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #8 on: September 08, 2005, 06:21:33 am »
Oh, wait... I could probably just use > to output the info from those three to the CF card, then move the CF card to another computer.  I'll do that right away and post the info messages.

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #9 on: September 08, 2005, 06:46:28 am »
Here is my DMESG output:

OpenBSD 3.8 (RAMDISK) #87: Fri Sep  2 15:06:54 MDT 2005
deraadt@zaurus.openbsd.org:/usr/src/sys/arch/zaurus/compile/RAMDISK
real mem  = 67108864 (65536K)
avail mem = 52101120 (50880K)
using 844 buffers containing 3457024 bytes (3376K) of memory
mainbus0 (root)
cpu0 at mainbus0: PXA27x rev 4 (XScale core)
cpu0: DC enabled IC enabled WB enabled LABT branch prediction enabled
cpu0: 32KB(32b/l,32way) I-cache, 32KB(32b/l,32way) wr-back-lock D-cache
pxaip0 at mainbus0: CPU clock = 415.997 MHz
pxaintc0 at pxaip0 addr 0x40d00000: Interrupt Controller
pxagpio0 at pxaip0 addr 0x40e00000: GPIO Controller
saost0 at pxaip0 addr 0x40a00000
saost0: SA-11x0 OS Timer
com0 at pxaip0 addr 0x40100000 intr 22: pxa2x0, 32 byte fifo
com1 at pxaip0 addr 0x40200000 intr 21: pxa2x0, 32 byte fifo
com2 at pxaip0 addr 0x40700000 intr 20: pxa2x0, 32 byte fifo (SIR)
pxaudc0 at pxaip0: USB Device Controller
ohci0 at pxaip0, version 1.0
usb0 at ohci0: USB revision 1.0
uhub0 at usb0
uhub0: PXA27x OHCI root hub, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
lcd_pxaip0 at pxaip0
wsdisplay0 at lcd_pxaip0 mux 1: console (std, vt100 emulation)
zkbd0 at pxaip0
wskbd0 at zkbd0: console keyboard, using wsdisplay0
scoop0 at pxaip0: PCMCIA/GPIO controller
scoop1 at pxaip0: PCMCIA/GPIO controller
pxapcic0 at pxaip0: 2 slots
pcmcia0 at pxapcic0
pcmcia1 at pxapcic0
zssp0 at pxaip0
apm0 at pxaip0
zts0 at pxaip0
wsmouse0 at zts0 mux 0
clock: hz=100 stathz=64
rd0: fixed, 5120 blocks
wdc0 at pcmcia0 function 0 "HITACHI, microdrive" port 0x0/16: irq 138
wd0 at wdc0 channel 0 drive 0: <HMS360604D5CF00>
wd0: 32-sector PIO, LBA, 3906MB, 7999488 sectors
wd0(wdc0:0:0): using BIOS timings
wdc1 at pcmcia1 function 0 "SanDisk, SDP, 5/3 0.6" port 0x0/16: irq 137
wd1 at wdc1 channel 0 drive 0: <SanDisk SDCFB-1024>
wd1: 4-sector PIO, LBA, 977MB, 2001888 sectors
wd1(wdc1:0:0): using BIOS timings
boot_file: '(null)'
rootdev=0x1200 rrootdev=0x1200 rawdev=0x1202
WARNING: using filesystem date -- CHECK AND RESET THE DATE!
wd1: no disk label

Here is my disklabel output:

# /dev/rwd0c:
type: ESDI

disk: ESDI/IDE disk
label: HMS360604D5CF00
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 16
sectors/cylinder: 1008
cylinders: 7936
total sectors: 7999488
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0      # microseconds
track-to-track seek: 0   # microseconds
drivedata: 0

16 partitions:
#             size        offset  fstype [fsize bsize  cpg]
a:        102753            63  4.2BSD   2048 16384  102 # Cyl     0*-   101
b:        196560        102816    swap                   # Cyl   102 -   296
c:       7999488             0  unused      0     0      # Cyl     0 -  7935
d:        788256        299376  4.2BSD   2048 16384  328 # Cyl   297 -  1078
e:       2097648       1087632  4.2BSD   2048 16384  328 # Cyl  1079 -  3159
f:        512064       3185280  4.2BSD   2048 16384  328 # Cyl  3160 -  3667
g:       4302144       3697344  4.2BSD   2048 16384  328 # Cyl  3668 -  7935

And finally, here is the output from my fdisk:

Disk: wd0   geometry: 7936/16/63 [7999488 Sectors]
Offset: 0   Signature: 0xAA55
         Starting       Ending       LBA Info:
 #: id    C   H  S -    C   H  S [       start:      size   ]
------------------------------------------------------------------------
 0: 00    0   0  0 -    0   0  0 [           0:           0 ] unused      
 1: 00    0   0  0 -    0   0  0 [           0:           0 ] unused      
 2: 00    0   0  0 -    0   0  0 [           0:           0 ] unused      
*3: A6    0   1  1 - 7935  15 63 [          63:     7999425 ] OpenBSD

barryg

  • Jr. Member
  • **
  • Posts: 60
    • View Profile
    • http://web.kssp.upd.edu.ph/barry/zaurus/
May Have Bricked 3100
« Reply #10 on: September 10, 2005, 09:36:32 pm »
Good Day!

Thanks for dmesg, fdisk and disklabel.

The fdisk and disklabel shows no obvious mistake.

1) Can you get to the boot> prompt?
2) If you can do:
        boot> bsd
3) If you cant get to the boot prompt do the
        b+d boot trick
        # insmod zbsdmod.o
        # cp bsd /proc/zboot

NOTE: I don't have a 3100 and have not verified this.  Do provide feed
back on your install.

Sorry for the delay, had to recover my hdd as I inadvertently removed my
zaurus' partition table. And played with my shiny new wi with kismet
;).

Mabuhay! barryg

--
Barry Dexter A. Gonzaga, bofh

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #11 on: September 11, 2005, 07:58:32 am »
Well, after flashing the NAND with the Tri Soft image, I can longer get to the "boot>" prompt.

I have already done #3:
 the b+d boot trick
# insmod zbsdmod.o
# cp bsd /proc/zboot
and have completely installed OpenBSD to the hard drive.

My problem now is that I can't seem to figure out a way to actually load the installed OpenBSD because the single user linux doesn't seem to recognise the OpenBSD partition in a way that will let me mount and boot manually.  I'm thinking my problem is as I stated before, that I should not have NAND flashed the rom.  Although, I'm hoping there's a quicker/easier solution.

- Renzo

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #12 on: September 12, 2005, 05:22:03 am »
Hmmm... After reading through this again, I suppose I should be more clear.  The only solution that I can see is to grab a NAND backup from someone that has a C3100 and OpenBSD currently installed.  As my Z won't even attempt to boot anything except the single user mode in the flash rom.

barryg

  • Jr. Member
  • **
  • Posts: 60
    • View Profile
    • http://web.kssp.upd.edu.ph/barry/zaurus/
May Have Bricked 3100
« Reply #13 on: September 13, 2005, 03:39:34 am »
Good Day!

Quote
Hmmm... After reading through this again, I suppose I should be more clear.
The only solution that I can see is to grab a NAND backup from someone that has
a C3100 and OpenBSD currently installed.  As my Z won't even attempt to boot
anything except the single user mode in the flash rom.
[div align=\"right\"][{POST_SNAPBACK}][/a][/div]
Before suggesting a more "involved" procedure.

Follow the procedures mentioned in line 862 and  904 of the INSTALL.zaurus[0].
After which you can reboot your zaurus, you should be able boot to linux then.
There install openbsd38_arm.ipk



Mabuhay! barryg

[0]
[a href=\"ftp://ftp.openbsd.org/pub/OpenBSD/snapshots/zaurus/INSTALL.zaurus]ftp://ftp.openbsd.org/pub/OpenBSD/snapsho.../INSTALL.zaurus[/url]
--
Barry Dexter A. Gonzaga, bofh
« Last Edit: September 13, 2005, 03:40:48 am by barryg »

Shaka

  • Newbie
  • *
  • Posts: 19
    • View Profile
May Have Bricked 3100
« Reply #14 on: September 13, 2005, 09:04:31 am »
After trying both of the procedures, I still get the same error message on boot up: "HDD1 Error!!"