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

How can I backup and restore the kernel only?

cdl

Android Enthusiast
Feb 4, 2010
448
60
I have an unlocked and rooted Samsung Galaxy S2 running the MIUI ROM, but I am posting here as I think this is a generic question.

Is there a way to backup and restore the kernel only, not a full nandroid backup? I searched the web, the android forums etc but all I could find was this suggestion to:

"just grab the boot.img and contents of /system/lib/modules from your rom zip and make your own update.zip"
[Q] Best way to backup and restore kernel only [Archive] - xda-developers

However, I found no comment of anyone actually confirming it does work.

There is an app for the Galaxy S (not the S2) which is supposed to backup the kernel, but I couldn't find anything similar for the S2 or for generic phones.

Thanks
 
A.)Do a nandroid backup and do advanced restore instead of complete restore.
boot.img is the kernel.

If you have required system I dont think you will need to flash /system/lib .
If however you are juggling between say CM7 ,Stock and MIUI then you will need to do a complete system flash ,atleast /system/app,/system/framework ,/system/bin ,/system/lib .
 
Upvote 0
A.)Do a nandroid backup and do advanced restore instead of complete restore.
boot.img is the kernel.

If you have required system I dont think you will need to flash /system/lib .
If however you are juggling between say CM7 ,Stock and MIUI then you will need to do a complete system flash ,atleast /system/app,/system/framework ,/system/bin ,/system/lib .

Thanks. However, I'm not sure I understand the last bit - sorry but I am new to custom Roms and kernels.

What do you mean by required system?
When you say complete system flash, is that an option in the recovery mode or what?

Thanks again!
 
Upvote 0
Ok .
So here is the thing .
A complete ROM is boot.img plus /system files .

Custom kernels are modified kernels .They may offer addition features like overclocking ,efficient governors and so on .
BUT each kernel is dependent on a system like CyanogenMod ,MIUI , Stock .
The dev usually notifies "This kernel is to be used on CyanogenMod " or
the kernel is part of ABC mod of CyanogenMod or so

So say ,you like the look of modified cyanogenmod but feel that kernel is using battery
and you want to revert to the original cyanogen kernel
You can do it with least probability of unstability

But if you like look of MIUI and you want kernel of CyanogenMod ,that is not possible and it shouldn't be try it for good reasons .It may not boot .

There is/are options for restoring individual kernel/system/data/sd-ext in clockworkmod .
So if you want to clean a ROM flash kernel and system.
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones