yashsingh1/xdaforums huggingface dataset:
[Epic 4G Android Development] tanimn:
Not to worry. There are actually 2 scripts that can be used on the handset side, odex.sh and OdexOne.sh. They both perform the same functions as far as odexing and restoration, but odex.sh also allows you to clean the /sdcard/odex folder. Since it requires interaction it is not compatible with the 'One Click' model, which is why OdexOne.sh was made.

Either script can be run from the handset without a pc, as long as the contents of the odex folder from the zip are in /data/local/tmp .

My boot time went from 49 seconds to 42 seconds, as measured from button press powered off to lockscreen after at least 2 boots. Time to logo alone went from 15+ to 12.5 seconds. Those numbers amount to about 15% faster load time.

10-15% performance improvement is an oft quoted reason for factory odexed roms, with at least a few citations here on xda alone.

This is what I would like to get a logcat of. A list of any mods or even a geneology of what mods, roms, and backup/restore's you've applied would go a long way to figuring out what's going on here.
[Epic 4G Android Development] MysteryEmotionz:
All the power options should be there although it says reboot only

Haterz gonna hate. Just keep hatin. I brush them haterz off. It ain't my fault my epic's e-penis is bigger then the evo's e-penis.
[Epic 4G Android Development] Gersonian:
Ok so it actually didn't work, it was just free memory from reboot

Still, I think this deserves a sticky. Does this only work on 2.1?
[Epic 4G Android Development] BeerChameleon:
Nope just the reboot :( is the asop lockscreen have all of them or do u have another file maybe?

Sent from my awesome epic 4g
[Epic 4G Android Development] BeerChameleon:
No as stated in op says work on d118 or dk28 roms :)

Sent from my awesome epic 4g
[Epic 4G Android Development] MysteryEmotionz:
Are you using my theme. My theme is the only theme with all the power options built in. in order to have the power options you need my theme and lock screen. I suggest one of the final builds with your choose of animations and lock screen. In order ro have all the power options its either my theme or stock. If you want the a stock theme look for raidereps thread

Haterz gonna hate. Just keep hatin. I brush them haterz off. It ain't my fault my epic's e-penis is bigger then the evo's e-penis.
[Epic 4G Android Development] yogi2010:
how can tell you tell if your system is odexed after restoring a nand backup? i can never get the phone to reboot on it's own, and phone completely freezes... i try running the script again but it goes nowhere.... so now i'm restoring the nand.

tanimn: i'm running a practically naked Syndicate 1.0.2 rom w/xtreme kernal 1.2.0. the last item processed successfully is wlan, then the script hangs at "# #'. pretty much same thing happened on Viper 4.0.3 ext4.
[Epic 4G Android Development] readermo:
Please forgive my ignorance. I'm not familiar with logcat.

here's what i've got running:

bonsai 2

gingerbread 1.5 theme with flying transitions 1.8

epic blue man battery mod

