[MOD][SCRIPT] Kernel Cleaner Script & SuperWipe Script

Search This thread

...Awesome...

Inactive Recognized Developer / Retired Forum Mod
Jul 10, 2010
3,266
7,243
Chicago
plus.google.com
Mods: If in wrong section feel free to move.

1346283476.png

I have decided to post the wipe scripts here for those KernelHolics & Flashaholics that are flashing kernels and ROMs constantly. I've made small modifications to these scripts FULL credit to the originator of them Credits below.

These are compatible with CWM, TWRP.

Since there have been numerous kernels recently being posted and people wondering what to wipe or what not to wiped here is the Kernel Cleaner.

1. Place the file in the root of your /sdcard
2. Flash Kernel Cleaner
3. Flash/Fastboot Kernel
4. Reboot.

Download: http://d-h.st/IOn

This second script I'm sure everyone is familiar with SUPERWIPE script.

Tired of wiping after every ROM or not knowing what to wipe to flash a ROM and have a clean install? Just flash this script & flash ROM easy right?

This version Deleted System, cache, data, formats device & INTERNAL SD CARD DATA!

1. Place Wipe-Script in root of /sdcard
2. Flash Wipe-Script
3. Flash ROM
4. Reboot.

Download: http://d-h.st/L31

This version is SUPERWIPE/NO INTERNAL SD DELETED!

http://d-h.st/476
SuperWipe deletes System, Cache, Dalvik, Formats Device!

DOES NOT TOUCH INTERNAL DATA SDCARD

Debug​

If it doesn't flash please tell me what recovery your using.

ONLY works for the NEXUS 4 ONLY will be available for other devices as well.

Credit goes to the following people.​

Mike1986
AmazingLarry31
Jivy26
I-777
Myself

IF YOU USE/DOWNLOAD THIS SCRIPT PLEASE PRESS THE THANKS BUTTON​
 
Last edited:

...Awesome...

Inactive Recognized Developer / Retired Forum Mod
Jul 10, 2010
3,266
7,243
Chicago
plus.google.com
The script cleans the left over files of a kernel, to prevent issues or compatibility problems when switching between kernels, kinda like Ccleaner for windows.
It does a cache wipe / dalvik cache wipe and a few other operations, basically it does the maintenance job for you, no need to manually do those tasks before flashing a new kernel.

Kernel Cleaner Operations performed:

Formatting cache partition

Wiping Dalvik-Cache

Deleting old kernel files

Cleaning up old Modules

Formatting cache for Security Purpose

Wiping Dalvik-Cache for Security Purpose
---++
We all know what SuperWipe Cleans everything but storage/sdcard
 
  • Like
Reactions: dhruvmalik

siloner

Senior Member
Jun 29, 2011
1,550
276
Chicago
Nice to see you here. I'll for sure be using this. Now go get the N4 and start with the ROMs!

Sent from my Nexus 4 using Tapatalk 2
 

siloner

Senior Member
Jun 29, 2011
1,550
276
Chicago
Sweet! So that means you got it or deving blind?

And to stay on topic. From my understanding this will keep me from having to flash a neutral kernel in between flashes right?

Sent from my Nexus 4 using Tapatalk 2
 

...Awesome...

Inactive Recognized Developer / Retired Forum Mod
Jul 10, 2010
3,266
7,243
Chicago
plus.google.com
Sweet! So that means you got it or deving blind?

And to stay on topic. From my understanding this will keep me from having to flash a neutral kernel in between flashes right?

Sent from my Nexus 4 using Tapatalk 2

I was lucky to get the device in the first wave just been updating my threads on other devices and finally got around to building for this device....

Yes flashing the Kernel Script will save not only you but kernel devs from debugging bug reports that are usually caused by "dirty" flashing a kernel.

Sent from my HTC One S using Tapatalk 2
 

Vangelis13

Senior Member
I was lucky to get the device in the first wave just been updating my threads on other devices and finally got around to building for this device....

Yes flashing the Kernel Script will save not only you but kernel devs from debugging bug reports that are usually caused by "dirty" flashing a kernel.

Sent from my HTC One S using Tapatalk 2

What about the ram disk? Flashing any other kernel on top of Franco's seems to cause bootloops because he's modifying it.
 

...Awesome...

Inactive Recognized Developer / Retired Forum Mod
Jul 10, 2010
3,266
7,243
Chicago
plus.google.com
What about the ram disk? Flashing any other kernel on top of Franco's seems to cause bootloops because he's modifying it.

Yes the bootloops happen because when u flash a new kernel it over writes the previous kernel/modules files and it doesn't remove no files. The kernel cleaner does remove the files and init.d support for the kernel.

You can't flash a different rom on top of another ROM can you? Without having issues? Why would you flash a kernel on top of another without removing the previous kernel files and having a clean kernel install.

Sent from my HTC DNA using Tapatalk 2
 

siloner

Senior Member
Jun 29, 2011
1,550
276
Chicago
Just used the wipe to go from Franco to Harsh kernel and got stuck on Google screen

Sent from my Nexus 4 using Tapatalk 2
 

Vangelis13

Senior Member
Yes the bootloops happen because when u flash a new kernel it over writes the previous kernel/modules files and it doesn't remove no files. The kernel cleaner does remove the files and init.d support for the kernel.

