Topic: Restore to original, Part 2: Bigger, Longer, and Uncut

Okay.  I've been trying to use the ROM (found here: http://forum.chumby.com/viewtopic.php?pid=31177#p31177) to write an image to a larger microSD card, so that I have room for Zurk's firmware *on* the card, and can put some music on it, too.

I want the OS partition to be 500 MB or a gig, and have the rest more or less in /mnt/storage.

I've been trying to use the instructions here:
http://wiki.ladyada.net/chumbyhackerboard/microsd

But any time I do any of the post-dd ladyada instructions, the infocast (testing with it before the two chumbies) won't boot at all.  No power, nothing.

If I just dd the image to it, and then stick it in the infocast, then it fixes the partitions by itself, then reboots and all is happy.

Except that...I have two primary partitions that seem to have identical copies of the OS (having removed the chip again to try to repartition it larger) and both have almost no extra space on them, certainly not enough to copy zurkware to it.  All the rest of the space is /mnt/storage/ and hey, I can put music there...but it doesn't help me convert to offline firmware.

I did try putting the various directories there and creating a symlink on the OS partition, but it didn't work.

Having gotten the microSD card to where it will run the infocast--by letting the infocast do it--I've stuck it back in my desktop. 

My desktop auto-mounts it as:
/dev/sdb2 -- 150 MB, operating system, 111.9 MB used
/dev/sdb3 -- 150 MB, operating system, 111.9 MB used
/dev/sdb4 -- extended partition containing /dev/sdb5
/dev/sdb5 -- 128 MB partition, 17.1 MB used
...it doesn't even see the rest of the 8 gigs as a partition.

Gparted reads it as 7.4 GB unallocated.

ARGH.  How do I make this thing reshuffle its partitions so there is more room?  Why can't ladyada's instructions work?  The infocast won't even *try* to boot if I follow her instructions.  Why does it seem to have two copies of the OS on two partitions?  Why can't gparted give me larger partitions?  Why isn't this WORKING?

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

What I did was dd copy the original sd to an image file, then dd the image file to a larger capacity card.  Afterwards, I performed a factory reset to expand the partition size automatically.

To expand the size of the partition after imaging to larger memory card, perform a factory reset. 
Take an original SD card, and dd its entire contents over to the new, larger SD card.

When powering up the Chumby for the first time with the new SD card, follow these instructions to restore factory settings:
http://www.chumby.com/help/faq/11/471

This will erase any settings that previously existed, but it will recreate the partitions associated with /psp and /mnt/storage, expanding /mnt/storage to the full size allowed by the larger SD card.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

I think galadriel wants to expand /dev/sdb2 and /dev/sdb3, not /mnt/storage...

galadriel wrote:

I want the OS partition to be 500 MB or a gig, and have the rest more or less in /mnt/storage.

galadriel wrote:

Except that...I have two primary partitions that seem to have identical copies of the OS (having removed the chip again to try to repartition it larger) and both have almost no extra space on them, certainly not enough to copy zurkware to it.  All the rest of the space is /mnt/storage/ and hey, I can put music there...but it doesn't help me convert to offline firmware.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

Here is what I've done.  Get http://files.chumby.com/firmware/infoca … ng.img.zip  Write it to a microSD with Winimage or dd it.

The first partition is the boot partition.  DO NOT TOUCH!

The second is the root file system.  I think this is what you want to expand.

The third is the back up root file.  I think this is used to over write the second during a factory install.

When you insert this into the SD slot and power up, it will create a fourth partition, which is /mnt/storage and expand it to fit the card.

If you want to expand the second partition you can us Gparted on a Linux machine.

First shrink the fourth partition

then move the third partition over to make room to ...

expand the second partition to take up the rest of the space.

This takes quite a while the bigger your SD card is.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

mwalimu: did you extend the second OS (backup) partition as well, or leave that factory-size?

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

No, I did not.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

Yes.  I'm trying to expand sdb2 so that I can fit zurkware on it.  If I didn't want to do that, it'd be fine with the adjustments a chumby automatically makes to the partitions when you insert a card with the shiny new image.

Okay, here's all the things I've tried so far:

1) dd the image to the microSD card.  Repartition with gparted so sdb2 is 600 MB (moving everything else to the right), then put in infocast.  No boot at all.

2) dd the image to the microSD card.  Change the partitions very slightly with gparted (put 500 MB unallocated between sdb3 and the extended partition sdb4), put in infocast, let infocast make /mnt/storage etc, then use gparted to move that unallocated 500 MB into sdb2.  Infocast gets stuck in a loop at "detecting networks, enter password, initializing, detecting networks."

3) dd the image to the microSD card.  Put it straight in the infocast and let the infocast do its thing.  Put it back in the desktop and try gparted...which sees it all as unallocated space, no partitions to adjust.

Which is to say, YES, I'm using gparted; I'm shrinking the last partition--in various ways, whether while it's still unallocated space or whether it's already been made into a sdb6 inside the extended partition sdb4--and it is NOT WORKING.

What do I need to do to make this actually work?  Neither adjusting it before OR after sticking it in the infocast is giving me something that will repartition nicely.


...I don't suppose there's an image out there with larger partitions, is there?

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

Try getting the falconwing-rom.img and dd that onto you SD card from your linux box.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

Aaaaand when I say I start by dd-ing "the ROM", (and then later put it in the infocast) what does that mean to you?

10 (edited by mwalimu 2012-06-02 07:41:26)

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

galadriel wrote:

Aaaaand when I say I start by dd-ing "the ROM", (and then later put it in the infocast) what does that mean to you?

I am guilty of what I am always complaining about - assuming that you speak linux.

-get   http://files.chumby.com/firmware/infoca … ng.img.zip

-extract it

-dd is the command to copy directly to disk in Linux.  So the command is:

    dd if=rom-falconwing.img of=/dev/sdX   bs=64M  (sdX is the drive that your SD card is on 64M would be the size of the blocks that your computer will read into memory before writing to disk)

Please look up this command before you use it as it can mess up your computer if you mix up "if" (input file) with "of"(output file).

If you use a Windows box, you can use Winimage, which is far simpler and less dangerous to your computer.

The result of all this is a rom image that you can put into the SD slot on your Chumby (Infocast) that will boot up and can be resized.

I've been resizing chumby images for a while and it's not difficult.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

And when I say I have been doing all of that, why do you keep telling me to do it?

I am not bothered that you are assuming I speak linux. 

I am bothered that you see me say that I am doing X, and assume for some reason that I have been doing Y.  I have no idea what this Y could be, by the way, hence my question.  What DO you think I have been doing?

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

What I think galadriel is saying, is that he was already using dd to load the falconwing ROM (from the website) onto the SD card.  He has then tried using gparted to move the third/fourth partitions over and expand the second.  And yet he is still having trouble.

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

Actually, "she".

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

my apologies!  i don't know why the name didn't click as feminine in my head tongue

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

@ Galadriel, if/when you get this figured out would you be able to share some detailed instructions? I picked up an 8GB microSD card that I was thinking of doing the same sort of thing but haven't had a chance yet. Slightly off topic, haven't had a chance to install that toolchain yet so no updates on the MPD stuff but when I do I'll let you know!

Re: Restore to original, Part 2: Bigger, Longer, and Uncut

JPH, I handed it off to my network engineer spouse and asked him to please just find time to make it happen.  It took him all weekend and he says he may be able to find time to note down what he did, but he may not even remember it all.  But.  He did finally wrestle the partitions into submission.

Yeah.

All right.  All right.  Well.

So you guys have all kept telling me that there's lots of room on a chumby, and there ought to be plenty of room for zurkware.  But I keep hitting "No space left on device" errors when I'd try to copy everything over (well, v9 worked fine, but not since then).

I thought I kept running into "No space left on device" errors because I had some of the chumbies that were shipped with the 1 gig micro SD cards.  "df" was telling me there was space, but I was getting persistent "No space left on device" errors when I'd try to copy it ALL over.  Okay, okay, I didn't know how else to approach it, I tried just sticking larger microSD cards in there.

And my husband finally managed to force the 8 gig microSD card into larger partitions at the beginning.  We started with a fresh ROM and wrestled the partitions larger and started entirely from scratch with a shiny new ROM and everything.  I am still getting "No space left on device" errors when I try to copy zurkware over to the chumby.

Okay.  It looks like the whole OS, except /psp/, is mounted on /dev/root/.  But, as it turns out, /psp/ is mounted on the first partition within the extended partition, partition 5.

Here's the partitions:
~ ~ ~
1: boot
2: OS
3: copy of OS (?)

4: extended partition, contains 5 and 6

5: /psp/
6: /mnt/storage
~ ~ ~

...

and /psp/ comes with a hard limit of 256 files.

THIS is the "no space left on device" error that keeps getting me.  It's not actual lack of space--I *knew* it wasn't actual lack of space, but didn't know how else to approach it.  But after there are 256 files in /psp/ it simply refuses to put any more there, including symlinks.

Goooooood griiiiiief.

Okay, so tell me.  There's a whole /perl directory on / now.  Does the system really need the perl that's in zurkware psp?  Is there anything in psp that I can eliminate?

Or do we have to start over with this poor abused chip, reformat the thing, re-dd the ROM image, wrestle the partitions into place again, and somehow overcome this bizarre 256 file limit in partition 5?