HELP! Can't install android, tried 10 times already... - Tilt, TyTN II, MDA Vario III Android Development

Guys, I have been trying to install android for 3 days already. No success. Tried atools 1.0.4, 1.0.5 and finally 1.1.0 today. I got the "bad block" errors. First I thought it is the SD card, changed it with another one, but same thing. Finally tried system and data on NAND and I got the following:
Format system
flash_eraseall: /dev/block/mtdblock2: not a char device
Failed
Failed to format
What should I do?
Any help will be appreciated!

My advice is to use ATOOLS only as NBH EDITOR to set your panel type and/or overclock GPU.
Install the kernel, do the reboot, and then press dpad when you see the message 'press and hold dpad .....'
Select system and data on NAND, install system (androidinstall.tar in andboot folder of course) and quit.
I suggest this way because I think that is little complicated to use a script generated by ATOOLS especially if you do not have much experience.

Millence said:
My advice is to use ATOOLS only as NBH EDITOR to set your panel type and/or overclock GPU.
Install the kernel, do the reboot, and then press dpad when you see the message 'press and hold dpad .....'
Select system and data on NAND, install system (androidinstall.tar in andboot folder of course) and quit.
I suggest this way because I think that is little complicated to use a script generated by ATOOLS especially if you do not have much experience.
Click to expand...
Click to collapse
I've just tried this way too, used atools as a nbh editor, put it in the root folder, then created andboot folder and put the TAR file inside.
Almost the same result:
Freeing init memory: 128K
[ 8.449793] set sdcc vdd to 16
[ 8.781563] clk_set_rate 21:32000000
[ 8.789359] set sd clock - 0 1
[ 8.815143] mmc1: host does not support reading read-only switch. assuming write-enable.
[ 8.832956] mmc1: new high speed SD card at address b368
[ 8.856739] mmcblk0: mmc1:b368 2GU2M 1.87 GiB
[ 8.869113] mmcblk0: p1 p2
After those I got Formatting, lots of bad blocks, then Installing...
Failed.
Not enough space on device...

The only logical explanation for this is that you have so mutch bad blocks on the NAND that not enough space remains for installation.
Try to increase the system partition to 120MB using ATOOLS.

Thanks for your reply!
Just did it. Same thing
The worst part is that I can't see exactly how many bad blocks I have, but they are at least 2 screens
Below is my log file.
Thanks is advance for your help.

Which rom are trying to install? What is the size androidinstall.tar file?

Bad blocks are normal on nand.
Reinstall, probably the androidinstall is too big.

Millence said:
Which rom are trying to install? What is the size androidinstall.tar file?
Click to expand...
Click to collapse
I've tried both Thoughtlesskyle's Not so Super Froyo and the "Gingerbones" rls5.1, one is 112K the other one is like 80-ish and I still got the same problem.
What if I put everything on the SD card, can I do that?

Finally...After increasing my system to 170MB I got it installed. Also tried with 160mb and less, but seems like I have so many bad blocks that there's no space for the system. But now looks like my space for data is very low. What would you guys suggest?

remove some apk from the android install...

Data on ext2 partition.

Related

[UTIL][OUTDATED] One Click Lag Fix 2.0

