FORUMS
Remove All Ads from XDA

[ADDON][Xperia S] Generic startup/init.d scripts support for Stock ROM/Kernel

13,194 posts
Thanks Meter: 39,785
 
Post Reply Email Thread
[ info ]

i am attaching a easy to run package which contains the files required for full functionality of executing startup scripts (init.d scripts)...

basically this will allow the user to execute custom shell scripts, placed in /system/etc/init.d/ folder and they will be executed on each boot!

i dont have this device yet!!

thanks to Jozinek for testing this on his phone!


[ requirements ]
  1. stock rooted ROM
  2. windows PC with adb drivers installed


[ how to install ]
  1. download the provided zip package
  2. save it on c:\
  3. extract the contents of the package
  4. connect phone with usb debugging active to PC via ADB
  5. execute "runme.bat"
  6. follow onscreen instructions & enjoy!

incase some issue is there post the output/log of script


[ additional info ]

i have added the following things in the package:
  1. corrected /system/bin/sysint file
  2. run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
  3. correct /system/etc/install-recovery.sh file (this file gets executed by default on stock kernel too!)
  4. test/example script /system/etc/init.d/99test

to check if this is working the test script (99test) will create a temporary file /data/local/tmp/init.d_log_test.txt on each boot


[ donations/device fund ]

i dont yet have this device but i plan to buy it.... if u guys want to donate to me to get this device OR if u feel that this work has helped u OR u think that the work i put into making this is worthy of donations, then click on the following link for buying me some coffee/beer/etc

i am currently channeling all my donations to get this phone asap and to avoid selling my ARC!!!


PAYPAL DONATION LINK


[ download link ]

generic-init.d-support-v01.zip
MD5HASH: 2eda273af4b91c34f868807820cceaee

let me know how it goes!




ENJOY!
The Following 30 Users Say Thank You to DooMLoRD For This Useful Post: [ View ] Gift DooMLoRD Ad-Free
15th March 2012, 01:56 PM |#2  
somemadcaaant's Avatar
Senior Member
Thanks Meter: 367
 
More
Nice work, this will enable the Speedy v7 int.d hacks, can you incorporate this in the above? As an addon perhaps.

Done, $50 "AU" dollars coming your way mate.

-smc
The Following 3 Users Say Thank You to somemadcaaant For This Useful Post: [ View ] Gift somemadcaaant Ad-Free
15th March 2012, 02:50 PM |#3  
DooMLoRD's Avatar
OP Inactive Recognized Developer
Flag Pune
Thanks Meter: 39,785
 
Donate to Me
More
Quote:
Originally Posted by somemadcaaant

Nice work, this will enable the Speedy v7 int.d hacks, can you incorporate this in the above? As an addon perhaps.

Done, $50 "AU" dollars coming your way mate.

-smc

this init.d support can be used to execute ANY shell script/program at startup... u are free to choose the ones u want...

if anyone needs help on how to push the scripts onto device let me know... but script specific info i dont have, u will need to ask the developer of those scripts..
The Following User Says Thank You to DooMLoRD For This Useful Post: [ View ] Gift DooMLoRD Ad-Free
21st March 2012, 05:34 AM |#4  
keunhuvac's Avatar
Senior Member
Thanks Meter: 178
 
Donate to Me
More
I used this script to move dalvik cache to /cache folder:
Code:
#!/system/bin/sh
# 
# relocate dalvik-cache to /cache/dalvik-cache

if [ ! -d /cache/dalvik-cache ]
then
    busybox rm -rf /cache/dalvik-cache /data/dalvik-cache
    mkdir /cache/dalvik-cache /data/dalvik-cache
fi

busybox chown 1000:1000 /cache/dalvik-cache
busybox chmod 0771 /cache/dalvik-cache

# create symlink
busybox mount -o bind /cache/dalvik-cache /data/dalvik-cache
busybox chown 1000:1000 /data/dalvik-cache
busybox chmod 0771 /data/dalvik-cache
After reboot i saw folder /cache-dalvid in both folders /data and /cache, is it normal?
Thank!
4th July 2012, 05:45 PM |#5  
Member
Flag Hong Kong
Thanks Meter: 41
 
More
I found that for devices rooted with locked bootloader

Line 21 of runme.bat need to change from

HTML Code:
@files\adb shell "su -c 'busybox mount -t ext4 -o rw,remount /system /system'"
to

HTML Code:
@files\adb shell "su -c 'busybox mount -o remount,rw /system'"
The Following User Says Thank You to imTigger For This Useful Post: [ View ] Gift imTigger Ad-Free
26th August 2012, 11:01 AM |#6  
Miche1asso's Avatar
Senior Member
Flag Treviso
Thanks Meter: 502
 
More
This is all great, exactly what I was looking for! But what about if the ROM already has a custom kernel that makes use of /etc/init.d? Do the /etc/init.d scripts get executed twice?

EDIT: in my phone this solution can't work. In the init.rc file the following lines are commented out


Code:
#service flash_recovery /system/etc/install-recovery.sh
#    oneshot
23rd September 2012, 08:39 AM |#7  
charlymaster's Avatar
Member
Thanks Meter: 26
 
More
Thanks, it's working but I have a question, how we can include this in a rom?

Please respond, I would appreciate that
26th September 2012, 11:30 AM |#8  
Daniel D.'s Avatar
Senior Member
Thanks Meter: 501
 
More
Quote:
Originally Posted by DooMLoRD

  1. run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)

That means I don't need run-parts if I've busybox installed?
26th October 2012, 05:39 PM |#9  
emmanueldmc's Avatar
Senior Member
Flag Distrito Federal
Thanks Meter: 52
 
Donate to Me
More
1-Tell me please if I understand: I've done everything the post says Doomlord ([ADDON] [Xperia S] Generic startup /init.d scripts support for Stock ROM / Kernel) my question is this, after this I can already install scripts from cwm?

2-I try installing ''NullVoid'' tweaK by cmw and apparently well was installed. (I say apparently because i do not know if it is working)

3-Another thing about Tweaks: These have to be installed every time the phone restarts? This tweaks are compatible with the stock ics rom? (With the Doomloard Method ?
6th November 2012, 04:31 PM |#10  
PIRATA!'s Avatar
Senior Member
Flag Pisa, Italy
Thanks Meter: 171
 
Donate to Me
More
Quote:
Originally Posted by DooMLoRD

........

[ additional info ]

i have added the following things in the package:

  1. corrected /system/bin/sysint file
  2. run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
  3. correct /system/etc/install-recovery.sh file (this file gets executed by default on stock kernel too!)
  4. test/example script /system/etc/init.d/99test

to check if this is working the test script (99test) will create a temporary file /data/local/tmp/init.d_log_test.txt on each boot

..........

So the "install-recovery.sh" file is executed by system by default and does not need to be executed manually from terminal or what else?
And about the file...that is not a one-run file...right? It is executed at every phone boot...right??

Thank you.


Sent from my GT-I9000 using xda app-developers app
12th February 2013, 04:01 AM |#11  
chitose_ndy's Avatar
Senior Member
Flag Jakarta
Thanks Meter: 196
 
More
AW: [ADDON][Xperia S] Generic startup/init.d scripts support for Stock ROM/Kernel
Sorry leaving footprint, to see this again after im home.

Gesendet von meinem LT26i mit Tapatalk 2
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes