KEXTCACHE(8) | System Manager's Manual | KEXTCACHE(8) |
kextcache
— create
kext cache files
kextcache |
-prelinked-kernel filename
[options] [-- ]
[kext_or_directory ... ] |
kextcache |
-system-prelinked-kernel
[options] [-- ]
[kext_or_directory ... ] |
kextcache |
-system-caches
[options] |
kextcache |
-update-volume os_volume
[options] |
The kextcache
utility has been deprecated.
It should no longer be necessary to use. See kmutil(8)
The kextcache
program creates kext caches,
which speed up kext loading operations. It is invoked automatically as
needed to rebuild system caches.
Caution:
Incorrect use of kextcache
can render a volume
incapable of startup. Installers and administrators should not use this
program to update system kext caches. Instead they should run
touch(1) on the
/System/Library/Extensions/ directory of the
installation target volume after they have finished, which invalidates the
existing caches and causes the system to update all necessary kext caches.
kextcache
-update-volume
can
be used to wait for this process to complete. See “Apple Developer
Technical Q&A QA1319: Installing an I/O Kit Kext Without
Rebooting” for information on updating kext caches on prior releases
of macOS.
kextcache
creates several kinds of kext
caches. The first is the prelinked kernel (also known as a
“prelinkedkernel”), which contains the kernel code and the
essential files (info dictionary and executable) for an arbitrary set of
kexts, with kext executables linked for their run-time locations. A
prelinked kernel speeds early system startup by collecting these many files
in one place for the booter to locate, and by having each kext linked in
place and ready to start as needed. To create or update a prelinked kernel,
use the -prelinked-kernel
or
-system-prelinked-kernel
option.
Other kext caches collect specific data from the info dictionaries
of kexts. There are many individual caches for specific subsets of data;
they care collectively called system info caches. These caches are used to
optimize disk I/O when working with kexts during late system startup and
beyond. To update the system kext info caches for the root volume, use the
-system-caches
option.
You must specify one of these options to have
kextcache
do anything:
-c
[filename], -prelinked-kernel
[filename]-all-loaded
.-system-prelinked-kernel
-all-loaded
.-system-caches
-i
os_volume, -invalidate
os_volumeThis option mimics sudo touch /System/Library/Extensions on
os_volume. If kextcache
cannot find or make sense of
os_volume/usr/standalone/bootcaches.plist,
the volume is treated as if no caches need updating: success is
returned.
-u
os_volume, -update-volume
os_volume-caches-only
and -force
.
Which caches are rebuilt depends on the macOS release
installed on os_volume. If
kextcache
cannot find or make sense of
os_volume/usr/standalone/bootcaches.plist
the volume is treated as if no caches need updating: success is
returned.
-U
os_volume-U
is used during system startup to check whether
the cache from which the currently-running kernel was loaded is out of
date. System startup interprets an EX_OSFILE exit code to mean that the
system should be immediately rebooted off the newer kernel cache.-Boot
-U
to enable early boot behaviors such
as limiting which caches must be updated.-e
,
-system-mkext
-system-prelinked-kernel
.-clear-staging
-prune-staging
These options restrict which kexts are included in a prelinked
kernel. The options -arch
and
-bundle-id
select kexts by supported architecture
and bundle identifier; the remaining filtering options select kexts based on
the value of their OSBundleRequired property. If these options are
specified, the cache will contain only kexts whose OSBundleRequired property
matches any of these options, or whose OSBundleRequired property is
“Root” or “Console”.
A prelinked kernel cache intended for a startup from a local disk
should be created with the -local-root
option, while
a cache intended for startup from the network should be created with the
-network-root
option. When creating a prelinked
kernel, if the -all-loaded
option is specified,
kexts requested by the kernel are always included regardless of these
filtering options.
-a
arch, -arch
arch-b
identifier, -bundle-id
identifier-l
,
-local-root
-local-root-all
option.-L
,
-local-root-all
-local-root
option.-n
,
-network-root
-network-root-all
option.-N
,
-network-root-all
-network-root
option.-s
,
-safe-boot
-safe-boot-all
option.-S
,
-safe-boot-all
-safe-boot
option.-caches-only
-update-volume
, skips updating any helper
partitions even if they appear out of to date.-f
,
-force
-update-volume
, rebuilds any helper
partitions even if they appear up to date. If this version of
kextcache
does not understand
bootcaches.plist well enough to be able to update
the helpers, exit with EX_OSFILE (72).-Installer
-update-volume
, implies
-force
while making helper partition updates
optional.-F
-h
,
-help
-K
kernel_filename, -kernel
kernel_filename-q
,
-quiet
-r
,
-all-loaded
-compressed
-uncompressed
-c
, uncompresses an existing
prelinked kernel file in place.-symbols
symbol_directory-t
,
-print-diagnostics
-v
[0-6
|
0x####
],
-verbose
[0-6
|
0x####
]kextcache
prints only warnings and errors. You can
specify a level from 0-6, or a hexadecimal log specification (as described
in kext_logging(8)). The levels
of verbose output are:
-quiet
.kextcache
.Unlike in other kext tools, the
-verbose
flag in
kextcache
applies to all kexts (that is, it
turns on hexadecimal bit 0x8 by default). See
kext_logging(8) for more information on verbose
logging.
-volume-root
path-z
,
-no-authentication
--
kextcache
exits with a zero status upon
success. Upon failure, it prints an error message and exits with a nonzero
status.
Many single-letter options are inconsistent in meaning with (or directly contradictory to) the same letter options in other kext tools.
kmutil(8), kernelmanagerd(8), kext_logging(8), kextd(8), kextload(8), kextutil(8), kextstat(8), kextunload(8)
November 14, 2012 | Darwin |