• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root Set CPU mistake.

nathanotis

Android Enthusiast
You ever done something and, while you're doing it, you think to yourself:

"This is a bad idea"

I just had one. I installed a netarchy kernal last night, then later I installed set cpu and under clocked my Evo a little. I set it to "set on boot"

This morning I decided to over clock for the sole purpose of seeing how long the battery would last... So I bumped it up to the max... It crashed, rebooted, crashed, rebooted. I can't change it to a more reasonable number now...

Totally my fault. No excuses. I knew it was dumb, did it anyway.

So... How do I fix it?
 
heh i've done this before too.

There's one thing you can do without blowing away your image with a NANDroid restore. It assumes you have adb working. You can manually uninstall SetCPU by removing the apk and associated files. Boot into recovery and connect your phone to your PC.

Open a command prompt and go to the folder where your adb executable is located. Type in:
Code:
adb shell
Then type in the following:
Code:
su
mount -o rw,remount -t yaffs2 /dev/block/mtdblock4 /system
cd /data/app
rm com.mhuang.overclock*
cd /data/data
rm com.mhuang.overclock*
cd /data/dalvik-cache
rm *mhuang.overclock*
exit
Now reboot, and SetCPU will be uninstalled. Reinstall it, and remember not to set it on boot until AFTER you've verified your settings won't bootloop your phone :)


-edit-
Actually, the above mount command may not work because nothing is actually mounted yet in recovery. So if that didn't work, try this instead:

mount /system

And I realize the OP is already back and running. Just thought I'd share this in case anyone ever runs into it. Seems like a common careless mistake.
 
There is also a zip file that you can flash that will override any setcpu settings on boot. I'm not quite sure where to download it though.
 
Removing the config file as outlined by novox is one way but also coolbho has enabled a safe mode. So if you simply drop a .txt named setcpu_safemode on the root it should boot ok into default then you can go change it, no recovery necessary
 
1) That's definitely creative novox :). That should work fine, but you probably don't want to remount /system as rw if you're just removing files from /data. That being said, if I'm not mistaken, if you want to remount /system as rw with adb, just run adb remount, first, then open your shell.

2) Evomattnc is right. That is how you get into safemode for setcpu. Just remember - don't actually give it a .txt extension :). It's text file, but it's what's called a "flag" file. It means it has no useful information, but it's presence means that an app has been designed to behave a certain way.

3) Adb actually provides a way to install/uninstall apps, already. If you have access to a remote shell of any kind, though, you can use the pm command install/uninstall apps. If you're interested, take a look at other stuff you can do with pm. You can disable/enable apps, for example.
 
1) That's definitely creative novox :). That should work fine, but you probably don't want to remount /system as rw if you're just removing files from /data. That being said, if I'm not mistaken, if you want to remount /system as rw with adb, just run adb remount, first, then open your shell.

2) Evomattnc is right. That is how you get into safemode for setcpu. Just remember - don't actually give it a .txt extension :). It's text file, but it's what's called a "flag" file. It means it has no useful information, but it's presence means that an app has been designed to behave a certain way.

3) Adb actually provides a way to install/uninstall apps, already. If you have access to a remote shell of any kind, though, you can use the pm command install/uninstall apps. If you're interested, take a look at other stuff you can do with pm. You can disable/enable apps, for example.


Oh yeah sorry thanks for clarifying the extension thing. Just "setcpu_safemode"
 
1) That's definitely creative novox :). That should work fine, but you probably don't want to remount /system as rw if you're just removing files from /data. That being said, if I'm not mistaken, if you want to remount /system as rw with adb, just run adb remount, first, then open your shell.

2) Evomattnc is right. That is how you get into safemode for setcpu. Just remember - don't actually give it a .txt extension :). It's text file, but it's what's called a "flag" file. It means it has no useful information, but it's presence means that an app has been designed to behave a certain way.

3) Adb actually provides a way to install/uninstall apps, already. If you have access to a remote shell of any kind, though, you can use the pm command install/uninstall apps. If you're interested, take a look at other stuff you can do with pm. You can disable/enable apps, for example.

heh, yeah when I first posted that, I thought it was a system app. then I went into my phone to get the actual folder names and didn't make the connection that the paths were not /system/*. No need to mount system rw for sure! And I didn't know about adb installing and uninstalling apps. definitely makes my solution way too complex for the task at hand. I tend to do everything from the command line, so I've lost touch with a lot of the convenience solutions to some of these problems!
 
heh, yeah when I first posted that, I thought it was a system app. then I went into my phone to get the actual folder names and didn't make the connection that the paths were not /system/*. No need to mount system rw for sure! And I didn't know about adb installing and uninstalling apps. definitely makes my solution way too complex for the task at hand. I tend to do everything from the command line, so I've lost touch with a lot of the convenience solutions to some of these problems!

Hehe, oh I totally hear ya. I can't tell you how many times I've wasted a bunch of time doing something, just to find out I could have done it a much simpler way. As anyone who uses the command line a lot know, there are a bazillion ways of doing something. That being said, had it been any other app that doesn't have a built-in safe mode, and it was a system app, your solution actually would work great. There might be better ways of removing data (like the pm command), but it certainly is a good thing to know for such a situation.
 
I have a question for you guys while on the subject of setCPU (and if this is common knowledge than forgive me), it seems that my phone boots with setCPU on, while the check mark is not checked. I have a couple of profiles set up (temp, screen off, etc.). Is it normal for setCPU to active these profiles when it boots, or does the 'set on boot' only appy to the "main" tab?

Thanks.
 
I have a question for you guys while on the subject of setCPU (and if this is common knowledge than forgive me), it seems that my phone boots with setCPU on, while the check mark is not checked. I have a couple of profiles set up (temp, screen off, etc.). Is it normal for setCPU to active these profiles when it boots, or does the 'set on boot' only appy to the "main" tab?

Thanks.

"Set on Boot" is for the main profile, which is what you see in the first tab. It is what is activated if none of the conditions of other profiles are met. If you have profiles, and the "enable" option is checked, profiles will always be set to work if the conditions are met, regardless of whether or not you have "set on boot" checked in the main tab.
 
Been there done that, only times I've boot looped my EVO were doing exactly what you described in the first post. Hopefully you're smarter than me and learn your lesson the first time... haha

I need a "set 5 minutes AFTER boot" option.
 
"Set on Boot" is for the main profile, which is what you see in the first tab. It is what is activated if none of the conditions of other profiles are met. If you have profiles, and the "enable" option is checked, profiles will always be set to work if the conditions are met, regardless of whether or not you have "set on boot" checked in the main tab.


Ahhh thanks. I completely missed the 'enable' on the profiles tab.
 
Been there done that, only times I've boot looped my EVO were doing exactly what you described in the first post. Hopefully you're smarter than me and learn your lesson the first time... haha

I need a "set 5 minutes AFTER boot" option.

Wow, you've never flashed a kernel that didn't work with a given ROM? Tried to manually theme an odex ROM? Apply a .zip made for 2.2 on a 2.3 ROM forgetting that it only worked for 2.2? Accidentally erased sh trying to get bash to work so the phone had no shell?

I guess I'm just a bonehead :)
 
Wow, you've never flashed a kernel that didn't work with a given ROM? Tried to manually theme an odex ROM? Apply a .zip made for 2.2 on a 2.3 ROM forgetting that it only worked for 2.2? Accidentally erased sh trying to get bash to work so the phone had no shell?

I guess I'm just a bonehead :)


Nah youre just like me, a tinkerer with no fear lol. :D
 
Removing the config file as outlined by novox is one way but also coolbho has enabled a safe mode. So if you simply drop a .txt named setcpu_safemode on the root it should boot ok into default then you can go change it, no recovery necessary


how, exactly, do you do this? I got stuck in a boot loop somehow or other a few times with this and then i saw and flashed the safemode thing but i can't figure out how to do this flag.

Help! :confused:

Too, assuming I figure out how to do this, how will the behavior of setcpu be different if I screw up?
 
Ive overclocked mine way to much on numerous roms now... no big deal. What i do is pop the battery out ....put it back in/power on. As soon as it reboots you have a few seconds to get back into Setcpu before the phone recognizes the overclocked setting and readjust it. No need to restore.
 
Ive overclocked mine way to much on numerous roms now... no big deal. What i do is pop the battery out ....put it back in/power on. As soon as it reboots you have a few seconds to get back into Setcpu before the phone recognizes the overclocked setting and readjust it. No need to restore.
I didn't have time for squat, got stuck 'Loading' and then rebooted. Ha!

I had to pull the battery and restore. :(

A couple of times, actually, still don't know what I did wrong.
 
Ive overclocked mine way to much on numerous roms now... no big deal. What i do is pop the battery out ....put it back in/power on. As soon as it reboots you have a few seconds to get back into Setcpu before the phone recognizes the overclocked setting and readjust it. No need to restore.

If you have it checked for "Set on boot", you likely will not get to it before it boots again. I had it happen before when I was first using kernels, not easy to get out of without restoring a nandroid or using adb to fix it.
 
Okay, I'll try to explain what evomattnc said with this...

"Removing the config file as outlined by novox is one way but also coolbho has enabled a safe mode. So if you simply drop a .txt named setcpu_safemode on the root it should boot ok into default then you can go change it, no recovery necessary"

Basically, you open notepad and make a file called setcpu_safemode. Okay? Then, it will default to a .txt extension. If you keep that, it won't work, but you can just remove it. Otherwise, it notepad change the 'Save As' option to allow an extension, then just don't give it one. That should work.
Or try notepad++ or programmers notepad, those should both have options for extension-less files.
 
Back
Top Bottom