aosp lockscreen (or, as i am wont to call it, aesop's lockscreen)

all nand backed-up (or possibly backupped)

ran the odex tool

smooth run. no hiccoughs.

phone rebooted.

got to samsung screen.

hung.

reboot to samsung screen.

wash, rinse, repeat, ad infinitum.

restored nand.

everything works great, but i'm not odexed.

i'm happy to provide a logcat. i'll do a search and figure out what it is.
[Epic 4G Android Development] Gersonian:
Go to your sd card on astro or a file explorer and see if anything is in the odex file. I actually realized there is nothing in mine, so apparently it didn't work.
[Epic 4G Android Development] Gersonian:
Doh! I will read better next time. Looks like I will have to give it another shot, or try the manual method.
[Epic 4G Android Development] tanimn:
Are you interacting with the screen at all while the script is running? closing fc notices and whatnot? The files that would affect booting are all jars, by the time it says it has processed WlanTest.apk successfully, the script is literally seconds from issuing the reboot command. Sometimes that command can take a minute or two to take hold, but I've never actually seen it fail when called.

Thanks, I'll try to emulate your setup and see if I can't reproduce this.

for a logcat: open a command prompt, cd to the directory you extracted the zip and go into the adb folder.

Unplug you phone from the usb and power it off.

Type adb logcat > logcat.txt<ENTER> on your computer.

Plug your phone into the usb cable, power it on, and let it do it's thing.

When the prompt comes back on the computer, open the logcat.txt file and paste it somewhere like pastebin.com, then bring that link back here.
[Epic 4G Android Development] sniperkill:
You know, it was kinda funny to me! I was real timid about running this script, so I was doing constant research about how to run the script and from where. I would never have thought that it was sooo easy, lol... I figured out that if you have "Root Explorer", all you have to do is copy the contents of the odex file to /data/local/tmp and after you do that, just select the folder called odex.sh and select "execute"! It did its thing, rebooted, and that's it! No adb from a pc, no terminal emulator, just root explorer!
[Epic 4G Android Development] yogi2010:
Cool! How did you copy the contents of the odex folder into the tmp folder using Root Explorer? Can you just select 'copy' for the entire odex folder, and then paste the contents, or do you have to open the odex folder and copy from within?
[Epic 4G Android Development] BeerChameleon:
Ok ran it the first time and it seemed to work, however

i ran into market force closing on every app when i try to view the app in the market. Also tried downloading a file off the internet and it forced closed on me as well. :( im going to try it again.

And no mystery im not using ur theme, i knew that i had to use your theme to get all power options, however i used your lock screen to get the reboot on any theme.
[Epic 4G Android Development] MysteryEmotionz:
The edits to get all the power options are in the framework-res.apk also. 90% of the theme is done in there. In order to have all the power options you need to either be using my framework-res.apk or the one posted by raiderep. The rest of the mod is controlled by 3.jar files that my lock screen consist of. Stock framework-res.apk has reboot already in just not the other changes for the other options. This is why you will get the reboot option using my lock screens on other themes

Haterz gonna hate. Just keep hatin. I brush them haterz off. It ain't my fault my epic's e-penis is bigger then the evo's e-penis.
[Epic 4G Android Development] sniperkill:
You gotta open the odex folder, then select ALL its contents and copy everything to /data/local/tmp and paste everything in there... then select odex.sh, and a window will pop up asking if you wanna execute the script, and just select execute. That's all I did and it worked perfectly!
[Epic 4G Android Development] SINNN:
Wheres the odex folder?
[Epic 4G Android Development] dreamsforgotten:
In the zip file your downloading.
[Epic 4G Android Development] yogi2010:
i was excited to have followed those steps, doing it all on the phone, and to execute the odex.sh.... but how long did the process take for you? mine is going on almost 15 minutes with it saying it's executing the script file. hopefully it will finish and i can edit this post....
[Epic 4G Android Development] formula84:
So just ran this during the process i got force closes on the phone, it rebooted and said it competed. Now though I get com.adriod.phone process terminated and I dont have a phone app anymore.... should i restore my backup and start over or try something else?
[Epic 4G Android Development] musclehead84:
Anyone noticing any speed increases. Not just on the phone boot time cause.that is faster but on use?

Sent from my Evo Killer!!!
[Epic 4G Android Development] formula84:
I would say ram usage reduction is reason enough even if there is no speed difference.
[Epic 4G Android Development] formula84:
Okay so I restored and retried same thing with the phone missing and getting a force close... any ideas i would really like this to work seems to be the only issue...

I am on Midnight v3 which is based on Bonsai v2 and I am running TimberWolf671 Blue Glass v2 theme...(Great theme BTW)
[Epic 4G Android Development] sniperkill:
I don't know what could be goin wrong, but mine took about 5 to 7 minutes. I didn't et any errors at all, and no FC's... I'm running midNIGHT rom v3 w/v3 midNIGHT's theme.. I just ran the ool right from root explorer...

@yogi2010, did you get it figured out? Its very easy to just run it from root explorer. I just tried it again and it worked flawlesly!! So if your still having problems, it might be the theme. I'm using midNIGHT's v3 theme with the blue circle batt...
[Epic 4G Android Development] yogi2010:
sniper: i tried it again on a different rom with stock theme, and it still wouldn't finish, after 10 minutes or more. BUT, i ran the one-click again using the computer, and had better luck than i was having before..... this time the phone still wouldn't reboot autmatically at the end, and the phone was frozen. but this time when i yanked the battery and rebooted, everything booted up fine. and now i have have 443 free MB internal, whereas i had around 403 before..... so i think it did work!!
[Epic 4G Android Development] sniperkill:
Well one way you can check to see if it worked is to open root explorer and go under system/app and see if you have a odex files under your usual apps. Also look on your sdcard and see id you have a odex folder there with a bunch of files in it..
[Epic 4G Android Development] yogi2010:
yeah, sure do, both. it worked :)
[Epic 4G Android Development] SINNN:
Oh I c. So if the apps show a odex file, then u dont need to run this right?
[Epic 4G Android Development] BeerChameleon:
Bump....

Anyone else get force closes on market and downloads

Sent from my awesome epic 4g
[Epic 4G Android Development] rocket321:
If you nand backup deodexed files, then restore the nand your gonna have deodexed files. It doesn't matter what you did in between. You could run the script 12 times but once you nand restore you are back to whatever state you had when you made the nand backup. Hope this helps, I see many questions in this thread not seeming to understand this concept.
[Epic 4G Android Development] sniperkill:
Well i'd atleast run it once. What, did you haveodex files in system/app before you ran the script? And not all apps in there will have an odex file to go with it, just most of them will...
[Epic 4G Android Development] SINNN:
Pretty much almost all the apps have a pair odex file. I initially odined the regular 2.1 build. Not the deodexed version from this site. I should be ok right?
[Epic 4G Android Development] thehustleman:
Well, I have tried this several times and always end up in a loop at the Samsung screen and I have to restore from nandroid. However, the odex folder contains the apk and associated odex files. Can I copy them to the system/app folder to complete the process?
[Epic 4G Android Development] formula84:
Bump... i Took the original phone.apk from the SD card and replaced with root explorer and rebooted... same force close....removed the odex file and rebooted same force close, restored from nand backup and back to square one hoping someone has an answer... I can post the before and after apk's with the odex file if it could help.
[Epic 4G Android Development] sniperkill:
No, I don't think that would work as a odexed rom. Try wiping data/cache/dalvik 3 times each in cwm3, assuming you have DK28, flash midNIGHT v3, then flash all the mods your gonna want. Then do a nandroid backup, then download the oneclickodex.zip to your sdcard, then using root explorer, unzip it and it will automatically get transfered to a extracted folder. Then go to the extracted folder and open up oneclickodex folder and navigate to the odex folder and open it up, there should be 7 or 8 files in it, so multi select/copy those files (do not "move" them) and go to data/local/tmp and paste the files in there. Then click the folder named OneOdex.sh and select execute from the window that pops up. It should run from there and auto reboot. Is this how you did it?

@Formula84, did you check to see if the odex folder in your sdcard to see if it had files in it? If your unsure your system is odexed, try what posted above to see if that works... it installed for me just by using root explorer... also, I'm on midNIGHT v3 with v3 of midNIGHt's them, with ext4 and cwm3.0.0.5 no journeling...
[Epic 4G Android Development] sniperkill:
Also, your system MUST be deodexed before you run this script, if I'm not mistaken...
[Epic 4G Android Development] thehustleman:
When I tried it that way the script was executing for more that 30 minutes so I stopped root explorer from running. Then there were no files in the odex folder. The initial results were achieved by running the batch file from the pc.
[Epic 4G Android Development] tanimn:
Sorry about the delay in replying. The lineman just left after fixing (hopefully) the dsl.

Unfortunately, after a nand restore you need to clear the /sdcard/odex folder, otherwise your original framework will be "restored" when the script is run. You can either clear the /sdcard/odex folder by hand, or run odex.sh and chose to clean the folder. I'm putting together a fix for that behaviour right now, but it requires a change in how files are stored and I'm making sure the upgrade scripts work right.

I think I'll have to enable clearing the entire dalvik-cache. This will slow down the initial boot time, but hopefully not by too much. It appears that some apps, even though not being odexed themselves, are maintaining dependencies to stale cache references.

What platform are you running this from (Win/Linux/Mac), and what are the last 2 lines of text before it stalls?

Run the script again to return your phone to it's origional state. If you restore from a backup, remove the /sdcard/odex folder before running again. See above.

The files stored in the /sdcard/odex folder are not compatible with each other, they are snapshots of different stages of the process. See above.

Please, the deodexed (before) phone.apk would be helpful.
[Epic 4G Android Development] formula84:
I did manually clear the folder before nand restore...

I will attach the files in a bit, also I will try the sniper way via root explorer and see if there are any other results....Thanks

edit: here they are, could it be a dependency of phone and not the phone.apk itself?
[Epic 4G Android Development] BeerChameleon:
Sweet I can't wait for the update why I wait, what ur saying is if I clear the dalvik cache it may work? I think I cleared the regular cache but not that one..

Sent from my awesome epic 4g
[Epic 4G Android Development] BeerChameleon:
Ok so after trying to put the old market that was working and browser that was working, still get force closes after using this. I now wiped dalvik cache and regular cache and see if that resolves the problem. if not i guess im going to have to wait for an update of this.

Its a bummer so close to working on my phone:

Except market everytime i click an app it force closes.

Browser click a link to download it force closes.

Otherwise everything works great, on Noobnls Andromeda Galaxy Rom & Kernal.

Edit: still not working even when i wipe all cache :(

Oh well, time to go back to my stock rom with theme, like i was doing before, ill have to wait til this is able to work. :(

Thanks for all your hard work i feel like a few minor tweaks would fix this, :)

im going to attach the browser,download provider,market,market updater apk, so u can look at them and see whats up why im getting force closes.
[Epic 4G Android Development] BeerChameleon:
@tanimn any news on an updated version of this, I would love yo be able to have mobile AP and reboot option on a custom rom, I've tried everything to get thus to nit force close my market it browser and still does, ill be patient, no hurry just wondering the status of a fix for these,

Thanks

Sent from my awesome epic 4g
[Epic 4G Android Development] dreamsforgotten:
I hope someone can confirm this but I dont think mObile ap works on froyo regardless of deodex. Not sure if you are running 2.2 or not
[Epic 4G Android Development] thomasskull666:
I've tried, it doesn't work.

Sent from Carl Sagan through the Cosmos
[Epic 4G Android Development] lviv73:
Someone should try odexing Syndicate(minimal version) so we could use MobileAP on it,this is tje only thing thats holding me back from up "Upgrading" from froyo to 2.1 Syndicate.
[Epic 4G Android Development] BeerChameleon:
I'm not talkin about froyo I'm talking about 2.1....

Sent from my awesome epic 4g
[Epic 4G Android Development] dreamsforgotten:
Just checking cause I had my hopes up at first
[Epic 4G Android Development] gtuansdiamm:
Will i lose my theme if i use this
[Epic 4G Android Development] BeerChameleon:
Nope sure wont :)

Sent from my awesome epic 4g
[Epic 4G Android Development] BeerChameleon:
Jr and btthomas are working on it however I don't think we see any progress unless we disable sprints authentication or we have the 2.2 source or the developer of wireless tether comes out with that thing he us working on for the epic.

Sent from my awesome epic 4g
[Epic 4G Android Development] formula84:
One typo that's causing others that try this way to hang on executing script... You need to execute, OdexOne.sh , not odex.sh ....

I still have problems with the com.android.phone process force closing. Shame as I saw 30 extra meg of free ram.
[Epic 4G Android Development] tanimn:
Both scripts contain the same functions, but odex.sh takes user input to select what it will do, and has the additional ability to clean the /sdcard/odex folder.

I'm trying to track down the fc and boot issues now, but it's slow going when every step says everything went just fine... :(
[Epic 4G Android Development] formula84:
Only problem I had was with com.Andriod.phone, any chance you have had a chance to check out the files I posted earlier... other than that it was great. I was thinking maybe it's a dependant apk that's not getting Odexed? Or the process is failing with that apk. .. not sure which apks to look at. Strange thing Is even after putting the original apk back problem was still there until nand restore. Maybe replacing just the phone. Apk with original was not enough, should I have also put other related apks back? If so which ones?
[Epic 4G Android Development] lloydcabraham:
How much free ram do you need to run this? I currently have about 50m free and can't seem to get this to run.
[Epic 4G Android Development] raiderep:
Try replacing phone, contacts and dialertabactivity apks, I may have the names off a bit and it may not help but its worth a try...

sent by an Epic4g through the cosmos

Edit: phonecrashnotifier,phoneerrservice and phoneinfo are also related...forgot them
[Epic 4G Android Development] BeerChameleon:
Sent from my awesome epic 4g
[Epic 4G Android Development] Mk4UmHa:
What do you mean you nand backup after you odexed? You mean you restored your original backup after odexing? and now your phone is odexed?

My phone is now stuck at samsung and i am going to restore my nand backup. Will it be the original one or is it going to odexed?
[Epic 4G Android Development] formula84:
It will be original at the time you took backup your rom was de odexed it will be that way after restore
[Epic 4G Android Development] yogi2010:
Unfortunately not having much luck odexing over here.... phone freezes and doesn't reboot, then after battery pull hangs at Samsung screen nearly every time. Right now on Syndicate 1.0.2 w/Phoenix kernel...

I'll keep an eye out for updates, and thanks for this tool!
[Epic 4G Android Development] sniperkill:
Thankx for the heads up bro! It's fixed...
[Epic 4G Android Development] yogi2010:
it looks like i might have solved my problem.... i just successfully odexed my system. this time, when the phone froze at the end, instead of yanking the battery, i restarted the phone by pressing volume up-camera-power..... the phone rebooted nicely and system was odexed!
[Epic 4G Android Development] k0nane:
Thanks for the feedback! Glad you're enjoying tanimn's hard work (and another fine ACS production ;)).

Testing is in progress for Eclair support, for anyone who prefers DI18 builds.
[Epic 4G Android Development] yogi2010:
Lol, cool man! I tried the script on both Froyo and Eclair roms, and didn't notice any difference.... should I not have been using it for Ecair? The success I had above was on Baked Snack 1.6.
[Epic 4G Android Development] k0nane:
There have been mixed results. If it worked for you, great!
[Epic 4G Android Development] BeerChameleon:
I look for the eclair testing update, cause I had no luck, makes some stuff force close... ill have to see what comes first this or the hacked sprint hotspot so I can have mobile so either way...

Sent from my awesome epic 4g
[Epic 4G Android Development] k0nane:
The Sprint version probably won't be coming to DI18 - but keep an eye on progress here.
[Epic 4G Android Development] yogi2010:
yes, thanks. i did some more messing around(had too much time on my hands yesterday :o), and i was able to successfully odex Baked Snack 1.6 again.... phone froze but once i manually reboot, THEN the script dialogue box says 'wait for phone to reboot', etc etc. could not however, successfully odex Syndicate Shuriken.... hangs at Sammy screen on reboot.

anyway, thx for everything. threw Taninm a donation last nite :)
[Epic 4G Android Development] k0nane:
Thanks for your support!