You can't flash a different rom on top of another ROM can you? Without having issues? Why would you flash a kernel on top of another without removing the previous kernel files and having a clean kernel install.

Sent from my HTC DNA using Tapatalk 2

One would normally have to flash the rom to restore the ramdisk and then the new kernel when coming from Franco's; does the script take care of that? That's all, no blaming.

Whether one can flash roms on top of other roms and kernels on top of other kernels without wiping anything, yes, that does happen a few thousand times daily without any problems. Is it better to use your script in between however to avoid possible issues? Probably yes. :good:
 

gothvell

Senior Member
Jan 17, 2010
109
4
Kernel Cleaner​


ui_print(" ");
ui_print(" ");
ui_print("");
ui_print("");
ui_print(" A w w eeee ssss oooo m m eeee ");
ui_print(" A A w w w e s o o m m m m e ");
ui_print(" A A w w w eeee ssss o o m m m eeee ");
ui_print(" AAAAAAA w w w w e s o o m m e ");
ui_print("A A w w eeee ssss oooo m m eeee ");
ui_print("");
ui_print("");

mount("ext4", "EMMC", "/dev/block/mmcblk0p22", "/cache");
mount("ext4", "EMMC", "/dev/block/mmcblk0p23", "/data");
mount("ext4", "EMMC", "/dev/block/mmcblk0p21", "/system");


show_progress(0.100000, 0);

ui_print(" ");
ui_print(" ");
ui_print("Deleting Cache and Dalvik-Cache...");

delete_recursive("/cache");
delete_recursive("/data/dalvik-cache");


show_progress(0.100000, 20);
show_progress(0.100000, 40);

ui_print(" ");
ui_print(" ");
ui_print("Removing old kernel files...");

delete_recursive("/system/etc/init.d");
delete("/system/lib/hw/lights.default.ko");
delete("/system/lib/hw/sensors.default.ko");
delete("/system/bin/logcat-on");
delete("/system/bin/logcat-off");


show_progress(0.100000, 60);

ui_print(" ");
ui_print(" ");
ui_print("Deleting Cache again just to be safe...");

delete_recursive("/cache");

show_progress(0.100000, 70);
show_progress(0.100000, 80);

ui_print(" ");
ui_print(" ");

ui_print("Deleting Dalvik-Cache again for safe measures...");

delete_recursive("/data/dalvik-cache");

show_progress(0.100000, 90);

ui_print(" ");
ui_print(" ");
ui_print("Install your new Kernel!");
ui_print(" PM ...AWESOME... @ XDA DEVELOPERS ");


Nothing risky but what's the point with double cache/dalvik wipe ? Why don't you delete libs and bin files before wiping cache/dalvik one time?
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 65
    Mods: If in wrong section feel free to move.

    1346283476.png

    I have decided to post the wipe scripts here for those KernelHolics & Flashaholics that are flashing kernels and ROMs constantly. I've made small modifications to these scripts FULL credit to the originator of them Credits below.

    These are compatible with CWM, TWRP.

    Since there have been numerous kernels recently being posted and people wondering what to wipe or what not to wiped here is the Kernel Cleaner.

    1. Place the file in the root of your /sdcard
    2. Flash Kernel Cleaner
    3. Flash/Fastboot Kernel
    4. Reboot.

    Download: http://d-h.st/IOn

    This second script I'm sure everyone is familiar with SUPERWIPE script.

    Tired of wiping after every ROM or not knowing what to wipe to flash a ROM and have a clean install? Just flash this script & flash ROM easy right?

    This version Deleted System, cache, data, formats device & INTERNAL SD CARD DATA!

    1. Place Wipe-Script in root of /sdcard
    2. Flash Wipe-Script
    3. Flash ROM
    4. Reboot.

    Download: http://d-h.st/L31

    This version is SUPERWIPE/NO INTERNAL SD DELETED!

    http://d-h.st/476
    SuperWipe deletes System, Cache, Dalvik, Formats Device!

    DOES NOT TOUCH INTERNAL DATA SDCARD

    Debug​

    If it doesn't flash please tell me what recovery your using.

    ONLY works for the NEXUS 4 ONLY will be available for other devices as well.

    Credit goes to the following people.​

    Mike1986
    AmazingLarry31
    Jivy26
    I-777
    Myself

    IF YOU USE/DOWNLOAD THIS SCRIPT PLEASE PRESS THE THANKS BUTTON​
    6
    Nice to see you here. I'll for sure be using this. Now go get the N4 and start with the ROMs!

    Sent from my Nexus 4 using Tapatalk 2

    Yes. I have PAC MAN ROM & TOASTED MARSHMALLOW for the N4 ready! :D 4.2.1
    2
    Reserved for more Awesome Scripts to make your life easier.
    2
    Sweet! So that means you got it or deving blind?

    And to stay on topic. From my understanding this will keep me from having to flash a neutral kernel in between flashes right?

    Sent from my Nexus 4 using Tapatalk 2

    I was lucky to get the device in the first wave just been updating my threads on other devices and finally got around to building for this device....

    Yes flashing the Kernel Script will save not only you but kernel devs from debugging bug reports that are usually caused by "dirty" flashing a kernel.

    Sent from my HTC One S using Tapatalk 2
    2
    http://d-h.st/476
    SuperWipe deletes System, Cache, Dalvik, Formats Device!

    DOES NOT TOUCH INTERNAL DATA SDCARD.