Jailbreak your iPhone

What is kext,Where is kext, how to Install kext.


kexticon128Kext file is a kernel extension. They’re generally used for device drivers and other things that need to modify the system at the lowest level. They’re not the same as classic Mac OS extensions, as many of the things that classic Mac OS extensions did are done differently in Mac OS X.Since kernel extensions aren’t protected by Mac OS X’s memory protection, developers are encouraged to stay away from writing them unless they absolutely have to. Even then, Mac OS X can dynamically load them, so chances are you’d rarely have to add anything to Mac OS X’s Extensions folder.

What is KEXT?
KEXT stands for Kernel Extension, this means that whatever needs to run in the kernel (OS core) environment can be written as extension and then loaded, even after the OSX has finished loading, this mostly answer the needs for hardware drivers.

Where are kext located?
kext are not files rather a folder (disguised as a file),

Leopard holds kext files/folders in the /System/Library/Extensions folder,
at boot time the relevant kext are uploaded from Extensions.mkext this is a cachefolder that contains kext related to the installed hardware,

you can delete it, if Leopard can’t find it, it will create it again,

you can also state to rebuild it from darwin prompt at boot time using the switch -f see this post for further information.
How to Install a new Kext?

cd /System/Library/Extensions
mv KextName.kext KextName.old  (where kextName stands for the kext you want to replace)this will rename the kext and this way back it up, it is highly recommended, warmly advised, very important to follow this step, it saved my OS many times

cd /path/to/new/kext (put your downloaded kext path here)
cp -R KextName.kext /System/Library/Extensions

next you need to fix permissions so the kext can be executed by OS user (root/system)
cd /System/Library/Extensions
chmod -R 755 KextName.kext
chown -R 0:0 KextName.kext   (this will set the ownership on files to system user (root))
rm /System/Library/Extensions.mkext   (this will reset all kext caching done by OSX)


Tags: , ,

Comments ( 7 )

Have Something To Say ?

  1. Alok February 7, 2011 Reply

    All commands are misleading according to the path
    I struggled and found this wis working on my pac

    kextcache -m Extensions.mkext -z /System/Library/Extensions

  2. Toyminator May 13, 2010 Reply

    Warning these instructions are incomplete. You must rebuild the Extensions.mkext file with the command:
    kextcache -m /Extensions.mkext /systems/extensions

    Your system will not reboot otherwise

  3. adi5402 March 15, 2010 Reply

    Hi I cant get past the boot : anything i load with just causes the system to restart

    any ideas whats going on

  4. hackeron November 13, 2009 Reply

    This page explains nothing.

    I came to this page to find out about where kexts can go, especially about the /Extra directory.

    1) Where in /Extra should I put a Disabler.kext?
    2) I’m not sure what installer I used but how did com.apple.boot.plist end up in /Extra?
    3) Guides I found say to put extensions in /Extra/Extensions/ – I don’t have that directory, should I create it?
    4) Is there an extensions search path I can specify somewhere?

    Currently this is what I have in /Extra:


  5. Flavio August 7, 2009 Reply

    Is there any way to recover kexts manually? I mean, I just updated my hackintosh from 10.5.7 to 10.5.8 and unfortunaly I forget to backup my Extensions, so system is not booting. But of course I can access to the disk by InstallDVD-terminal procedure.

    I saw that only 8 files were changed in my Extension folder. One of them is IOPCIFamily and system. Before I resintall the system again, I don’t know if there is any other way to fixed or if can I do something manually, aka text edit,etc.

    Another alternative could be to install the same system (10.5.7) in an USB disk, make it functional and then move kexts manually from that disk to 10.5.8 disk. Is that could be possible? Can I mix 10.5.7 kext into 10.5.8 version? I understand that’s the idea of previous backup of Extension folder.


    PD: My hardware is Asus P5K-VM (audio, LAN, GMA3000 video), Quad2Core 2.4GHz, 4Gb RAM OCZ-800Mhz, Nvidia MSI 8600GTS 256MB, 500Gb Samsung 7200

  6. Mellifluos May 18, 2009 Reply

    Operate in Single Use mode:

    Reboot at Darwin Boot Loader and type -s and press enter.
    Now execute the following commands :

    mount - uw /
    cd /System/Library/Extensions
    rm -fr KextName.kext
    mv KextName.old KextName.kext
    (where kextName stands for the kext you want to replace)

  7. Vishu March 14, 2009 Reply


    Can u please tell me how to restore a old kext if i used a wrong kext??


Leave your comment here