Author Topic: New pdaXrom installer (to have just Root partition)  (Read 31248 times)

Ashley

  • Newbie
  • *
  • Posts: 46
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #90 on: July 30, 2004, 04:33:45 am »
You're welcomed!
c760 pdaXrom & zdebian (on SD)
256MB SD, 16MB CF, Prism 2.5 Wifi CF
Athlon XP
Debian sarge, Gentoo 1.4, RedHat 9, FreeBSD 5.1, xp

donspinelakemed

  • Newbie
  • *
  • Posts: 19
    • View Profile
    • http://www.pinelakemed.com/
New pdaXrom installer (to have just Root partition)
« Reply #91 on: July 31, 2004, 02:10:06 am »
Quote
First of all, you can use testing tool (mtdparts_test.tar.gz). Just decompress into your running rom and exec ./test/mtdtest.sh. Report any problem or success.

If testing is ok, you should be able to use modified installer. Follow the instructions from pdaxrom site to prepare your flash card. Before rebooting your z, put files from new installer to your root dir of your flash card (overwrite updater.sh). Reboot in maintenance mode, as told by pdaxrom. Patch mtdparts with 2n option "NAND Flash repartition: only Root". If you have a 750 you should also update maintenance kernel. Reboot in maintenance mode. Install new rom with option 1. Reboot. Voilà.


I finally tried to install this on my C700.  The testing tool reported "success."  When I tried to "NAND Flash repartition: only Root," I got an error message "Flash pattern NOT recognized.  Cannot patch flash."

What should I try next?

donspinelakemed

  • Newbie
  • *
  • Posts: 19
    • View Profile
    • http://www.pinelakemed.com/
New pdaXrom installer (to have just Root partition)
« Reply #92 on: July 31, 2004, 05:09:26 am »
Actually, I am not sure that the testing tool ran correctly.  If  I type "exec ./test/mtdtest.sh" at the console command line, the first line I get is :

:bad interpreter: No such file or directory

the next line is:

bash: /mnt/cf/test/mtdtest.sh: Success

Does anyone have any suggestions?

deniscallies

  • Jr. Member
  • **
  • Posts: 73
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #93 on: August 09, 2004, 03:43:29 pm »
Hello,

got the same problem on my c 700  
do i have to edit my updater.sh

or will it not work under c 700 ?

thanks,

Denis

Ashley

  • Newbie
  • *
  • Posts: 46
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #94 on: August 10, 2004, 02:35:37 pm »
Hi!, good summer!  

I don't know anything about this error message. Never happened with a non-700. All this stuff remains untested on 700, you seem to be the first ones  . Maybe bcut is not working properly. It is just used to compare (into a loop) mtdnand with mtdparts and mtdtweak files. You can compare them by any other app or even by hand (just 80 Bytes).

I don't know if c700 kernel command line is just offseted from other z or is not compatible with this tweak. I will be able to investigate if you send me your mtdnand file  

Ash.
c760 pdaXrom & zdebian (on SD)
256MB SD, 16MB CF, Prism 2.5 Wifi CF
Athlon XP
Debian sarge, Gentoo 1.4, RedHat 9, FreeBSD 5.1, xp

ikm

  • Full Member
  • ***
  • Posts: 172
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #95 on: August 12, 2004, 06:21:29 am »
Ashley, the other problem is that the C700 kernel probably needs to be patched and recompiled to work with 64Mb large jffs2 partitions. That could be easily done, the only problem is that I don't really know what exact kernel patches are applied by the pdaXrom developers to their kernels.

iamasmith

  • Hero Member
  • *****
  • Posts: 1248
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #96 on: August 12, 2004, 07:08:22 am »
Woah, I'm sure this has been thought of but I just want to query this and introduce a word of caution.

If you start the image installer process (using the OK button from a cold start) option 3 lets you format the 'User Partition'.

An (already installed) traditional ROM then has the job of re-populating this to a usable state - this is the traditional way of resetting one of these units to a virgin state.

Does anyone know what happens if you select this having repartitioned the NAND ? and what happens if this option can't find the User partition ?

It could possibly brick at worst case.

BTW: While we are at it I'm assuming that the Service Menus are in ROM and not FLASH but is this Japanese utility menu the same or does this class as a flash based bootloader ? If so then it would need patching to avoid the possibility of this issue.

You could argue that if you have gone to the effort of partitioning the flash like this then you are in an 'informed position' and wouldn't try this option. There again what happens if something 'breaks' that would be possible to fix in a service depot and you send it to some poor hapless dude whose first procedure is to wipe the user partition.

Hmm.. you may get back a brick and be charged for wasting time.

Wouldn't a safer option be to just make the initial root partition as small as possible, carry only the kernel, some minimal scripts and busybox that on an erase would set up the user partition as the real root. On a normal boot the root would pivot the root mount onto the user partition and remount itself in perhaps /boot ?.

This seems safer and keeps the partitioning scheme cool with the loader menus etc. It also means that you are still free to install almost everything including base stuff from IPK if your distro allows it.
« Last Edit: August 12, 2004, 07:33:39 am by iamasmith »
OpenBSD 4.2 -current on full 4Gb of SL-C3000
Microdrive replaced with 4Gb SanDisk Extreme III card

ikm

  • Full Member
  • ***
  • Posts: 172
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #97 on: August 12, 2004, 06:41:01 pm »
Quote
Woah, I'm sure this has been thought of but I just want to query this and introduce a word of caution.

If you start the image installer process (using the OK button from a cold start) option 3 lets you format the 'User Partition'.

An (already installed) traditional ROM then has the job of re-populating this to a usable state - this is the traditional way of resetting one of these units to a virgin state.

Does anyone know what happens if you select this having repartitioned the NAND ? and what happens if this option can't find the User partition ?

It could possibly brick at worst case.

I don't really think it would brick the device. It would possibly screw up while trying to perform the thing, but I highly doubt it would trash a reserved service/utility part of the flash.

Quote
BTW: While we are at it I'm assuming that the Service Menus are in ROM and not FLASH but is this Japanese utility menu the same or does this class as a flash based bootloader ? If so then it would need patching to avoid the possibility of this issue.

As far as I understand it, both service menus and the Japanese utility are in flash. You can erase them, you can patch them, you can do whatever you want with them. But there is always a possibility to bootstrap the device, as the very basic first-stage bootloader resides in ROM and has a built-in possibility to restore the flash. There is an instruction for doing that, the link on it was posted on this board quite a while ago, but I think it's possible to find it. Or maybe someone could post it here if he has it saved.

Quote
You could argue that if you have gone to the effort of partitioning the flash like this then you are in an 'informed position' and wouldn't try this option. There again what happens if something 'breaks' that would be possible to fix in a service depot and you send it to some poor hapless dude whose first procedure is to wipe the user partition.

Hmm.. you may get back a brick and be charged for wasting time.

Well, in the worst case scenario, a real brick can drop from the rooftops and brick you on a way to service ;) My point is that thinking about that is a bit over the top. And well, I guess someone with the experience of the lowest-level bootstraping could just try that out :)

Quote
Wouldn't a safer option be to just make the initial root partition as small as possible, carry only the kernel, some minimal scripts and busybox that on an erase would set up the user partition as the real root. On a normal boot the root would pivot the root mount onto the user partition and remount itself in perhaps /boot ?.

This seems safer and keeps the partitioning scheme cool with the loader menus etc. It also means that you are still free to install almost everything including base stuff from IPK if your distro allows it.

Well, in my opinion, while I think it would be a small tiny bit safer, it would not pay off a single megabyte of the precise flash space wasted. Just relax, there are much more pressing issues on the agenda to mediate about :)

Ashley

  • Newbie
  • *
  • Posts: 46
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #98 on: August 13, 2004, 12:41:21 pm »
Quote
Ashley, the other problem is that the C700 kernel probably needs to be patched and recompiled to work with 64Mb large jffs2 partitions. That could be easily done, the only problem is that I don't really know what exact kernel patches are applied by the pdaXrom developers to their kernels.

You are right. And it may not be as simple as the trick used with 750s (using the 760 kernel). Recompilation may be needed. The worse is I don't own a 700, so I can't play this game. Any volunteer?  

Quote
As far as I understand it, both service menus and the Japanese utility are in flash. You can erase them, you can patch them, you can do whatever you want with them. But there is always a possibility to bootstrap the device, as the very basic first-stage bootloader resides in ROM and has a built-in possibility to restore the flash. There is an instruction for doing that, the link on it was posted on this board quite a while ago, but I think it's possible to find it. Or maybe someone could post it here if he has it saved.
http://pocketworkstation.org/files/recover/

Of course I agree with you, ikm. Nice post , as usual

iamasmith, I wrote a simple partition restoration to the origianl root+user scheme in the installer, so you always have the choice to go back by rebooting again into the installer. So don't worry so much. Installer was written months ago, and I don't know how many people has tried it, but no complaint received, only congratulations... and fears
c760 pdaXrom & zdebian (on SD)
256MB SD, 16MB CF, Prism 2.5 Wifi CF
Athlon XP
Debian sarge, Gentoo 1.4, RedHat 9, FreeBSD 5.1, xp

iamasmith

  • Hero Member
  • *****
  • Posts: 1248
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #99 on: August 13, 2004, 06:36:45 pm »
OK, paranoia kicking in I guess.