[size=+2]This version is now deprecated in favor of the 2.0 APK version. Please see this link: http://forum.xda-developers.com/showthread.php?t=784691[/size]
This version is not recommended for use any longer.
Details about what this fix does:
Creates a VIRTUAL EXT2 filesystem inside the stock RFS filesystem on the internal SD card, with a 4KB block size. This means that this lag fix creates a buffer between the real filesystem and the android system. This buffer should reduce the amount of disk I/O required for all operations by utilizing EXT2 buffering, as well as not writing file access times to disk, etc.
Folders that are currently supported:
/data/data
/data/system
/data/dalvik-cache
/data/app
/data/app-private as a symlink to /data/app/app-private
/dbdata/databases is not supported. It appears to be ROM backed, and can cause problems if overwritten.
Benefits over version 1
1.5GB of application data available, with no data loss.
e2fsck of the EXT2 partition on each boot.
Correct busybox version included! YES!
/app and /app-private directory included in the fix for faster application installs.
/dbdata/databases included in the fix, expected to give a big performance boost for apps that use it.
Mounts instead of symlinks for extra performance as OS does less work (about 100 or so more quadrant).
Benefits over other lag fixes
Open source, with full comments and ease of editing.
Works on any and all firmware versions, including any yet unreleased froyo versions (that don't change file structure).
Credits
Big thanks to mimocan for putting us all on the right track in how to sort out lag problems!
Big thanks to ykk_five for showing us all how well loopback filesystem mounting works!
Big thanks to cyanogen mod for e2fsck
Requirements for One Click Lag Fix 2.0
Rooted phone - http://www.addictivetips.com/mobile...t-samsung-galaxy-s-i9000-with-a-single-click/
Windows computer with SGS Drivers (Samsung Kies), or the ability to read through the batch file and run it yourself.
(Beta Release) The ability to reflash your device if something goes wrong.
No other lag fix installed. If you installed One Click Lag Fix 1.0, then use the uninstall function which came with that lag fix before running this lag fix. (Untested but assumed to be working, please help out here.)
1.5GB of freespace on Internal SD Card for swap files while the fix is working (/sdcard).
"Internal phone storage" in Settings->SD Card must read greater than 500mb (0.5GB) of free space.
How to run One Click Lag Fix 2.0
Place your phone into USB debugging mode: Settings->Applications->Development
Attach your device to your computer. Do not mount the drives.
Download the attached ZIP file.
Unzip to a folder of your choice.
Double click "lagfixme.bat".
Don't double click "unlagfixme.bat".
Wait for it to complete.
You will need your phone to be unlocked when it runs the script, so that you can accept the permissions request that will appear on your device.
How to remove One Click Lag Fix 2.0
Double click "unlagfixme.bat"
Wait for it to complete.
Known Issues For All Versions
Some custom firmwares use up all available space in /system. This fix requires some libraries to be placed in /system/lib. These libraries are used to create the filesystem properly, and to check it for errors on every boot.
If your firmware does not have the available space (around 1mb) in /system, do not use this fix! Your phone will not boot and will have to be restored from backup / reflashed.
Current known firmwares with this issue: None yet. Please provide the firmware version+mods if you encounter this issue. It will show up as an out of space error in the log, under 'Copying libraries'.
Known Issues 2-1, 2-2
Paid apps from the market have issues.
Google maps and other pre-installed ROM-backed applications have issues.
2-3 Changes from 2-2
/dbdata has been removed. This fixes maps issues.
/app-private is now a symlink to /app/app-private. This fixes paid apps issues.
Alternate installation methods for similar fixes
Tayutama has made an update.zip version that is easy to install - http://forum.xda-developers.com/showpost.php?p=7632258&postcount=208
Chainfire has a .NET version of this fix with some nice features - http://forum.xda-developers.com/showthread.php?t=751513
Frequently Asked Questions
Q: My apps are force closing while this fix is running, and I can't use my phone!
A: By design. The script has backed up/copied your apps over to the internal SD card (remember the requirement about 1.5GB of free space on the SD card?). It is now overwriting them with a 1.5GB file. As the file overwrites an app that is trying to do something, it will probably force close. This is normal.
Closing all running apps, and removing widgets before running this fix can make the process much smoother, though.
Q: The script can't transfer files to my phone / The script can't run / Help help I'm dieing!
A: Read the first post again.
Q: My paid apps from the market don't show up.
A: I will hopefully have a fix for this sooner or later. Hold tight! It's in the known issues. I don't have access to paid apps, so I can't test this.
Q: Does this need busybox?
A: No, busybox is included.
Q: I only have 200mb of free space now! What gives?
A: The lag fix has made a 1.5GB file, and is storing all of the data inside there. The side effect is that the free space meter is now incorrect. Sorry, this can't be helped.
You can check real free space by using ADB like this:
Code:
adb shell
su
busybox df -h
Q: When I use a backup tool, the backup is now 1.5GB big! It's taking forever!
A: The backup tool isn't designed to work with this fix. It will work, it just won't work well. Hopefully this fix will be short lived, and either Samsung will give us a new update, or someone will give us a good custom firmware that can natively mount what we need, where we need it. Or someone might come out with a better backup manager. Until then, we suffer.
Q: Will a reflash wipe this fix?
A: Yes, a reflash will wipe everything this fix did.
Q: Can this brick my phone?
A: If you know how to get to the download mode from power off (hint: volumedown+home+power), then almost nothing short of throwing your phone off a tall building can actually brick it. If you can't do this though, or don't know someone who can, then you're better off waiting for samsung to release a fix. Anything that moves files around on your device has the potential to break things, and this fix has no QA department.
Q: Why is /dbdata not included in your fix, but other people have included it?
A: Other people have included it in the same way my 2-2 fix includes it. However, /dbdata is ROM backed. This means that the real files are on ROM, and only the changes appear in the /dbdata folder. When copying or moving files from this folder, you would need to specify each folder by exact name to ensure that it was copied across, and each firmware can have their own names. (This is because RFS wildcard will not catch an unused ROM backed file.) In some cases, you can get lucky and have this work perfectly because you have already used all the files in /dbdata. There is no fail safe method to do this though, and /dbdata does not make a big difference to performance. (It is already on NAND flash.) If you want to try your luck, v2-2 is still available.
Q: Why does this lag fix work? Is it slowly destroying my phone?
A: Let's say an application counts from 1 to 10, and writes the value each time to disk.
Stock:
1 -> App tells RFS to write 1 to disk -> RFS writes 1 to disk -> RFS writes journal saying to changed the value on the disk.
2 -> App tells RFS to write 2 to disk -> RFS writes 2 to disk -> RFS writes journal saying to changed the value on the disk.
..
9 -> App tells RFS to write 9 to disk -> RFS writes 9 to disk -> RFS writes journal saying to changed the value on the disk.
10 -> App tells RFS to write 10 to disk -> RFS writes 10 to disk -> RFS writes journal saying it changed the value on the disk.
Total physical disk writes: 20. Speed: SLOW! Wear and tear on disk: HIGH!
Lag Fix:
1 -> App tells EXT2 to write 1 to disk -> EXT2 stores 1 in RAM.
2 -> App tells EXT2 to write 2 to disk -> EXT2 stores 2 in RAM.
..
9 -> App tells EXT2 to write 9 to disk -> EXT2 stores 9 in RAM.
10 -> App tells EXT2 to write 10 to disk -> EXT2 stores 10 in RAM.
..
EXT2 tells RFS to write 10 to disk -> RFS writes 10 to disk -> RFS writes journal saying it changed the value on the disk.
Total physical disk writes: 2. Speed: FAST! Wear and tear on disk: LOW!
This isn't exactly what is happening, but it gives you the general idea.
Q: Can this mod work on other Android devices? Would we see a performance boost on them as well? If not why is it limited to the Galaxy S?
A: SGS has very very good hardware, but it has some parts of it's hardware poorly implemented. The filesystem that samsung chose to use is custom-built using FAT32 as a base, RFS. It has a lot of the problems that FAT32 has, and should have been left back in the 90s, or even the 80s.
One of the big issues with it is how it handles multiple requests - it blocks. It blocks everything. When your mail app wants to read the mail you just tried to view, but your twitter app is busy writing a new tweat it just received, your mail app is forced to wait.
This is bad, but it could be worse! And it is... your twitter app didn't just get one tweat, it got 50 tweaks. It is busy writing the tweats one by one to the filesystem. This would be fine, since all modern filesystems will buffer writes, so instead of writing each one at a time, they will batch them together and write it as a big chunk. Uh oh - RFS does no buffering at all! After each write, it will also write an update to the grafted-on journal system. Guess what happened to your mail you were trying to view while all this happened? It 'lagged' and you got a black screen for half a second, before the mail popped into view.
Luckily the hardware on the device is so good that you usually don't even notice the problem until you have a lot of apps running, all writing their updates when you unlock the phone.
This is mostly speculation based on experiments done on RFS -- RFS is closed source, and we have no idea if the problems are just badly set settings (such as a block size that is too small), coding bugs in the implementation, or if RFS is just really that badly designed.
This fix just grafts a buffer on top of the RFS filesystem, using a very very simple and fast filesystem, EXT2. It fixes most of the issues by writing to RFS as seldom as possible.
So no, this fix won't fix other devices, since they're already running quite close to maximum speed. The SGS at stock is running nowhere near maximum speed, and this lag fix takes it a bit closer. You could probably speed up other devices by tweaking the filesystem settings to give them a big buffer or similar, but it isn't really needed. (I haven't actually tried to put an EXT2 onto any other Android phone, as I don't have any other Android phone, so this is just speculation.)
Q: My phone is fast now!
A: Yeah.
Oh, awesome. I managed to post this in the wrong forum. Doh!
Could a moderator please move this to Android Dev sub forum?
haha looks awesome dude but you are correct, wrong section im gonna try it now, will report in 5 mins!
A few people in the other thread said they had the first lag fix working on the captivate. Anything that might change that with this release? I came to download the old one, and here a new one is
abra-cadabra...
*POOF*
Done!
E_man5112 said:
A few people in the other thread said they had the first lag fix working on the captivate. Anything that might change that with this release? I came to download the old one, and here a new one is
Click to expand...
Click to collapse
The old one is still here. Nothing has changed that should stop it working on the captivate though, but it is completely untested. Use the 1.0 (which has had a lot of testing) until this one has been put through the paces.
sirphunkee said:
abra-cadabra...
*POOF*
Done!
Click to expand...
Click to collapse
Thanks.
RyanZA said:
The old one is still here. Nothing has changed that should stop it working on the captivate though, but it is completely untested. Use the 1.0 (which has had a lot of testing) until this one has been put through the paces.
Click to expand...
Click to collapse
E_man5112 said:
A few people in the other thread said they had the first lag fix working on the captivate. Anything that might change that with this release? I came to download the old one, and here a new one is
Click to expand...
Click to collapse
I'm running the manual ext2 fix with Q scores 2000+. I'll try 2.0 Util tonight and post feedback....
Someone got some benchmarks?
Maybe for xxjp3? I only reach 1900 in quadrant.. /:
Sent from my GT-I9000 using Tapatalk
gonna test report in 5minutes
RyanZA said:
The old one is still here. Nothing has changed that should stop it working on the captivate though, but it is completely untested. Use the 1.0 (which has had a lot of testing) until this one has been put through the paces.
Click to expand...
Click to collapse
I'm in the process of flashing back to stock on my Captivate so I can give this a legit test. I'll report back here and let you know how it goes. Assuming my Captivate doesn't melt I'll update my OP from the thread about the original fix in the Captivate section!
About what lag is this?
Sent from my HTC Desire using XDA App
Dominik06 said:
Someone got some benchmarks?
Maybe for xxjp3? I only reach 1900 in quadrant.. /:
Sent from my GT-I9000 using Tapatalk
Click to expand...
Click to collapse
Benchmarks are roughly the same as 1.0. You can expect about 100 points more on average though, at least on my phone.
I just removed the V1 version and finished the V2.
It finally finished and rebooted the phone. now it tells me my internal memory storage is full. None of my Widgets will load.
Looking i see only 14MB free in internal storage.
thoughts?
Zilch25 said:
I'm in the process of flashing back to stock on my Captivate so I can give this a legit test. I'll report back here and let you know how it goes. Assuming my Captivate doesn't melt I'll update my OP from the thread about the original fix in the Captivate section!
Click to expand...
Click to collapse
Just as long as you point out that this fix isn't heavily tested yet!
RyanZA said:
Just as long as you point out that this fix isn't heavily tested yet!
Click to expand...
Click to collapse
Oh I know, I'm going to emphasize that heavily, lord knows I don't want to get stuck on tech support all night
clubtech said:
I just removed the V1 version and finished the V2.
It finally finished and rebooted the phone. now it tells me my internal memory storage is full. None of my Widgets will load.
Looking i see only 14MB free in internal storage.
thoughts?
Click to expand...
Click to collapse
Thoughts? That's bad.
You should be seeing roughly 215mb free. Did you see any errors in the log at all?
Everything is working fine for me. First reboot after lagfix had some problems with downloading apps from market, but after a second reboot it got fixed.
"Biggest" problem now, is just the phone stating that my internal phone storage is too low, with an icon on notification bar that I cannot remove. Already deleted some .bak from /data folder, any more tips what I can delete to get rid from this message?
Regarding the fix. apps are indeed much more snappier, no lag on the system when installing apps from market, and overall if the phone would continue like this for the next 48 hours, lag fix form me is solved. I had some problems after some 24h, with some lag, even with the previous version of the lag fix.
clubtech said:
I just removed the V1 version and finished the V2.
It finally finished and rebooted the phone. now it tells me my internal memory storage is full. None of my Widgets will load.
Looking i see only 14MB free in internal storage.
thoughts?
Click to expand...
Click to collapse
Looking through my old V1 remove script, I believe I was leaving behind the .bak files! Nastyyy... I'll update V2 to remove those if they're there on install. Will hopefully clear up any problems.

[Q] android install..please help!!..ive read guides

hey guys, im sure this is getting old for some..but yes im a newbie, 8925 user. ive read the android install on htc by l1q1d, which i thought brought me in the correct position.. (not to say it wasnt a good guide, im sure it is..im a noob) i was wrong heres what im using and trying to accomplish, i sarted out reading "How to replace Windows Mobile with Android (Guide)" the first thread, i used jump spl 1.93 , flashed hard spl 3.56, flashed radio 1.71.09.01, then i used the htc on droid guide on atools to configure my kernal (which i loaded while in atools, i tried both 2.6.52 and 2.6.32-which is the current one im using )saved the KAISIMG.NBH in the root of my sd card(2GB HP i think its class 4) then set up my androidinstall.tgz(Incubus26Jc's Super FroYo RLS16 All Languages) in the atools mixer with the unique module update in atools V1.0.4 and extracted them together. saved the androidinstall.tgz in the /storagecard/andboot. then used BSE boot script editor, to setup my install-seq.sh which i also saved to the /andboot folder.
Heres my current specs again in line:
jump spl 1.93
hardspl 3.56
radio 1.71.09.01
kernal 2.6.32
Build Incubus26Jc's Super FroYo RLS16 All Languages with atools module update extracted together
when installing , the farthest point i reached was a succesful install of kernal, then reboot, install-seq.sh started---end result "could not determine file system size", failed, failed to format.
im currently trying to use nand for system and sd card for data , not sure what SWAP means?...
as for the seetings for fstab on atools ( which was the most confusing for me), i p
SYSTEM- NAND p2
DATA- sd partition p2
SWAP- sd partition p3
ive also tried system as nand p2, and data as nand p3 and swap at auto, cause i figured im having issues with my sd card , but then it said something about "install update module for kernal". im stumped any information you can helkp with would be greatly appreciated, here a few links to pics of the settings i made in atools, thanks alot
Hmmm, I have just tried that myself and I think it might be a bug in atools - I was changing nand partition sizes and the only combination I could get to work was Atools 1.0.4 with all fstab setting set to auto (I haven't tried Atools 1.0.5 yet, but 1.1.0 didn't work for any combination of settings for me)
Also I've never used the install-seq.sh so I can't help with that.
As a "good" starting point try using Atools 1.0.4 , latest kernel, don't change system/data partition sizes and leave all fstab settings on auto.
Flash that nbh then install through the boot menu (hold D-pad centre on boot)
If that works, then it will be easier to work from there to find out what exactly was causing the problem
huh, yup im learning as i go lol , i have tried to boot without using the install-seq file but have not tried to install with fstab on auto. what does that mean though, if its placed on auto is it going to just pick whatever i feel like at the moment , im assuming system will be on nand , but what about data. and also ive tried looking it up but what does SWAP mean? thanks alot im gonna try what u said
EDIT: ok i tried that out i got into the manual install by pressing the dpad center button, then i picked system and data to be installed on nand , then installed, then quit, then it, loaded for a while then it went to a droid screen and a animated green ball that seemed to be loading but just stayed there and did nothing. so i turned off the phone.... could it be because i didnt press 4. install update(do i even need to)? OR should i have installed system on nand then data on sd partition?
try again, and leave it a bit longer, the first boot of an un-odexed build can take aver long time, maybe about 10 minutes
swap is extra space for RAM, but on the NAND memory or SD card - like a swap partition on linux or a pagefile on windows. By default there is no swap partition used.
option 4: "install update" extracts the contents of an androidupdate.tar or .tgz file in the andboot folder, if you haven't got an androidupdate file you're trying to use then you don't need to use this option
allright ill try it now thanks man
i tried it again, but this time i used thoughtlesskyles not so super froyo rls18 and i waited , and it finally came up its installed ive checked a few things, calling works, wifi ,navigation maps some cool stuff. im gonna use this for a while then try my luck on some other endeavors. thanks again

[initrd][DL Data2SD/Ext4+ V1.5] Enable your build with fast ext4/data.img support

This is my development based on Takaaki's initrd, during I develop my build at http://forum.xda-developers.com/showthread.php?t=913597, I spent a lot of time to enhance the data2sd and ext4, after studying almost all the popular methods: App2SD, Data2SD, Data2ext, Data2whatever, I develop this:
Features:
1. Support both data 2 data.img or ext4.
2. Support SquareFS.
3. Auto-format the 2nd partition with block size of 4096.
4. Utilize the Nand data partition to improve the performance.
5. Switch the PPP/RMNET.
6. Config the gps_zone
7. Support the update without re-flash. (you can fully customize your build based on this feature)
8. Backup the ext4 to data.img (implement in future)
9. Restore the data.img to ext4 (implement in future).
To enable external data.img
1. create '.data' folde under sdcard (/sdcard/.data).
2. create 'config.txt' under '.data' directory.
3. copy old data.img to '.data' directory, otherwise a new data.img will be created.
4. boot into Android.
Config.txt for data2SD.
data_img=1
data_ext=0
sd_boost=1
nand_data=0
Click to expand...
Click to collapse
To enable ext4
1. create '.data' folde under sdcard (/sdcard/.data).
2. create 'config.txt' under '.data' directory.
3. Config.txt for data2SD.
data_img=0
data_ext=1
sd_boost=0
nand_data=0
format_ext4=0
Click to expand...
Click to collapse
For first installation, it is always good to set the format_ext4=1 to format your ext4 partition with proper block size, after 1st boot, change it back to 0.
To config PPP/RMNET and GPS_ZONE
ppp_mode=1 will enable the ppp, set to 0 will use rmnet.
gps_zone='your country code', - country code, us, fr, jp, etc
To update/customize your build
1. Create a folder /DLZUPDATE under your sdcard.
2. put your app's apk under AndroidApps in /DLZUPDATE, that apps will be automatically installed into your data partition.
3. put your kernel file or other under root in /DLZUPDATE, all the files under root will be copied to your build, if your want to upgrade your kernel, just put zImage in /DLZUPDATE/root/system, and module files under /DLZUPDATE/root/system/lib/modules. etc.
Download
View attachment 492146
Install
1. extract the zip to a folder on your pc
2. backup your existing initrd.gz using adb
3. In "command prompt" env, run install.
4. your existing initrd.gz will be backup at the same folder named backup.initrd.gz.
5. if your have problem to boot into the system, just try: adb push backup.initrd.gz /system/initrd.gz. (even system can not be booted into the launcher or sense, in some point of time, the adb still can function, so just keep trying.)
Caution: if your build current use app2sd, you have to disable it before using this, rename the init.local.rc under etc to init.local.rc.bak, remove the 00start, 04apps2sd from /system/etc/init.d.
If your build uses boot partition, you should change the installation script to push the initrd.gz to replace the existing one wherever it is.
Thanks to
- ownhere (he is the expert of the ext4 or other file systems, and developed the data2ext.)
- melethron (the author of data2whatever)
- Takaaki (the author of data2sd)
- Cedesmith (He is guru of initrd )
Donation
I do not work for money, but it is always nice to know people really like my work and encourage me carrying on.
Please could you provide also information in case that NAND rom already use EXT4 for data2ext4 (like AF403 DesireHD stock based 1.0a)?
Good stuff.. thank you!
I am trying your NAND ROM now....
Good knowledge ... keep up cool stuff
i already use ur nand rom
If you don't want to look into the code to find out the difference, then, how about just try 1st.
totalcmdext said:
Please could you provide also information in case that NAND rom already use EXT4 for data2ext4 (like AF403 DesireHD stock based 1.0a)?
Click to expand...
Click to collapse
Sent from my DL DesireZ v2.5 using XDA App
Ok, i've managed to understand the concept of data2ext, and when on initial setup everything gets what i expect, i've 1 GB (depends on ext partition size) of free memory space, but i get an horrible performance even if formated with your tool, i guess it's SD performance/quality because i can't run any ext build published here where most of users claim to get good performance. So i try data2sd but instead of the 512MB (img size created with this) of memory i get only the 80MB of the free nand internal ram. What is stored on this img file ? only settings ? On 20 applications i use only 4 are movable to sd, so after my initial setup (and of course with good performance) i get a lot of memory low warnings.
Thanks
Looks like the data2sd was not enforced, what's your configuration in config.txt?
jpl69 said:
Ok, i've managed to understand the concept of data2ext, and when on initial setup everything gets what i expect, i've 1 GB (depends on ext partition size) of free memory space, but i get an horrible performance even if formated with your tool, i guess it's SD performance/quality because i can't run any ext build published here where most of users claim to get good performance. So i try data2sd but instead of the 512MB (img size created with this) of memory i get only the 80MB of the free nand internal ram. What is stored on this img file ? only settings ? On 20 applications i use only 4 are movable to sd, so after my initial setup (and of course with good performance) i get a lot of memory low warnings.
Thanks
Click to expand...
Click to collapse
Sent from my DL DesireZ v2.5 using XDA App
This is good and detail steps http://forum.xda-developers.com/showpost.php?p=10666187&postcount=341 on how to config, better than mine
Sent from my DL DesireZ v2.5 using XDA App
If i understand this, this is only change existing inird with modified initrd?
I'm sorry but with all this flash/unflash install/uninstall download configure i've lost my config, but i'm sure data_img=1 and data_ext=0
(just a note gps_zone=pt should configure gps to be used here in Portugal right ?)
If you say that it should work i'm going further with my tests and post here results because i don't want to flame this thread.
Update:
I've a stock 8GB class 4 card swaped with 4GB class 2, results on nand/ext4:
Initial setup (with format ext4) 1/2 time, second boot 1 minute and everything runing muuuch smother and faster so or i've got a malfunction card (?) (and i've read someone complaining about a 16GB class 10) or lowest class gets more speed (?)
Update2:
The diference is really amazing, i've got a completly functional android now with this card.
You should mention on your threads that if you get bad results on initial setup forget about that nand, return to SD builds or get other card.
Can you please post your card type please ?
how long does it take to format the ext4?
Hi,
I am trying to setup this new initrd, i put the format ext4 parameter in the config file and start my HD2.
wondering how long will it take to format my 1G ext4 partition?
thanks!
data.img Question
3. copy old data.img to '.data' directory, otherwise a new data.img will be created. ... Can I somehow set how big will the data.img be ?
Default will be 512M, you can config it by data_size.
BoneMo said:
3. copy old data.img to '.data' directory, otherwise a new data.img will be created. ... Can I somehow set how big will the data.img be ?
Click to expand...
Click to collapse
Sent from my DL DesireZ v2.5 using XDA App
Looks promising
This new initrd and file management seems well thought through and very promising.
In other builds I experienced that there can be a huge performance difference between the different file management choices (full NAND > adsd > ads2+ > data2ext > data2sd). It's good to see that you got into this subject and tried to find an optimal solution which can be configured by other chefs.
I assume that you implemented all this in your own DL DesireZ v2.5 build? If I find time I'm certainly gonna give it a try!
Keep up the good work!
works with AF403 DesireHD stock based 1.0a
there are a lot of discussions on my nand build about mixing using all the parameters, some got the performance improved a lot, some got things worse, your can refer to that to config your build for the best performance.
Dear, i got this error message...
D:\a>install
back your initrd...
remote object '/system/initrd' does not exist
replace your initrd...
1442 KB/s (0 bytes in 1523605.001s)
failed to copy 'mkfs.ext4' to '/system/xbin/mkfs.ext4': No space left on device
1263 KB/s (0 bytes in 303212.000s)
1410 KB/s (0 bytes in 428664.000s)
Unable to chmod /system/xbin/mkfs.ext4: No such file or directory
Unable to chmod /system/xbin/e2fsck: No such file or directory
Press any key to continue . . .
please help... I am using Gauner1986 build
Looks like the system in Gauner1986 build is read only or have the boot partition, or really occupied all the space? anyway, your existing build should be unchanged.
you can try adb shell ls /system, or adb shell ls /boot, whether there is an initrd.gz under it, then, manually push all the necessary files.
rasumia said:
Dear, i got this error message...
D:\a>install
back your initrd...
remote object '/system/initrd' does not exist
replace your initrd...
1442 KB/s (0 bytes in 1523605.001s)
failed to copy 'mkfs.ext4' to '/system/xbin/mkfs.ext4': No space left on device
1263 KB/s (0 bytes in 303212.000s)
1410 KB/s (0 bytes in 428664.000s)
Unable to chmod /system/xbin/mkfs.ext4: No such file or directory
Unable to chmod /system/xbin/e2fsck: No such file or directory
Press any key to continue . . .
please help... I am using Gauner1986 build
Click to expand...
Click to collapse
dandiest said:
Default will be 512M, you can config it by data_size.
Sent from my DL DesireZ v2.5 using XDA App
Click to expand...
Click to collapse
So you mean data_size= ... (512,1024,2048)
This is in cofig.txt?
jan-willem3 said:
So you mean data_size= ... (512,1024,2048)
This is in cofig.txt?
Click to expand...
Click to collapse
Yes, but please don't use 2048.

Clemsyn's Kaiser Kernel Corner for 2.6.32 with EXT4 for DATA (SD) install

**** EXT4 for DATA (SD) install on second post *****
I've been slowly working on our Kaiser Kernel hoping to get extra life from it. Here are the changes I made so far.
1. Updated to the latest initrd and made a few changed in the init file
2. Changed the default I/O scheduler to noop.
3. Added block data integrity support and v4 support
4. Updated the latest yaffs2 filesupport up to changes dated 1/14/2011
5. Added PM module for Qualcomm 7500 chip
Will try to add BFQ I/O scheduler and see how the performance is compared to noop.
1/29/11 ** UPDATED KERNEL for better YAFFS2 best suited for Kaiser Samsung Memory chip **
Here is the nbh. This is type2 screen and keyboard1.
Will release my latest changes and update to git (need help on this one) when stable.
Please reinstall ROM and wipe data after flashing the kernel. The changes in yaffs2 code might cause issues. You can restore your data from BACKUP after installing the ROM.
************ TO FORCE CHECKPOINT IN DATA PARTITION PLEASE DO THIS IN TERMINAL *******************
su
echo 6 > /sys/module/yaffs/parameters/yaffs_auto_checkpoint
sync
This will change auto checkpointing to 2 and create a checkpoint.
This is just temporary, the checkpoint is deleted in reboot so the commands have to be done before every reboot.
One solution is to use Gscript.apk and type the commands in Gscripts. Execute via Gscript before reboot
**** To verify if you have checkpoint in Data Partition Please do in Terminal ******
To verify if you have yaffs2 checkpoint in the data partition Type the following in terminal
su
cat /proc/yaffs
Scroll down to Device 2 "userdata"
scroll down and look for "blocks_in_checkpt" should be 1 or 2 (not 0, if it is zero then you have no checkpoint in data partition)
Update 2/7/2011
******************EXT4 FILESYSTEM FOR SD INSTALL***************
Because of bad blocks on my Kaiser, I have to give all NAND partition to install on system while installing data on SD with EXT4 filesystem. Here are the requirements:
1. An SD card with at least class 4
2. A way to partition and format your SD with FAT/ext2/Ext4 (ext2 should be as small as possible), I use Ubuntu for this.
3. Kernel with ext4 support (this will format your whole NAND partition to use system and use EXT4 on SD for Data)
Instructions:
1. FORMAT SD (I use Ubuntu DiskUtil) with FAT/ext2/EXT4, on my 8GB SD I use 7gb for FAT/8mb for ext2/1gb for EXT4 but it's your call. The most important part is that you only give the second partition (ext2) the least amount of size.
2. Download the KAISIMG.zip, extract and you will get a file KAISIMG.NBH
3. use Atools to edit accordingly with your Kaiser's screen type and keyboard (NBH is using screen 2 and keyboard 1)
4. Flash the KAISIMG.NBH
HERE IS WHERE IT GETS TRICKY!!! PLEASE FOLLOW THESE INSTRUCTIONS CAREFULLY!!!!
a. PRESS CENTER D PAD to enter ANDROID Installer
b. Choose (*) Sys on NAND
Choose (*) Data on SDCard Partition
c. Scroll Down to Install System and choose it
d. This will wipe your Existing system! Are you sure CHOOSE (YES)
e. Would you like to clear data too (Suggested) CHOOSE (NO) ***DO NOT CLEAR DATA OR THIS WILL CHANGE YOUR THIRD PARTITION TO EXT2 and will not work.
That's it. After installation reboot and you have an optimized ext4 on your SD for data. The mount options for ext4 in this kernel are:
data=writeback, barrier=0, nobh, noauto_da_alloc
Will use barrier=1 for better data security on next release, just enjoying the speed of barrier=0 for now
clemsyn said:
Will try to update our 2.6.25 kernel too if I get some space for my hard drive.
Click to expand...
Click to collapse
Yes, Clemsyn If it's not a big problem please update 2.6.25 too. Thank you.
updates kernel 2.6.25
clemsyn said:
Will try to update our 2.6.25 kernel too if I get some space for my hard drive.
Click to expand...
Click to collapse
This would be nice. Thank you
mt1976 said:
This would be nice. Thank you
Click to expand...
Click to collapse
It would take awhile though since I have to remove my 2.6.32 kernel to put 2.6.25 since I'm limited in space. Donations for a laptop HD would be appreciated
UPDATE:
1. I think one of the reasons of data failure is that YAFFS refuses to write a checkpoint for our data partition. It writes it in the system partition with no issues. The new yaffs2 (updated 1-27-11 which I will update shortly) allows forcing checkpoint so I'll try that one and see if I can create a checkpoint on our data partition.
Finally got a checkpoint in my userdata partition...instructions posted on first post, no update on yaffs needed
clemsyn said:
It would take awhile though since I have to remove my 2.6.32 kernel to put 2.6.25 since I'm limited in space. Donations for a laptop HD would be appreciated
UPDATE:
1. I think one of the reasons of data failure is that YAFFS refuses to write a checkpoint for our data partition. It writes it in the system partition with no issues. The new yaffs2 (updated 1-27-11 which I will update shortly) allows forcing checkpoint so I'll try that one and see if I can create a checkpoint on our data partition.
Click to expand...
Click to collapse
I have a 20 GB Sata laptop drive I could get to you. Used to be in a 360 and then broke the enclosure open for a hdd when the one in my laptop died. Drive works just fine, just small lol
aceoyame said:
I have a 20 GB Sata laptop drive I could get to you. Used to be in a 360 and then broke the enclosure open for a hdd when the one in my laptop died. Drive works just fine, just small lol
Click to expand...
Click to collapse
Sorry about your phone. I was hoping you could test out my new kernel. ANyways, I think yaffs2 was having issues creating a checkpoint on the data partition since yaffs was only creating a checkpoint on proper unmount (which was not done in our kaiser). The latest yaffs can make us force a checkpoint by simply typing the command in the first post and typing "Sync" on terminal automatically creates a checkpoint in data partition. I'm currently testing it now and seeing how it goes.
BTW, I'll take that donation re:HD since I can use it as an external HD and put the 2.6.25 kernel there and improve it (that is if wife permits).
clemsyn said:
Sorry about your phone. I was hoping you could test out my new kernel. ANyways, I think yaffs2 was having issues creating a checkpoint on the data partition since yaffs was only creating a checkpoint on proper unmount (which was not done in our kaiser). The latest yaffs can make us force a checkpoint by simply typing the command in the first post and typing "Sync" on terminal automatically creates a checkpoint in data partition. I'm currently testing it now and seeing how it goes.
BTW, I'll take that donation re:HD since I can use it as an external HD and put the 2.6.25 kernel there and improve it (that is if wife permits).
Click to expand...
Click to collapse
lol she's really not that strict, she just thinks my development for our devices is a waste of time. Just PM me where to send it and ill get it out to you.
aceoyame said:
lol she's really not that strict, she just thinks my development for our devices is a waste of time. Just PM me where to send it and ill get it out to you.
Click to expand...
Click to collapse
Agreed, that's what my wife thinks too I'll PM you my location
BTW, please make sure that the location of yaffs_auto_checkpoint is in /sys/module/yaffs/parameters (some ROM might have it on modules).
UPDATE:
Checkpointing is working great for me so far. Command on first post has to be executed in every reboot to create a checkpoint so typing the commands in first post before rebooting will create a checkpoint and save data partition (me thinks).
You can install Gscript and run the script before reboot
To verify if you have yaffs2 checkpoint in the data partition Type the following in terminal
su
cat /proc/yaffs
Scroll down to Device 2 "userdata"
blocks_in_checkpt should be 1 or 2 (not 0, if it is zero then you have no checkpoint in data partition)
Can anyone help adding this to the shutdown script?
I've done 5 restarts, 2 battery pulls and 2 resets, made sure data partition was checkpointed before doing so....So far data partition has been OK with no FC's or errors, no lost apps with 18mb's left in data partition The thing that surprises me is that Phone Storage size hardly changes in size in every reboots so it's good news I have a feeling we finally nailed down this data corruption issue, but only time can tell since I will shift to prolong use before doing any restarts...
I have sent a PM to scooter hoping he can help me with a shutdown script so we won't need a Gscript. So far, Gscript is doing it for me. Upong reboot, I run the script and make sure I have a checkpoint in data partiion
clemsyn said:
sent a PM to scooter hoping he can help me with a shutdown script so we won't need a Gscript. So far, Gscript is doing it for me. Upong reboot, I run the script and make sure I have a checkpoint in data partiion
Click to expand...
Click to collapse
I've got it working in a script, i have it in a script which is run on startup and then again on a successful shutdown. I'll upload a couple of updates in a bit
EDIT: I have attached 2 updates to the post, one is for cyanogenMod based builds and the other is for all other builds such as fresh froyo etc.
Clemsyn, i have the latest yaffs source compiled into the kernel, i will commit it to git in a bit. With the latest yaffs a checkpoint is created every time sync is executed which makes scripts easier!
scooter1556 said:
I've got it working in a script, i have it in a script which is run on startup and then again on a successful shutdown. I'll upload a couple of updates in a bit
EDIT: I have attached 2 updates to the post, one is for cyanogenMod based builds and the other is for all other builds such as fresh froyo etc.
Clemsyn, i have the latest yaffs source compiled into the kernel, i will commit it to git in a bit. With the latest yaffs a checkpoint is created every time sync is executed which makes scripts easier!
Click to expand...
Click to collapse
I downloaded the CM update, and it didn't enable the checkpoint, still had to enable it manually through terminal.
Testing the kernel right now however, and so far liking it.
scooter1556 said:
I've got it working in a script, i have it in a script which is run on startup and then again on a successful shutdown. I'll upload a couple of updates in a bit
EDIT: I have attached 2 updates to the post, one is for cyanogenMod based builds and the other is for all other builds such as fresh froyo etc.
Clemsyn, i have the latest yaffs source compiled into the kernel, i will commit it to git in a bit. With the latest yaffs a checkpoint is created every time sync is executed which makes scripts easier!
Click to expand...
Click to collapse
Thanks scooter, I'll try it out. I got stuck on a fake vsync and can't get out of it that I was unable to create a checkpoint and upon reboot without a checkpoint, everything was messed up. This is perfect, getting a checkpoint on startup and another in shutdown Thanks a lot.
Krazy-Killa said:
I downloaded the CM update, and it didn't enable the checkpoint, still had to enable it manually through terminal.
Testing the kernel right now however, and so far liking it.
Click to expand...
Click to collapse
That's weird! So it didn't make a checkpoint on startup? I'm running the same script and init.rc and it works fine. I did push the file with adb though, did you fix permissions after updating?
scooter1556 said:
That's weird! So it didn't make a checkpoint on startup? I'm running the same script and init.rc and it works fine. I did push the file with adb though, did you fix permissions after updating?
Click to expand...
Click to collapse
Ooooooh.... Probably not, lol. I'll do that, and edit this post with my results.
*EDIT* Ok, I feel stupid. I still had an old androidupdate.tgz file in my sdcard andboot folder, and the boot menu used it instead of the correct .tar file... Hm, that explained why my Market stopped working, lmao.
Krazy-Killa said:
Ooooooh.... Probably not, lol. I'll do that, and edit this post with my results.
*EDIT* Ok, I feel stupid. I still had an old androidupdate.tgz file in my sdcard andboot folder, and the boot menu used it instead of the correct .tar file... Hm, that explained why my Market stopped working, lmao.
Click to expand...
Click to collapse
lol, rookie error
OK, it works on boot up since I get a checkpoint 1 every boot not sure about shutdown but if scooter says it works, I bet you it works in shutdown too
Scoot, I'm going to try to do a git diff and post it here so all the changes I've made in the config will be there.
Even with that little debacle, I had 0 corruption of data, or missing apps in my /data partition, and had to reboot 4-5 times, each time I used GScript to execute the command manually before shutdown.
And camera still works. ^.^
Krazy-Killa said:
Even with that little debacle, I had 0 corruption of data, or missing apps in my /data partition, and had to reboot 4-5 times, each time I used GScript to execute the command manually before shutdown.
And camera still works. ^.^
Click to expand...
Click to collapse
That's great news and if my memory serves me right, you easily have data corruption in shutdowns and reboot. IMO, scooter's script is the best option we have for this issue and you don't have to remember to use gscript (especially from an old person like me with slight dementia Anyways, I'll continue on with my testing with this script. If it is still working after a few days, I'll try to add Namespace support, CIFFS, PPOE in our kernel.
BTW, here is my git diff and .config file. Please put it up in GIT. Thanks.

[WIP] Booting NST from the sd card

This is still a work in progress but the Nook Simple Touch can now boot from the sd card. If you would like to learn how view klausef's comments in post number 27 (http://forum.xda-developers.com/showpost.php?p=25325319&postcount=27).
I will continue to update this post when there is new information
Thanks to klausef for working on this and creating a solution to my question.
Thanks to all of those that contribute to nookdevs and thanks to everyone else that has commented on this topic.
I wonder what would happen if I were to write a backup of the Nook onto an SD card and put it in (with the Nook itself wiped so it can't boot from the internal flash)
Nothing, because the mountpoints are wrong.
It should be possible, but I never tried it:
-partition and format the sd in a similiar way like the nook,
-unpack the uRamdisk and edit the mountpoints in the init.rc from mmcblk0 to mmcblk1
Again, I'm not sure if it works, thats what I read somewhere. And even if it works, it will be slow if you don't use a really fast sd-card.
mali100 said:
Nothing, because the mountpoints are wrong.
It should be possible, but I never tried it:
-partition and format the sd in a similiar way like the nook,
-unpack the uRamdisk and edit the mountpoints in the init.rc from mmcblk0 to mmcblk1
Again, I'm not sure if it works, thats what I read somewhere. And even if it works, it will be slow if you don't use a really fast sd-card.
Click to expand...
Click to collapse
Onwards to experimentation!!!!
mali100 said:
And even if it works, it will be slow if you don't use a really fast sd-card.
Click to expand...
Click to collapse
He meant not SD class (sequential I/O speed), but random (SD brand mostly)
Explained here: http://forum.xda-developers.com/showthread.php?t=1102704
So it is possible thats good news. Do we know of any body thats working on it? or can someone instruct me on how to edit the files that need to be edit?
ApokrifX said:
He meant not SD class (sequential I/O speed), but random (SD brand mostly)
Explained here: http://forum.xda-developers.com/showthread.php?t=1102704
Click to expand...
Click to collapse
Yes, I know that. I wasn't planning on using this for day-to-day use, just testing to see if it would boot.
Googie2149 said:
Yes, I know that. I wasn't planning on using this for day-to-day use, just testing to see if it would boot.
Click to expand...
Click to collapse
Have you got anything to boot off the sd card?
probbiethe1 said:
Have you got anything to boot off the sd card?
Click to expand...
Click to collapse
Haven't tried yet, been busy with a school project. I finish it tomorrow, so I'll try then. Maybe. Probably.
Cool good luck with your school project
Forgive me if this explanation goes through too basic of things for you but I am trying to establish context. Basically here's the status:
When you hit the power button on the nook touch, it calls some bootloader software called UBoot, that's kind of like a BIOS for embedded systems. UBoot looks for a file called UImage and a file called URamdisk. These two files contain the kernel and the root filesystem (and maybe a few other things, I've not taken the time to learn too much about UBoot). When UBoot finds these files, it loads them to RAM and starts executing the kernel.
Now the first thing the kernel is going to do when it starts up is to run the program 'init.' Init performs all the necessary stuff to start the system as you know it. Part of what init does is run a script called 'init.rc.' This script does a lot of things, but an important part of what it does is mount all these partitions.
So all we have to do to run the device off an SD card is to get UBoot to use the UImage and URamdisk from the SD card instead of internal memory! It turns out that this has actually been done before. This method is exactly what touchNooter did to root our nooks. Of course, it was created with other things in mind.
What I did was burn an exact copy of the nook's internal memory to an SD card, but then took the files from the touchNooter image that make UBoot work, and copied them over to the boot partition of the SD card. I'm not sure that you have to copy all the files I did, but anyway here's the ones I took from touchNooter:
u-boot.bin
cfg.bin
boot.scr (This is essentially a UBoot script that tells it what to do with UImage and URamdisk to set up the rootfs and start the Kernel)
I also made all of the boot images black so I would be able to tell if the nook was using the SD card.
When I stuck the SD card in and rebooted, lo and behold, the screen went black all the way through the boot process. It worked! The only issue is, it turns out that init and init.rc are somehow loaded into the UImage or URamdisk, so when init runs, it still mounts the partitions that are on the nook's internal storage. From this, we can deduce that the only thing running from the SD card is the kernel, and everything else is as before.
The solution to this is to recompile the UImage and URamdisk using B&N's provided source with an edited init.rc to mount the SD card's partitions. Another way we could do it is to somehow edit 'boot.scr' to make UBoot to pass an argument to the kernel when it gets started to use a different, modified init. (Much like pushing `esc` on a linux bootscreen and typing init=<binary>)
The first solution is harder but more correct, while the second solution is easier but much more hackish.
I am somewhat new to UBoot so I would appreciate it if someone else could correct any inaccuracies I may have made.
klausef said:
The solution to this is to recompile the UImage and URamdisk using B&N's provided source with an edited init.rc to mount the SD card's partitions.
Click to expand...
Click to collapse
You can easily unpack/edit/pack URamdisk
mali100 explained everything and posted scripts here. I’m reposting his scripts below:
Unpack (xuramdisk)
Code:
#!/bin/bash
#if (test $# -eq 1 && -f $1)
if [ -f $1 ]; then
dd if=$1 bs=64 skip=1 of=rdisk.gz
# Uncompress
gunzip rdisk.gz
# Extract
mkdir ramdisk
cd ramdisk
cpio -iv < ../rdisk
else
echo "No Ramdisk found"
fi
pack (mkuramdisk)
Code:
#!/bin/bash
find . -regex "./.*"| cpio -ov -H newc | gzip > ../ramdisk.gz
mkimage -A ARM -T RAMDisk -n Image -d ../ramdisk.gz ../uRamdisk
klausef said:
-snip-
Click to expand...
Click to collapse
That's great! Even as you have it right now, this could be a great way to test new kernels!
Googie2149 said:
klausef said:
-snip-
Click to expand...
Click to collapse
That's great! Even as you have it right now, this could be a great way to test new kernels!
Click to expand...
Click to collapse
If nook doesn’t boot, but respond to shutdown button still,
you can replace uImage or uRamdisk on nook internal SD by booting from noogie (well known fact)
or removing external SD card.
Otherwise (nook doesn't respond to shutdown button - semi-bricks)
you need to open it and disconnect battery or wait till it got discharged completely
And you may need to pop nook open to start it charging again in some cases
Either way, I don’t see how booting from external SD card helping much with kernel testing.
Am I missing something obvious?
I use my Nook to read textbooks for all my classes so I cannot afford to experiment through the internal memory.
At any rate, digging around the forum it turns out that people have known this for a while (OP even mentioned it in the first post), so I apologize for the bulk of that post.
I tried editing the init.rc to mount the SD card's partitions (replaced all /dev/block/mmcblk0 with /dev/block/mmcblk1) and it seems to just hang. ( I made sure to wait a long time to make sure it wasn't just lagging from the speed of the card reader, although I may not have waited long enough... )
This lead me to believe that the card reader is not initialized yet. To test this hypothesis I edited init.rc back to something that worked, but this time added `ls /dev/block/ > /data/blocks` right after the data partition is mounted, to find out all the block devices the Nook sees at this point. Unfortunately, after the system starts up I found no file named 'blocks' in /data/blocks.
EDIT: Found the culprit! After boot, I looked at dmesg:
Code:
init: /init.rc: 19: invalid command 'ls'
So we can't use `ls` for this. No problemo, I'll just pack busybox into the uRamdisk and use `ls` from there.
klausef said:
I use my Nook to read textbooks for all my classes so I cannot afford to experiment through the internal memory.
At any rate, digging around the forum it turns out that people have known this for a while (OP even mentioned it in the first post), so I apologize for the bulk of that post.
I tried editing the init.rc to mount the SD card's partitions (replaced all /dev/block/mmcblk0 with /dev/block/mmcblk1) and it seems to just hang. ( I made sure to wait a long time to make sure it wasn't just lagging from the speed of the card reader, although I may not have waited long enough... )
This lead me to believe that the card reader is not initialized yet. To test this hypothesis I edited init.rc back to something that worked, but this time added `ls /dev/block/ > /data/blocks` right after the data partition is mounted, to find out all the block devices the Nook sees at this point. Unfortunately, after the system starts up I found no file named 'blocks' in /data/blocks.
EDIT: Found the culprit! After boot, I looked at dmesg:
Code:
init: /init.rc: 19: invalid command 'ls'
So we can't use `ls` for this. No problemo, I'll just pack busybox into the uRamdisk and use `ls` from there.
Click to expand...
Click to collapse
Wow sounds like your really making progress. Let me know if there is anything I can do to help.
klausef said:
So we can't use `ls` for this. No problemo, I'll just pack busybox into the uRamdisk and use `ls` from there.
Click to expand...
Click to collapse
Would it be easier to use cat? (this is not a snarky remark)
Wow sounds like your really making progress. Let me know if there is anything I can do to help.
Click to expand...
Click to collapse
Haha thank you but nah, most of the stuff that I have done is known. I'm mostly just trying to replicate and document what has been done as precisely as possible.
Would it be easier to use cat? (this is not a snarky remark)
Click to expand...
Click to collapse
I am not sure cat would work in this case since we are trying to get a directory listing of the directory /dev/block/, not concatenate or list two files.
Anyhow, it turns out that 'init.rc' is not a bash script, but instead uses the syntax described here: http://www.kandroid.org/online-pdk/guide/bring_up.html (See 'Android Init Language' section)
klausef said:
Anyhow, it turns out that 'init.rc' is not a bash script, but instead uses the syntax described here: http://www.kandroid.org/online-pdk/guide/bring_up.html (See 'Android Init Language' section)
Click to expand...
Click to collapse
Thats correct, but you can call your own bash script from it. Take a look on how clrbootcount.sh is called in the init.rc
Per the documentation I have invoked a script through init.rc. The script is very simple. I included a busybox binary in the uRamdisk at /busybox, so that's what it's based on:
Code:
#/busybox ash
/busybox ls /dev/block/ > /data/blocks;
I have verified that the script works by first running it on an up-and-running nook and it worked properly. (That is, it created a populated file in /data/blocks and then terminated)
The script is called through the init.rc right after it finishes mounting all the partitions:
Code:
service lsdev /lsdev.sh
oneshot
When I start up the nook with this init.rc it hangs on boot. I also tried calling the script using `exec` instead of `service` but it still hangs.
In other news, I noticed dmesg finds mmcblk1 (the SD card) around the same time it finds the internal memory. See this dmesg snippet:
Code:
<6>[ 22.080810] twl4030_rtc twl4030_rtc: setting system clock to 2012-04-15 00:48:42 UTC (1334450922)
<6>[ 22.090759] mmc0: new high speed MMC card at address 0001
<6>[ 22.096801] Freeing init memory: 164K
<6>[ 22.106384] mmcblk0: mmc0:0001 SEM02G 1.82 GiB
<6>[ 22.111450] mmcblk0: p1 p2 p3 p4 < p5 p6 p7 p8 >
<4>[ 22.238494] EXT2-fs warning: mounting unchecked fs, running e2fsck is recommended
<4>[ 22.321990] mmc1: host does not support reading read-only switch. assuming write-enable.
<6>[ 22.330841] mmc1: new high speed SDHC card at address 1234
[B]<6>[ 22.337280] mmcblk1: mmc1:1234 SA04G 3.67 GiB [/B]
<6>[ 22.342651] mmcblk1: p1 p2 p3 p4 < p5 p6 p7 p8 >
The Nook is failing to boot for some other reason than because it doesn't see the SD card. I previously assumed the opposite, which is why I've been going through this big init.rc exercise to verify it. (I was expecting not to see a /dev/mmcblk1p*)
It is my assumption that this has something to do with how the stock userland is set up, so I'm going to call it a day, then shift my focus to compiling a new kernel and userland instead of just aimlessly trying to get this one to run off the SD card.
Please don't let that doesn't discourage any of you from further contributing to this thread's original goal, because it would still be immensely useful to the development process.
Good day, all. Thanks for the help.

Categories

Resources