ASUS EEE PC init.rc 파일
Android :
2010. 2. 18. 18:50
반응형
출처 : http://gitorious.org/android-eeepc/eee_701/blobs/e3536193871099cb4425c0ecab8efce39943b636/init.rc
1 | |
2 | on init |
3 | |
4 | sysclktz 0 |
5 | |
6 | loglevel 3 |
7 | |
8 | # setup the global environment |
9 | export PATH /sbin:/system/sbin:/system/bin:/system/xbin |
10 | export LD_LIBRARY_PATH /system/lib |
11 | export ANDROID_BOOTLOGO 1 |
12 | export ANDROID_ROOT /system |
13 | export ANDROID_ASSETS /system/app |
14 | export ANDROID_DATA /data |
15 | export EXTERNAL_STORAGE /sdcard |
16 | export BOOTCLASSPATH /system/framework/core.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/android.policy.jar:/system/framework/services.jar |
17 | |
18 | # Backward compatibility |
19 | symlink /system/etc /etc |
20 | |
21 | # create mountpoints and mount tmpfs on sqlite_stmt_journals and debugfs on d |
22 | mkdir /d |
23 | mkdir /sdcard 0000 system system |
24 | mkdir /system |
25 | mkdir /data 0771 system system |
26 | mkdir /cache 0770 system cache |
27 | mkdir /sqlite_stmt_journals 01777 root root |
28 | mount tmpfs tmpfs /sqlite_stmt_journals size=4m |
29 | mount debugfs debugfs /d |
30 | |
31 | mount rootfs rootfs / ro remount |
32 | |
33 | write /proc/sys/kernel/panic_on_oops 1 |
34 | write /proc/sys/kernel/hung_task_timeout_secs 0 |
35 | write /proc/cpu/alignment 4 |
36 | write /proc/sys/kernel/sched_latency_ns 10000000 |
37 | write /proc/sys/kernel/sched_wakeup_granularity_ns 2000000 |
38 | |
39 | # mount mtd partitions |
40 | # TODO: this should be mounted by fs vol id (i.e. /dev/block-by-volid/system), |
41 | # once init gets that functionality. |
42 | mount ext3 /dev/block/sda6 /system |
43 | mount ext3 /dev/block/sda6 /system ro remount |
44 | |
45 | # We chown/chmod /data again so because mount is run as root + defaults |
46 | mount ext3 /dev/block/sda8 /data |
47 | chown system system /data |
48 | chmod 0771 /data |
49 | |
50 | # Same reason as /data above |
51 | mount ext3 /dev/block/sda5 /cache |
52 | chown system cache /cache |
53 | chmod 0770 /cache |
54 | |
55 | # This may have been created by the recovery system with odd permissions |
56 | chown system system /cache/recovery |
57 | chmod 0770 /cache/recovery |
58 | |
59 | # create basic filesystem structure |
60 | mkdir /data/misc 01771 system misc |
61 | mkdir /data/misc/hcid 0770 bluetooth bluetooth |
62 | mkdir /data/local 0771 shell shell |
63 | mkdir /data/local/tmp 0771 shell shell |
64 | mkdir /data/data 0771 system system |
65 | mkdir /data/app-private 0771 system system |
66 | mkdir /data/app 0771 system system |
67 | mkdir /data/property 0700 root root |
68 | |
69 | # create dalvik-cache and double-check the perms |
70 | mkdir /data/dalvik-cache 0771 system system |
71 | chown system system /data/dalvik-cache |
72 | chmod 0771 /data/dalvik-cache |
73 | |
74 | # create the lost+found directories, so as to enforce our permissions |
75 | mkdir /data/lost+found 0770 |
76 | mkdir /cache/lost+found 0770 |
77 | |
78 | # double check the perms, in case lost+found already exists, and set owner |
79 | chown root root /data/lost+found |
80 | chmod 0770 /data/lost+found |
81 | chown root root /cache/lost+found |
82 | chmod 0770 /cache/lost+found |
83 | |
84 | |
85 | ### Load some modules |
86 | insmod /lib/modules/atl2.ko |
87 | insmod /lib/modules/softcursor.ko |
88 | insmod /lib/modules/bitblit.ko |
89 | insmod /lib/modules/font.ko |
90 | insmod /lib/modules/cfbimgblt.ko |
91 | insmod /lib/modules/cfbfillrect.ko |
92 | insmod /lib/modules/cfbcopyarea.ko |
93 | insmod /lib/modules/drm.ko |
94 | insmod /lib/modules/i915.ko modeset=1 |
95 | insmod /lib/modules/fbcon.ko |
96 | |
97 | on boot |
98 | # basic network init |
99 | ifup lo |
100 | hostname localhost |
101 | domainname localdomain |
102 | |
103 | # set RLIMIT_NICE to allow priorities from 19 to -20 |
104 | setrlimit 13 40 40 |
105 | |
106 | # Define the oom_adj values for the classes of processes that can be |
107 | # killed by the kernel. These are used in ActivityManagerService. |
108 | setprop ro.FOREGROUND_APP_ADJ 0 |
109 | setprop ro.VISIBLE_APP_ADJ 1 |
110 | setprop ro.SECONDARY_SERVER_ADJ 2 |
111 | setprop ro.HOME_APP_ADJ 4 |
112 | setprop ro.HIDDEN_APP_MIN_ADJ 7 |
113 | setprop ro.CONTENT_PROVIDER_ADJ 14 |
114 | setprop ro.EMPTY_APP_ADJ 15 |
115 | |
116 | # Define the memory thresholds at which the above process classes will |
117 | # be killed. These numbers are in pages (4k). |
118 | setprop ro.FOREGROUND_APP_MEM 1536 |
119 | setprop ro.VISIBLE_APP_MEM 2048 |
120 | setprop ro.SECONDARY_SERVER_MEM 4096 |
121 | setprop ro.HOME_APP_MEM 4096 |
122 | setprop ro.HIDDEN_APP_MEM 8192 |
123 | setprop ro.CONTENT_PROVIDER_MEM 8704 |
124 | setprop ro.EMPTY_APP_MEM 16384 |
125 | |
126 | # Write value must be consistent with the above properties. |
127 | write /sys/module/lowmemorykiller/parameters/adj 0,1,2,7,14,15 |
128 | |
129 | write /proc/sys/vm/overcommit_memory 1 |
130 | write /sys/module/lowmemorykiller/parameters/minfree 1536,2048,4096,8192,8704,16384 |
131 | |
132 | # Set init its forked children's oom_adj. |
133 | write /proc/1/oom_adj -16 |
134 | |
135 | # Permissions for System Server and daemons. |
136 | chown radio system /sys/android_power/state |
137 | chown radio system /sys/android_power/request_state |
138 | chown radio system /sys/android_power/acquire_full_wake_lock |
139 | chown radio system /sys/android_power/acquire_partial_wake_lock |
140 | chown radio system /sys/android_power/release_wake_lock |
141 | chown system system /sys/class/timed_output/vibrator/enable |
142 | chown system system /sys/class/leds/keyboard-backlight/brightness |
143 | chown system system /sys/class/leds/lcd-backlight/brightness |
144 | chown system system /sys/class/leds/button-backlight/brightness |
145 | chown system system /sys/class/leds/red/brightness |
146 | chown system system /sys/class/leds/green/brightness |
147 | chown system system /sys/class/leds/blue/brightness |
148 | chown system system /sys/class/leds/red/device/grpfreq |
149 | chown system system /sys/class/leds/red/device/grppwm |
150 | chown system system /sys/class/leds/red/device/blink |
151 | chown system system /sys/class/leds/red/brightness |
152 | chown system system /sys/class/leds/green/brightness |
153 | chown system system /sys/class/leds/blue/brightness |
154 | chown system system /sys/class/leds/red/device/grpfreq |
155 | chown system system /sys/class/leds/red/device/grppwm |
156 | chown system system /sys/class/leds/red/device/blink |
157 | chown system system /sys/class/timed_output/vibrator/enable |
158 | chown system system /sys/module/sco/parameters/disable_esco |
159 | chown system system /sys/kernel/ipv4/tcp_wmem_min |
160 | chown system system /sys/kernel/ipv4/tcp_wmem_def |
161 | chown system system /sys/kernel/ipv4/tcp_wmem_max |
162 | chown system system /sys/kernel/ipv4/tcp_rmem_min |
163 | chown system system /sys/kernel/ipv4/tcp_rmem_def |
164 | chown system system /sys/kernel/ipv4/tcp_rmem_max |
165 | chown root radio /proc/cmdline |
166 | |
167 | # Define TCP buffer sizes for various networks |
168 | # ReadMin, ReadInitial, ReadMax, WriteMin, WriteInitial, WriteMax, |
169 | setprop net.tcp.buffersize.default 4096,87380,110208,4096,16384,110208 |
170 | setprop net.tcp.buffersize.wifi 4095,87380,110208,4096,16384,110208 |
171 | setprop net.tcp.buffersize.umts 4094,87380,110208,4096,16384,110208 |
172 | setprop net.tcp.buffersize.edge 4093,26280,35040,4096,16384,35040 |
173 | setprop net.tcp.buffersize.gprs 4092,8760,11680,4096,8760,11680 |
174 | |
175 | class_start default |
176 | |
177 | ## Daemon processes to be run by init. |
178 | ## |
179 | service console /system/bin/sh |
180 | console |
181 | |
182 | # adbd is controlled by the persist.service.adb.enable system property |
183 | service adbd /sbin/adbd |
184 | disabled |
185 | |
186 | on property:persist.service.adb.enable=1 |
187 | start adbd |
188 | |
189 | on property:persist.service.adb.enable=0 |
190 | stop adbd |
191 | |
192 | service servicemanager /system/bin/servicemanager |
193 | user system |
194 | critical |
195 | onrestart restart zygote |
196 | onrestart restart media |
197 | |
198 | service vold /system/bin/vold |
199 | socket vold stream 0660 root mount |
200 | |
201 | service zygote /system/bin/app_process -Xzygote /system/bin --zygote --start-system-server |
202 | socket zygote stream 666 |
203 | onrestart write /sys/android_power/request_state wake |
204 | disabled |
205 | |
206 | service media /system/bin/mediaserver |
207 | user media |
208 | group system audio camera graphics inet net_bt net_bt_admin |
209 | |
210 | service installd /system/bin/installd |
211 | socket installd stream 600 system system |
반응형
'Android' 카테고리의 다른 글
JNI on Android (0) | 2010.02.19 |
---|---|
삼성 S3C6410 GPIO Pin 관련 (0) | 2010.02.18 |
우분투 9.10 Ubuntu 9.10 에서 안드로이드 Android 개발 (0) | 2010.02.18 |