blob: 5a1cf440c75a82f463b92440399fb95517828e43 [file] [log] [blame]
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -07001
2Android Init Language
3---------------------
4
Tom Cherry3be66ed2015-09-01 14:49:38 -07005The Android Init Language consists of five broad classes of statements,
6which are Actions, Commands, Services, Options, and Imports.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -07007
8All of these are line-oriented, consisting of tokens separated by
9whitespace. The c-style backslash escapes may be used to insert
10whitespace into a token. Double quotes may also be used to prevent
11whitespace from breaking text into multiple tokens. The backslash,
12when it is the last character on a line, may be used for line-folding.
13
14Lines which start with a # (leading whitespace allowed) are comments.
15
16Actions and Services implicitly declare a new section. All commands
17or options belong to the section most recently declared. Commands
18or options before the first section are ignored.
19
Tom Cherry3be66ed2015-09-01 14:49:38 -070020Actions and Services have unique names. If a second Action is defined
21with the same name as an existing one, its commands are appended to
22the commands of the existing action. If a second Service is defined
23with the same name as an existing one, it is ignored and an error
24message is logged.
25
26
27Init .rc Files
28--------------
29The init language is used in plaintext files that take the .rc file
30extension. These are typically multiple of these in multiple
31locations on the system, described below.
32
33/init.rc is the primary .rc file and is loaded by the init executable
34at the beginning of its execution. It is responsible for the initial
35set up of the system. It imports /init.${ro.hardware}.rc which is the
36primary vendor supplied .rc file.
37
38During the mount_all command, the init executable loads all of the
39files contained within the /{system,vendor,odm}/etc/init/ directories.
40These directories are intended for all Actions and Services used after
41file system mounting.
42
43The intention of these directories is as follows
44 1) /system/etc/init/ is for core system items such as
45 SurfaceFlinger and MediaService.
46 2) /vendor/etc/init/ is for SoC vendor items such as actions or
47 daemons needed for core SoC functionality.
48 3) /odm/etc/init/ is for device manufacturer items such as
49 actions or daemons needed for motion sensor or other peripheral
50 functionality.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -070051
Hung-ying Tyandc738ea2016-01-14 11:18:21 +080052One may specify paths in the mount_all command line to have it import
53.rc files at the specified paths instead of the default ones described above.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -070054
55Actions
56-------
57Actions are named sequences of commands. Actions have a trigger which
58is used to determine when the action should occur. When an event
59occurs which matches an action's trigger, that action is added to
60the tail of a to-be-executed queue (unless it is already on the
61queue).
62
63Each action in the queue is dequeued in sequence and each command in
64that action is executed in sequence. Init handles other activities
65(device creation/destruction, property setting, process restarting)
66"between" the execution of the commands in activities.
67
68Actions take the form of:
69
Tom Cherry3be66ed2015-09-01 14:49:38 -070070on <trigger> [&& <trigger>]*
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -070071 <command>
72 <command>
73 <command>
74
75
76Services
77--------
78Services are programs which init launches and (optionally) restarts
79when they exit. Services take the form of:
80
81service <name> <pathname> [ <argument> ]*
82 <option>
83 <option>
84 ...
85
86
87Options
88-------
89Options are modifiers to services. They affect how and when init
90runs the service.
91
92critical
Elliott Hughesd62f0602015-06-12 18:02:20 -070093 This is a device-critical service. If it exits more than four times in
94 four minutes, the device will reboot into recovery mode.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -070095
96disabled
Elliott Hughesd62f0602015-06-12 18:02:20 -070097 This service will not automatically start with its class.
98 It must be explicitly started by name.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -070099
100setenv <name> <value>
Elliott Hughesd62f0602015-06-12 18:02:20 -0700101 Set the environment variable <name> to <value> in the launched process.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700102
Elliott Hughes8d82ea02015-02-06 20:15:18 -0800103socket <name> <type> <perm> [ <user> [ <group> [ <seclabel> ] ] ]
Elliott Hughesd62f0602015-06-12 18:02:20 -0700104 Create a unix domain socket named /dev/socket/<name> and pass
105 its fd to the launched process. <type> must be "dgram", "stream" or "seqpacket".
106 User and group default to 0.
107 'seclabel' is the SELinux security context for the socket.
108 It defaults to the service security context, as specified by seclabel or
109 computed based on the service executable file security context.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700110
111user <username>
Elliott Hughesd62f0602015-06-12 18:02:20 -0700112 Change to username before exec'ing this service.
113 Currently defaults to root. (??? probably should default to nobody)
Tom Cherrydbddb402015-12-11 12:54:50 -0800114 As of Android M, processes should use this option even if they
115 require linux capabilities. Previously, to acquire linux
116 capabilities, a process would need to run as root, request the
117 capabilities, then drop to its desired uid. There is a new
118 mechanism through fs_config that allows device manufacturers to add
119 linux capabilities to specific binaries on a file system that should
120 be used instead. This mechanism is described on
121 http://source.android.com/devices/tech/config/filesystem.html. When
122 using this new mechanism, processes can use the user option to
123 select their desired uid without ever running as root.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700124
125group <groupname> [ <groupname> ]*
Elliott Hughesd62f0602015-06-12 18:02:20 -0700126 Change to groupname before exec'ing this service. Additional
127 groupnames beyond the (required) first one are used to set the
128 supplemental groups of the process (via setgroups()).
129 Currently defaults to root. (??? probably should default to nobody)
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700130
Elliott Hughes8d82ea02015-02-06 20:15:18 -0800131seclabel <seclabel>
132 Change to 'seclabel' before exec'ing this service.
Stephen Smalley3fb61102012-11-02 15:22:34 -0400133 Primarily for use by services run from the rootfs, e.g. ueventd, adbd.
134 Services on the system partition can instead use policy-defined transitions
135 based on their file security context.
136 If not specified and no transition is defined in policy, defaults to the init context.
137
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700138oneshot
Elliott Hughesd62f0602015-06-12 18:02:20 -0700139 Do not restart the service when it exits.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700140
141class <name>
Elliott Hughesd62f0602015-06-12 18:02:20 -0700142 Specify a class name for the service. All services in a
143 named class may be started or stopped together. A service
144 is in the class "default" if one is not specified via the
145 class option.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700146
147onrestart
Elliott Hughesd62f0602015-06-12 18:02:20 -0700148 Execute a Command (see below) when service restarts.
149
150writepid <file...>
151 Write the child's pid to the given files when it forks. Meant for
152 cgroup/cpuset usage.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700153
Elliott Hughes841b2632015-02-12 14:28:54 -0800154
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700155Triggers
156--------
Tom Cherry3be66ed2015-09-01 14:49:38 -0700157Triggers are strings which can be used to match certain kinds of
158events and used to cause an action to occur.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700159
Tom Cherry3be66ed2015-09-01 14:49:38 -0700160Triggers are subdivided into event triggers and property triggers.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700161
Tom Cherry3be66ed2015-09-01 14:49:38 -0700162Event triggers are strings triggered by the 'trigger' command or by
163the QueueEventTrigger() function within the init executable. These
164take the form of a simple string such as 'boot' or 'late-init'.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700165
Tom Cherry3be66ed2015-09-01 14:49:38 -0700166Property triggers are strings triggered when a named property changes
167value to a given new value or when a named property changes value to
168any new value. These take the form of 'property:<name>=<value>' and
169'property:<name>=*' respectively. Property triggers are additionally
170evaluated and triggered accordingly during the initial boot phase of
171init.
Badhri Jagan Sridharan0b415122014-10-10 23:19:06 -0700172
Tom Cherry3be66ed2015-09-01 14:49:38 -0700173An Action can have multiple property triggers but may only have one
174event trigger.
Badhri Jagan Sridharan0b415122014-10-10 23:19:06 -0700175
Tom Cherry3be66ed2015-09-01 14:49:38 -0700176For example:
177'on boot && property:a=b' defines an action that is only executed when
178the 'boot' event trigger happens and the property a equals b.
179
180'on property:a=b && property:c=d' defines an action that is executed
181at three times,
182 1) During initial boot if property a=b and property c=d
183 2) Any time that property a transitions to value b, while property
184 c already equals d.
185 3) Any time that property c transitions to value d, while property
186 a already equals b.
Badhri Jagan Sridharan0b415122014-10-10 23:19:06 -0700187
Elliott Hughes841b2632015-02-12 14:28:54 -0800188
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700189Commands
190--------
191
Elliott Hughes91a3be52015-03-20 11:00:15 -0700192bootchart_init
193 Start bootcharting if configured (see below).
194 This is included in the default init.rc.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700195
196chmod <octal-mode> <path>
197 Change file access permissions.
198
199chown <owner> <group> <path>
200 Change file owner and group.
201
202class_start <serviceclass>
203 Start all services of the specified class if they are
204 not already running.
205
206class_stop <serviceclass>
Elliott Hughes91a3be52015-03-20 11:00:15 -0700207 Stop and disable all services of the specified class if they are
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700208 currently running.
209
Elliott Hughes91a3be52015-03-20 11:00:15 -0700210class_reset <serviceclass>
211 Stop all services of the specified class if they are
212 currently running, without disabling them. They can be restarted
213 later using class_start.
214
215copy <src> <dst>
216 Copies a file. Similar to write, but useful for binary/large
217 amounts of data.
218
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700219domainname <name>
220 Set the domain name.
221
JP Abgrall3beec7e2014-05-02 21:14:29 -0700222enable <servicename>
223 Turns a disabled service into an enabled one as if the service did not
224 specify disabled.
225 If the service is supposed to be running, it will be started now.
226 Typically used when the bootloader sets a variable that indicates a specific
227 service should be started when needed. E.g.
228 on property:ro.boot.myfancyhardware=1
229 enable my_fancy_service_for_my_fancy_hardware
230
Elliott Hughes91a3be52015-03-20 11:00:15 -0700231exec [ <seclabel> [ <user> [ <group> ]* ] ] -- <command> [ <argument> ]*
232 Fork and execute command with the given arguments. The command starts
233 after "--" so that an optional security context, user, and supplementary
234 groups can be provided. No other commands will be run until this one
Mark Salyzyn17fff892015-06-02 11:11:02 -0700235 finishes. <seclabel> can be a - to denote default.
Elliott Hughes91a3be52015-03-20 11:00:15 -0700236
Elliott Hughes91a3be52015-03-20 11:00:15 -0700237export <name> <value>
238 Set the environment variable <name> equal to <value> in the
239 global environment (which will be inherited by all processes
240 started after this command is executed)
241
242hostname <name>
243 Set the host name.
244
245ifup <interface>
246 Bring the network interface <interface> online.
247
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700248insmod <path>
249 Install the module at <path>
250
Elliott Hughes91a3be52015-03-20 11:00:15 -0700251load_all_props
252 Loads properties from /system, /vendor, et cetera.
253 This is included in the default init.rc.
254
255load_persist_props
256 Loads persistent properties when /data has been decrypted.
257 This is included in the default init.rc.
258
Elliott Hughesf682b472015-02-06 12:19:48 -0800259loglevel <level>
260 Sets the kernel log level to level. Properties are expanded within <level>.
261
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700262mkdir <path> [mode] [owner] [group]
263 Create a directory at <path>, optionally with the given mode, owner, and
264 group. If not provided, the directory is created with permissions 755 and
Johan Redestig0b42ba22015-03-15 17:39:41 +0100265 owned by the root user and root group. If provided, the mode, owner and group
266 will be updated if the directory exists already.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700267
Hung-ying Tyandc738ea2016-01-14 11:18:21 +0800268mount_all <fstab> [ <path> ]*
269 Calls fs_mgr_mount_all on the given fs_mgr-format fstab and imports .rc files
270 at the specified paths (e.g., on the partitions just mounted). Refer to the
271 section of "Init .rc Files" for detail.
Elliott Hughes91a3be52015-03-20 11:00:15 -0700272
Niklas Tibblingbc3f69f2012-08-01 13:15:38 +0200273mount <type> <device> <dir> [ <flag> ]* [<options>]
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700274 Attempt to mount the named device at the directory <dir>
275 <device> may be of the form mtd@name to specify a mtd block
276 device by name.
Niklas Tibblingbc3f69f2012-08-01 13:15:38 +0200277 <flag>s include "ro", "rw", "remount", "noatime", ...
278 <options> include "barrier=1", "noauto_da_alloc", "discard", ... as
279 a comma separated string, eg: barrier=1,noauto_da_alloc
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700280
Elliott Hughes91a3be52015-03-20 11:00:15 -0700281powerctl
282 Internal implementation detail used to respond to changes to the
283 "sys.powerctl" system property, used to implement rebooting.
284
285restart <service>
286 Like stop, but doesn't disable the service.
287
Stephen Smalley726e8f72013-10-09 16:02:09 -0400288restorecon <path> [ <path> ]*
Stephen Smalley3fb61102012-11-02 15:22:34 -0400289 Restore the file named by <path> to the security context specified
290 in the file_contexts configuration.
291 Not required for directories created by the init.rc as these are
292 automatically labeled correctly by init.
293
Stephen Smalley726e8f72013-10-09 16:02:09 -0400294restorecon_recursive <path> [ <path> ]*
295 Recursively restore the directory tree named by <path> to the
296 security contexts specified in the file_contexts configuration.
Stephen Smalley726e8f72013-10-09 16:02:09 -0400297
Elliott Hughes91a3be52015-03-20 11:00:15 -0700298rm <path>
299 Calls unlink(2) on the given path. You might want to
300 use "exec -- rm ..." instead (provided the system partition is
301 already mounted).
302
303rmdir <path>
304 Calls rmdir(2) on the given path.
305
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700306setprop <name> <value>
Elliott Hughesf682b472015-02-06 12:19:48 -0800307 Set system property <name> to <value>. Properties are expanded
308 within <value>.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700309
310setrlimit <resource> <cur> <max>
311 Set the rlimit for a resource.
312
313start <service>
314 Start a service running if it is not already running.
315
316stop <service>
317 Stop a service from running if it is currently running.
318
Elliott Hughes91a3be52015-03-20 11:00:15 -0700319swapon_all <fstab>
320 Calls fs_mgr_swapon_all on the given fstab file.
321
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700322symlink <target> <path>
323 Create a symbolic link at <path> with the value <target>
324
The Android Open Source Project35237d12008-12-17 18:08:08 -0800325sysclktz <mins_west_of_gmt>
326 Set the system clock base (0 if system clock ticks in GMT)
327
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700328trigger <event>
329 Trigger an event. Used to queue an action from another
330 action.
331
Elliott Hughes91a3be52015-03-20 11:00:15 -0700332verity_load_state
333 Internal implementation detail used to load dm-verity state.
334
335verity_update_state <mount_point>
336 Internal implementation detail used to update dm-verity state and
337 set the partition.<mount_point>.verified properties used by adb remount
338 because fs_mgr can't set them directly itself.
339
Patrick McCormick96d0a4d2011-02-04 10:51:39 -0800340wait <path> [ <timeout> ]
Elliott Hughes91a3be52015-03-20 11:00:15 -0700341 Poll for the existence of the given file and return when found,
342 or the timeout has been reached. If timeout is not specified it
343 currently defaults to five seconds.
Patrick McCormick96d0a4d2011-02-04 10:51:39 -0800344
Elliott Hughesf682b472015-02-06 12:19:48 -0800345write <path> <content>
346 Open the file at <path> and write a string to it with write(2).
347 If the file does not exist, it will be created. If it does exist,
348 it will be truncated. Properties are expanded within <content>.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700349
350
Tom Cherry3be66ed2015-09-01 14:49:38 -0700351Imports
352-------
353The import keyword is not a command, but rather its own section and is
354handled immediately after the .rc file that contains it has finished
355being parsed. It takes the below form:
356
357import <path>
358 Parse an init config file, extending the current configuration.
359 If <path> is a directory, each file in the directory is parsed as
360 a config file. It is not recursive, nested directories will
361 not be parsed.
362
363There are only two times where the init executable imports .rc files,
364 1) When it imports /init.rc during initial boot
Hung-ying Tyandc738ea2016-01-14 11:18:21 +0800365 2) When it imports /{system,vendor,odm}/etc/init/ or .rc files at specified
366 paths during mount_all
Tom Cherry3be66ed2015-09-01 14:49:38 -0700367
368
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700369Properties
370----------
Tom Cherry3be66ed2015-09-01 14:49:38 -0700371Init provides information about the services that it is responsible
372for via the below properties.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700373
374init.svc.<name>
Tom Cherry3be66ed2015-09-01 14:49:38 -0700375 State of a named service ("stopped", "stopping", "running", "restarting")
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700376
377
Elliott Hughes841b2632015-02-12 14:28:54 -0800378Bootcharting
379------------
Elliott Hughes841b2632015-02-12 14:28:54 -0800380This version of init contains code to perform "bootcharting": generating log
381files that can be later processed by the tools provided by www.bootchart.org.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700382
Elliott Hughes59abac22015-03-28 12:12:51 -0700383On the emulator, use the -bootchart <timeout> option to boot with bootcharting
384activated for <timeout> seconds.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700385
Elliott Hughes841b2632015-02-12 14:28:54 -0800386On a device, create /data/bootchart/start with a command like the following:
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700387
Elliott Hughes841b2632015-02-12 14:28:54 -0800388 adb shell 'echo $TIMEOUT > /data/bootchart/start'
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700389
Elliott Hughes841b2632015-02-12 14:28:54 -0800390Where the value of $TIMEOUT corresponds to the desired bootcharted period in
391seconds. Bootcharting will stop after that many seconds have elapsed.
392You can also stop the bootcharting at any moment by doing the following:
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700393
Elliott Hughes841b2632015-02-12 14:28:54 -0800394 adb shell 'echo 1 > /data/bootchart/stop'
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700395
Elliott Hughes841b2632015-02-12 14:28:54 -0800396Note that /data/bootchart/stop is deleted automatically by init at the end of
397the bootcharting. This is not the case with /data/bootchart/start, so don't
398forget to delete it when you're done collecting data.
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700399
Elliott Hughes841b2632015-02-12 14:28:54 -0800400The log files are written to /data/bootchart/. A script is provided to
401retrieve them and create a bootchart.tgz file that can be used with the
402bootchart command-line utility:
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700403
Elliott Hughes841b2632015-02-12 14:28:54 -0800404 sudo apt-get install pybootchartgui
Elliott Hughes59abac22015-03-28 12:12:51 -0700405 # grab-bootchart.sh uses $ANDROID_SERIAL.
Elliott Hughes841b2632015-02-12 14:28:54 -0800406 $ANDROID_BUILD_TOP/system/core/init/grab-bootchart.sh
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700407
Elliott Hughes59abac22015-03-28 12:12:51 -0700408One thing to watch for is that the bootchart will show init as if it started
409running at 0s. You'll have to look at dmesg to work out when the kernel
410actually started init.
411
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700412
Ben Cheng50bbde02015-06-09 17:04:36 +0800413Comparing two bootcharts
414------------------------
415A handy script named compare-bootcharts.py can be used to compare the
416start/end time of selected processes. The aforementioned grab-bootchart.sh
417will leave a bootchart tarball named bootchart.tgz at /tmp/android-bootchart.
418If two such barballs are preserved on the host machine under different
419directories, the script can list the timestamps differences. For example:
420
421Usage: system/core/init/compare-bootcharts.py base_bootchart_dir
422 exp_bootchart_dir
423
424process: baseline experiment (delta)
425 - Unit is ms (a jiffy is 10 ms on the system)
426------------------------------------
427/init: 50 40 (-10)
428/system/bin/surfaceflinger: 4320 4470 (+150)
429/system/bin/bootanimation: 6980 6990 (+10)
430zygote64: 10410 10640 (+230)
431zygote: 10410 10640 (+230)
432system_server: 15350 15150 (-200)
433bootanimation ends at: 33790 31230 (-2560)
434
435
Yasuhiro Matsudaf93db4b2015-06-15 18:49:35 +0900436Systrace
437--------
438Systrace [1] can be used for obtaining performance analysis reports during boot
439time on userdebug or eng builds.
440Here is an example of trace events of "wm" and "am" categories:
441
442 $ANDROID_BUILD_TOP/external/chromium-trace/systrace.py wm am --boot
443
444This command will cause the device to reboot. After the device is rebooted and
445the boot sequence has finished, the trace report is obtained from the device
446and written as trace.html on the host by hitting Ctrl+C.
447
448LIMITATION
449Recording trace events is started after persistent properties are loaded, so
450the trace events that are emitted before that are not recorded. Several
451services such as vold, surfaceflinger, and servicemanager are affected by this
452limitation since they are started before persistent properties are loaded.
453Zygote initialization and the processes that are forked from the zygote are not
454affected.
455
456[1] http://developer.android.com/tools/help/systrace.html
457
458
Elliott Hughes841b2632015-02-12 14:28:54 -0800459Debugging init
460--------------
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700461By default, programs executed by init will drop stdout and stderr into
462/dev/null. To help with debugging, you can execute your program via the
Elliott Hughesf682b472015-02-06 12:19:48 -0800463Android program logwrapper. This will redirect stdout/stderr into the
The Android Open Source Project4f6e8d72008-10-21 07:00:00 -0700464Android logging system (accessed via logcat).
465
466For example
467service akmd /system/bin/logwrapper /sbin/akmd
Elliott Hughesf682b472015-02-06 12:19:48 -0800468
469For quicker turnaround when working on init itself, use:
470
Elliott Hughes841b2632015-02-12 14:28:54 -0800471 mm -j
Elliott Hughesf682b472015-02-06 12:19:48 -0800472 m ramdisk-nodeps
473 m bootimage-nodeps
474 adb reboot bootloader
475 fastboot boot $ANDROID_PRODUCT_OUT/boot.img
476
477Alternatively, use the emulator:
478
479 emulator -partition-size 1024 -verbose -show-kernel -no-window
480
481You might want to call klog_set_level(6) after the klog_init() call
482so you see the kernel logging in dmesg (or the emulator output).