WEB开发网
开发学院手机开发Android 开发 Android启动脚本init.rc 阅读

Android启动脚本init.rc

 2010-09-14 23:58:00 来源:WEB开发网   
核心提示:the tail of a to-be-executed queue (unless it is already on thequeue).Each action in the queue is dequeued in sequence and each command inthat action is execute

the tail of a to-be-executed queue (unless it is already on the

queue).

Each action in the queue is dequeued in sequence and each command in

that action is executed in sequence. Init handles other activities

(device creation/destruction, property setting, process restarting)

"between" the execution of the commands in activities.

Actions take the form of:

on < trigger>

< command>

< command>

< command>

Services

--------

Services are programs which init launches and (optionally) restarts

when they exit. Services take the form of:

service < name> < pathname> [ < argument> ]*

< option>

< option>

...

Options

-------

Options are modifiers to services. They affect how and when init

runs the service.

critical

This is a device-critical service. If it exits more than four times in

four minutes, the device will reboot into recovery mode.

disabled

This service will not automatically start with its class.

It must be explicitly started by name.

setenv < name> < value>

Set the environment variable < name> to < value> in the launched process.

socket < name> < type> < perm> [ < user> [ < group> ] ]

Create a unix domain socket named /dev/socket/< name> and pass

its fd to the launched process. < type> must be "dgram" or "stream".

User and group default to 0.

user < username>

Change to username before exec'ing this service.

Currently defaults to root. (??? probably should default to nobody)

Currently, if your process requires linux capabilities then you cannot

上一页  1 2 3 4 5 6 7  下一页

Tags:Android 启动 脚本

编辑录入:coldstar [复制链接] [打 印]
赞助商链接