I wouldn't design a system that you couldn't restore even if all the flash was gone so I guess why should Sharp.

I have, however, worked in 'the industry' a long time and have learned to be cautious - this helps to prevent those 'cold sweat' moments that people end up with.

Good info on the reflash stuff, thanks. Not so encouraging that the 860 archive is marked 'probably_not_working' though  guess which unit I've got...

Anyway, thanks for the response. It sets my mind at rest a little on this one.
OpenBSD 4.2 -current on full 4Gb of SL-C3000
Microdrive replaced with 4Gb SanDisk Extreme III card

ikm

  • Full Member
  • ***
  • Posts: 172
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #100 on: August 13, 2004, 06:57:50 pm »
Quote
Quote
Ashley, the other problem is that the C700 kernel probably needs to be patched and recompiled to work with 64Mb large jffs2 partitions. That could be easily done, the only problem is that I don't really know what exact kernel patches are applied by the pdaXrom developers to their kernels.

You are right. And it may not be as simple as the trick used with 750s (using the 760 kernel). Recompilation may be needed. The worse is I don't own a 700, so I can't play this game. Any volunteer?  

I could handle the fix and recompilation, but I would need the precise pdaXrom kernel patch they apply, and their .config file. The result would most probably work without any testing at all, but only if both the patch and the .config are right.
Quote
Quote
As far as I understand it, both service menus and the Japanese utility are in flash. You can erase them, you can patch them, you can do whatever you want with them. But there is always a possibility to bootstrap the device, as the very basic first-stage bootloader resides in ROM and has a built-in possibility to restore the flash. There is an instruction for doing that, the link on it was posted on this board quite a while ago, but I think it's possible to find it. Or maybe someone could post it here if he has it saved.
http://pocketworkstation.org/files/recover/

Of course I agree with you, ikm. Nice post , as usual

Thanks

jerrybme

  • Hero Member
  • *****
  • Posts: 639
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #101 on: August 20, 2004, 01:00:37 pm »
Well, I'm getting some interesting results trying to modify my 750 to have a singe root partition. I've got RC2 successfully flashed with 45 mg  on mtdblock2 and 12mg on mtdblock3 (/home).

When I try and reflash with Ashley's "new-installer-fix" I got this error
Code: [Select]
flash pattern not recognized  I got this error before and after using the update maintance kernel (I restored it after it didn't resolve error)

Next I rebooted back into pdaXrom and tried the mtdtest script and got the error
Code: [Select]
open flash:No such file or directory and the rest of the script fails.

So in looking at the script I see that LOGOCAL_MTD=/dev/mtd1 However in looking at /dev/ there is no mtd1, only mtd. So I modified script to LOGOCAL_MTD=/dev/mtd and then ran it with the following error
Code: [Select]
GETMEMINFO: Inappropriate ioctl for device
Since the script fails there is no mtdnand file to examine.

Any ideas Ashley?

Thanks,
Jerry
SL-C3100
Angstrom-GPE
Lexar SD 1 GB
PQI 2GB CF
Ambicom WL1100 CF

ikm

  • Full Member
  • ***
  • Posts: 172
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #102 on: August 20, 2004, 04:59:00 pm »
Quote
So in looking at the script I see that LOGOCAL_MTD=/dev/mtd1 However in looking at /dev/ there is no mtd1, only mtd. So I modified script to LOGOCAL_MTD=/dev/mtd and then ran it with the following error
Code: [Select]
GETMEMINFO: Inappropriate ioctl for device

Try using not just /dev/mtd, but rather /dev/mtd/1.

jerrybme

  • Hero Member
  • *****
  • Posts: 639
    • View Profile
    • http://
New pdaXrom installer (to have just Root partition)
« Reply #103 on: August 20, 2004, 05:27:58 pm »
Thanks ikm, that worked. It created the mtdnand file and of course it didn't recognized the pattern. Reading the mtdnand hex is beyond my little brain.
Cheers,
Jerry
« Last Edit: August 20, 2004, 05:32:26 pm by jerrybme »
SL-C3100
Angstrom-GPE
Lexar SD 1 GB
PQI 2GB CF
Ambicom WL1100 CF

Ashley

  • Newbie
  • *
  • Posts: 46
    • View Profile
New pdaXrom installer (to have just Root partition)
« Reply #104 on: August 21, 2004, 12:09:05 pm »
Jerry, that mtdnand looks jerky. It makes no sense to me. How did you attached it?

BTW, I haven't tried RC2 yet...
c760 pdaXrom & zdebian (on SD)
256MB SD, 16MB CF, Prism 2.5 Wifi CF
Athlon XP
Debian sarge, Gentoo 1.4, RedHat 9, FreeBSD 5.1, xp