This version is now deprecated, consult the downloads page for a link to the latest version.
This is a complete rewrite of the pfix utility. I have taken the feedback I have received over the last month since the initial release and attempted to make a more solid and universal solution that eliminates as many potential problems as possible and provides intelligent feedback to the user to help ensure proper usage.
Basic usage instructions:
Run this script by double clicking it in finder or using the command “sudo /path/to/pfix” from a terminal if it says “command not found” or “Permission denied” you must fix the permissions to make the script executable using the command “sudo chmod 755 /path/to/pfix” before running.
IMPORTANT NOTE: This script is intended to be used for correcting permissions and building kext caches on Snow Leopard ONLY! It can be run from Tiger, Leopard or Snow Leopard but you MUST target a Snow Leopard Volume!
Changes since v1.2:
- -Reverted to chmod -R 755 *
- -Added an OS X Version Check *
- -pfix now functions correctly on OS X 10.4 “Tiger”
- -Kexts are now installed to /Extra/Extensions *
- -Added diskutil repairPermissions / command *
- -Added function to delete kext caches if pfix was run from OS X 10.4 *
- -Verbose output is now written to pfix.log for debugging purposes and simplification of terminal output.
* A problem arose which is discussed in more detail in the comments HERE that caused a failure in SMB due to a binary inside of a particular kext that required executable permissions. This is a potential issue for other kexts and although rare it poses enough of a problem that it needed to be corrected.
* The kextcache utility on older versions of OS X (10.4 “Tiger” and earlier) can not create snow leopard compatable mkext’s. Which of course will cause a boot failure of snow leopard. The solution was to test for OS version and remove caches when pfix is running on older versions of OS X to force snow leopard to boot from the kext files directly. This is also why I have reverted to using /Extra/Extensions instead of /Extra/CustomExtensions which would not boot without a proper mkext inside of /Extra.
* As mentioned in * the primary reason for doing this was to re-enable the functionality of -f (ignore kext caches) command in chameleon and allow the system to boot without kext caches. In older revisions of pfix and the myHack installer I used /Extra/CustomExtensions directory to correct an error that was happening to many people using PC EFI 10.1 when booting Snow Leopard. Since Chameleon RC3 & PC EFI 10.3 I have not heard a single report of that error so it no longer appears to be a problem and this should no longer be required.
* This will only be ran if the script is being run on the root partition [/] of a running Snow Leopard installation. Due to the fact that I have now granted executable permissions to many files that do not require it so that others which do will not fail (as mentioned in *) it is nessisary to revoke those permissions and set them as correctly as possible using the diskutility’s internal permissions database. This command however will not work on disks mounted under /Volumes so if you have run pfix from another partition it will be nessisary to either run pfix again on the snow leopard system after booting to it or to go into disk utility manually and run the command yourself.
* As metioned in * & * this has been done to ensure that snow leopard partitions that have been repaired or modified from an older OS X operating system which can not correctly build kext caches for snow leopard will not fail to boot. It will be nessisary to run pfix again or manually build these caches from inside of a working snow leopard install for proper operation. (Kext caches help to speed up the boot process).
NOTE: I have been asked on IRC “it possible to use name of /extra/extensions as a parameter? (for example mine is /extra/extensions_)”. If you haven’t read my release notes on the v2.0 page as I stated there the reasons for using other Extensions directories that used to exist are no longer a problem as far as I know since pc efi 10.3. However, if for some reason you really want to use a different directory name just open up the script in a text editor, search for the EXTRA_KEXT=”$VOLUME/Extra/Extensions” line and change it. ;)
For further information about permissions and kext caches please review this post.