Would you mind PMing tanimn or I a logcat from the boot process? SyndicateROM should have debugging enabled by default, so you should be able to connect to ADB on boot.
[Epic 4G Android Development] yogi2010:
ok no problem.... I'm gonna get set up with ADB as soon as I get home today. I've managed to get by without really knowing what it is so far, but it sounds like I need to learn it if I wanna get more into this and be able to help out developers.
[Epic 4G Android Development] rjmjr69:
Any new items wanted in the next release?

I call for it to check what roms installed and if its known to cause issues for the script to stop and warn the user....
[Epic 4G Android Development] BeerChameleon:
Not so much items just a fix for force closes on certain apps...

Thanks

Sent from my awesome epic 4g
[Epic 4G Android Development] tanimn:
Version 1.2 Beta 3

This version should address some issues with boot loops and fc's, although it might not reach the automatic reboot when run (thus BETA). Since the stops are not happening during the actual odex/restore routines, I figured those in need could make use of it while I finish polishing this version.

REQUIRED: NANDROID BACKUP! It's no longer a recommendation. Although this method has proven benign on every other handset that has put it to use, our epic's chose to stand outside the crowd yet again by somehow screwing up this process sometimes.

RECOMMENDED: Put your phone in airplane mode before running. Besides making the script run faster, this reduces the risk of a background task interfering with the process, and allows the script a more consistent environment to work in.

UPDATING: There is an update folder included with this version. This version of the script stores files differently than verison 1.0. If you have a currently odexed system from the version 1.0 script, please run the appropriate script from the update folder before using this version.

TO-DO: Get permission fixing running again on restore. Update odex.sh to allow running of permission fixing independant of other functions. Update odex.sh to allow granular control over what is odexed (minimal, standard, full monty, etc...).

Full changelog with the RC, until then:

Version 1.2 BETA 3