diff --git a/bootstat/bootstat.rc b/bootstat/bootstat.rc index f4756d59d..d697efba0 100644 --- a/bootstat/bootstat.rc +++ b/bootstat/bootstat.rc @@ -1,7 +1,39 @@ # This file is the LOCAL_INIT_RC file for the bootstat command. on post-fs-data - mkdir /data/misc/bootstat 0700 root root + mkdir /data/misc/bootstat 0700 system log + # To deal with ota transition resulting from a change in DAC from + # root.root to system.log, may be deleted after ota has settled. + chown system log /data/misc/bootstat/absolute_boot_time + chown system log /data/misc/bootstat/boot_complete + chown system log /data/misc/bootstat/boot_complete_no_encryption + chown system log /data/misc/bootstat/boot_reason + chown system log /data/misc/bootstat/bootime.bootloader.1BLE + chown system log /data/misc/bootstat/bootime.bootloader.1BLL + chown system log /data/misc/bootstat/bootime.bootloader.2BLE + chown system log /data/misc/bootstat/bootime.bootloader.2BLL + chown system log /data/misc/bootstat/bootime.bootloader.AVB + chown system log /data/misc/bootstat/bootime.bootloader.KD + chown system log /data/misc/bootstat/bootime.bootloader.KL + chown system log /data/misc/bootstat/bootime.bootloader.ODT + chown system log /data/misc/bootstat/bootime.bootloader.SW + chown system log /data/misc/bootstat/bootime.bootloader.total + chown system log /data/misc/bootstat/build_date + chown system log /data/misc/bootstat/factory_reset + chown system log /data/misc/bootstat/factory_reset_boot_complete + chown system log /data/misc/bootstat/factory_reset_boot_complete_no_encryption + chown system log /data/misc/bootstat/factory_reset_current_time + chown system log /data/misc/bootstat/factory_reset_record_value + chown system log /data/misc/bootstat/last_boot_time_utc + chown system log /data/misc/bootstat/ota_boot_complete + chown system log /data/misc/bootstat/ota_boot_complete_no_encryption + chown system log /data/misc/bootstat/post_decrypt_time_elapsed + chown system log /data/misc/bootstat/ro.boottime.init + chown system log /data/misc/bootstat/ro.boottime.init.cold_boot_wait + chown system log /data/misc/bootstat/ro.boottime.init.selinux + chown system log /data/misc/bootstat/time_since_factory_reset + chown system log /data/misc/bootstat/time_since_last_boot + # end ota transitional support # Record the time at which the user has successfully entered the pin to decrypt # the device, /data is decrypted, and the system is entering the main boot phase. @@ -10,7 +42,7 @@ on post-fs-data # property:init.svc.bootanim=running: The boot animation is running # property:ro.crypto.type=block: FDE device on post-fs-data && property:init.svc.bootanim=running && property:ro.crypto.type=block - exec - root root -- /system/bin/bootstat -r post_decrypt_time_elapsed + exec - system log -- /system/bin/bootstat -r post_decrypt_time_elapsed # sys.logbootcomplete is a signal to enable the bootstat logging mechanism. # This signaling is necessary to prevent logging boot metrics after a runtime @@ -33,13 +65,13 @@ on property:init.svc.zygote=stopping # Record boot complete metrics. on property:sys.boot_completed=1 && property:sys.logbootcomplete=1 # Record boot_complete and related stats (decryption, etc). - exec - root root -- /system/bin/bootstat --record_boot_complete + exec - system log -- /system/bin/bootstat --record_boot_complete # Record the boot reason. - exec - root root -- /system/bin/bootstat --record_boot_reason + exec - system log -- /system/bin/bootstat --record_boot_reason # Record time since factory reset. - exec - root root -- /system/bin/bootstat --record_time_since_factory_reset + exec - system log -- /system/bin/bootstat --record_time_since_factory_reset # Log all boot events. - exec - root root -- /system/bin/bootstat -l + exec - system log -- /system/bin/bootstat -l