属性变更的请求时init事件循环处理的另一个事件,在Android平台中,为了让运行中的所有进程共享系统运行时所需要的各种设置值,系统开辟了属性存储区域,并提供了访问该区域的API。属性由键(key)与值(value)构成,其表现形式为“键=值”。在Linux系统中,属性服务主要用来设置环境变量,提供各进程访问设定的环境变量值。在Android平台中,在访问属性值时,添加了访问权限控制,增强了访问的安全性。系统中所有运行中的进程都可以访问属性值,但仅有init进程才能修改属性值。其他进程修改属性值时,必须向init进程提出请求,最终由init进程负责修改属性值。在此过程中,init进程会先检查各属性的访问权限,而后再修改属性值,当属性值更改后,若定义在init.rc文件中的某个特定条件得到满足,则与此条件相匹配的动作就会发生,每个动作都有一个触发器,决定动作的执行时间,记录在“on property”关键字后的命令即被执行。
root@sabresd_6dq:/ # getprop
[CPU]: [i.MX6 Cortex A9 .0GHz]
[FileSystemVersion]: []
[RAM]: [DDR3 .0GB]
[SoftwarePartNumber]: [0713625406xx]
[alsa.mixer.capture.headset]: [Capture]
[alsa.mixer.capture.master]: [Capture]
[alsa.mixer.playback.headset]: [Headphone]
[alsa.mixer.playback.master]: [Playback]
[alsa.mixer.playback.speaker]: [Playback]
[back_camera_orient]: []
[camera.disable_zsl_mode]: []
[dalvik.vm.dex2oat-Xms]: [64m]
[dalvik.vm.dex2oat-Xmx]: [512m]
[dalvik.vm.dexopt-flags]: [m=y]
[dalvik.vm.heapgrowthlimit]: [80m]
[dalvik.vm.heapmaxfree]: [8m]
[dalvik.vm.heapminfree]: [512k]
[dalvik.vm.heapsize]: [384m]
[dalvik.vm.heapstartsize]: [8m]
[dalvik.vm.heaptargetutilization]: [0.75]
[dalvik.vm.image-dex2oat-Xms]: [64m]
[dalvik.vm.image-dex2oat-Xmx]: [64m]
[dalvik.vm.isa.arm.features]: [default]
[dalvik.vm.stack-trace-file]: [/data/anr/traces.txt]
[debug.egl.hw]: []
[debug.force_rtl]: []
[debug.sf.enable_hgl]: []
[debug.sf.showfps]: []
[dev.bootcomplete]: []
[front_camera_orient]: []
[gsm.current.phone-type]: []
[gsm.network.type]: [Unknown]
[gsm.operator.alpha]: []
[gsm.operator.iso-country]: []
[gsm.operator.isroaming]: [false]
[gsm.operator.numeric]: []
[gsm.ril.delay]: []
[gsm.sim.operator.alpha]: []
[gsm.sim.operator.iso-country]: []
[gsm.sim.operator.numeric]: []
[gsm.sim.state]: [NOT_READY]
[hw.backlight.dev]: [pwm-backlight.]
[hwc.enable_dither]: []
[hwc.stretch.filter]: []
[init.svc.adbd]: [running]
[init.svc.bootanim]: [stopped]
[init.svc.console]: [running]
[init.svc.debuggerd]: [running]
[init.svc.drm]: [running]
[init.svc.healthd]: [running]
[init.svc.installd]: [running]
[init.svc.keystore]: [running]
[init.svc.lmkd]: [running]
[init.svc.logd]: [running]
[init.svc.media]: [running]
[init.svc.netd]: [running]
[init.svc.ril-daemon]: [running]
[init.svc.sdcard]: [running]
[init.svc.servicemanager]: [running]
[init.svc.surfaceflinger]: [running]
[init.svc.ueventd]: [running]
[init.svc.vold]: [running]
[init.svc.watchdogd]: [running]
[init.svc.wifi_mac]: [stopped]
[init.svc.zygote]: [running]
[media.omxgm.enable-player]: []
[media.omxgm.enable-record]: []
[media.omxgm.enable-scan]: []
[media.wfd.video-bitrate]: []
[net.bt.name]: [Android]
[net.change]: [net.qtaguid_enabled]
[net.hostname]: [android-83a3ccab22cf4b3e]
[net.qtaguid_enabled]: []
[net.tcp.default_init_rwnd]: []
[persist.sampling_profiler]: []
[persist.sys.dalvik.vm.lib.]: [libart.so]
[persist.sys.profiler_ms]: []
[persist.sys.strictmode.disable]: []
[persist.sys.strictmode.visual]: []
[persist.sys.usb.config]: [mtp,adb]
[ro.FSL_AAC_PARSER]: []
[ro.FSL_ASF_PARSER]: []
[ro.FSL_AVI_PARSER]: []
[ro.FSL_FLAC_PARSER]: []
[ro.FSL_FLV_PARSER]: []
[ro.FSL_MKV_PARSER]: []
[ro.FSL_MPG2_PARSER]: []
[ro.FSL_REAL_PARSER]: []
[ro.adb.secure]: []
[ro.allow.mock.location]: []
[ro.baseband]: [unknown]
[ro.board.platform]: [imx6]
[ro.boot.console]: [ttymxc0]
[ro.boot.hardware]: [freescale]
[ro.boot.selinux]: [disabled]
[ro.boot.serialno]: [102231d4e6b416f0]
[ro.boot.storage_type]: [emmc]
[ro.bootloader]: [unknown]
[ro.bootmode]: [unknown]
[ro.build.characteristics]: [tablet]
[ro.build.date.utc]: []
[ro.build.date]: [三 6月 :: CST ]
[ro.build.description]: [sabresd_6dq-user 5.1. 2.1.-ga-rc3 release-keys]
[ro.build.display.id]: [2.1.-ga-rc3 release-keys]
[ro.build.fingerprint]: [Freescale/sabresd_6dq/sabresd_6dq:5.1./2.1.-ga-rc3/:user/release-keys]
[ro.build.flavor]: [sabresd_6dq-user]
[ro.build.host]: [imx6]
[ro.build.id]: [2.1.-ga-rc3]
[ro.build.product]: [sabresd_6dq]
[ro.build.tags]: [release-keys]
[ro.build.type]: [user]
[ro.build.user]: [lee]
[ro.build.version.all_codenames]: [REL]
[ro.build.version.base_os]: []
[ro.build.version.codename]: [REL]
[ro.build.version.incremental]: []
[ro.build.version.release]: [5.1.]
[ro.build.version.sdk]: []
[ro.build.version.security_patch]: [--]
[ro.carrier]: [unknown]
[ro.config.alarm_alert]: [Alarm_Classic.ogg]
[ro.config.notification_sound]: [OnTheHunt.ogg]
[ro.crypto.state]: [unencrypted]
[ro.dalvik.vm.native.bridge]: []
[ro.debuggable]: []
[ro.factorytest]: []
[ro.hardware.lightsensor]: [/sys/class/i2c-dev/i2c-/device/-/]
[ro.hardware]: [freescale]
[ro.lightsensor.threshold]: []
[ro.opengles.version]: []
[ro.product.board]: [SABRESD]
[ro.product.brand]: [Freescale]
[ro.product.cpu.abi2]: [armeabi]
[ro.product.cpu.abi]: [armeabi-v7a]
[ro.product.cpu.abilist32]: [armeabi-v7a,armeabi]
[ro.product.cpu.abilist64]: []
[ro.product.cpu.abilist]: [armeabi-v7a,armeabi]
[ro.product.device]: [sabresd_6dq]
[ro.product.locale.language]: [en]
[ro.product.locale.region]: [US]
[ro.product.manufacturer]: [Freescale]
[ro.product.model]: [SABRESD-MX6DQ]
[ro.product.name]: [sabresd_6dq]
[ro.revision]: []
[ro.ril.wake_lock_timeout]: []
[ro.runtime.firstboot]: []
[ro.secure]: []
[ro.serialno]: [102231d4e6b416f0]
[ro.sf.hwrotation]: []
[ro.sf.lcd_density]: []
[ro.soc]: [i.MX6DL]
[ro.tether.denied]: [false]
[ro.wifi.channels]: []
[rw.VIDEO_RENDER_NAME]: [video_render.surface]
[selinux.reload_policy]: []
[service.bootanim.exit]: []
[sys.boot_completed]: []
[sys.emulated.battery]: []
[sys.interactive]: [active]
[sys.sysctl.extra_free_kbytes]: []
[sys.usb.config]: [mtp,adb]
[sys.usb.state]: [mtp,adb]
[vold.post_fs_data_done]: []
[wifi.ap.interface]: [wlan0]
[wifi.interface]: [wlan0]
[wlan.interface]: [wlan0]