scripts in my init.d folder are not starting, those in su.d work fine, I have installed uni-init to test and everything looks good,anyone any ideas ?
The script 00test which will create a log in /data, put the script in init.d it does not work, move it to su.d and rename it 00test.sh and it runs and generates a log in /data
I am on slimsaber which has init.d support and the app reports that everything is working, scripts in init.d do not work but manually running them does
Correct permissions etc
latest busybox 1.23.2
Also going to /system/etc/init.d and running the script manually works,just not at startup like it meant to.
Can you please use System Manager to see if Scripts do get executed at Boot ? Alternatively Script Manager is also a good test.
If one or both fail then there's a chance your kernel does not look in init.d and you'd need to look into some sort of insmod option or continue Script manager.
Thanks for the pointers,sorry dont understand how to check with system manager? is that an app ? Am using slimsaber and ak's kernel which is meant to have support, it seems like the init.d folder is definitely not being allowed to run at boot, odd that su.d is working, as I said I can run the script and it works, just not at startup
Can you Try SManager AKA Script Manager ?
Meant to say [APP 2.1+] System Tuner not Manager.
su mkdir /data/logs chmod 0777 /data/logs touch /data/logs/startup.log
echo $(date) $0 >> /data/logs/startup.log
**UPDATE: v3 is out now! Android 4.3 compatible!
**Term-init is also used in Droid Manager!!!**
**Featured in the XDA News Portal: Init.d Support for Any Rooted Phone (Thanks to the_scotsman!)
Hi guys...as stated in the title above, I have created a script to be ran in terminal emulator so that it will enable the support of init.d scripts!!!
**Note...this is only for those who do not have init.d support...if you are using custom kernels (cyanogen mod original kernel etc.) that already supports init.d, you shouldn't run this......but if you accidentally ran this, it is ok...won't mess up anything...
init.d support through terminal emulator!!!
What is init.d:
I have recently learnt some linux scripting and was searching for a method to enable init.d scripts support for my phone which has a stock kernel. Inspired by this thread by iridaki, I finally managed to get init.d working in my phone!!! However, I thought of the other users who still do not have a proper custom recovery...how are they gonna flash zip packages? And if it has to be done manually, it requires a lot of typing, changing file permissions etc....a very tedious process...
Therefore, I've decided to come up with a script to automate this process!!! *Drum rolls*...lol
Do I have init.d support?:
Well, here is a way to test:
1. Download the file from here: Attachment 1612958
2. Extract the file, you will get a file named 00test. DO NOT flash!
3. Paste it into /etc/init.d. If there is no init.d folder, most probably you DO NOT have init.d support. However, if you still wanna try, just create the folder named "init.d"
4. Change the permissions of the init.d folder and 00test into rwxrwxrwx.
6. If you see a file named Test.log in /data, you have init.d support. If not, you will have to run Uni-init, Term-init or Zip-init.
- Auto checks for required files [v2]
- Utilises install-recovery.sh (if your kernel supports that, but of course, but most do...) to enable init.d scripts (busybox run-parts required)
- Will move install-recovery.sh to install-recovery-2.sh if it already exists and call it from the main install-recovery.sh (will not replace install-recovery.sh because certain apps such as Link2SD requires that to work), creates it if it doesn't [v3]
- If Superuser is using install-recovery.sh, will use install-recovery-2.sh instead [v3]
- Creates the init.d folder with correct permissions
- Adds 2 init.d scripts: one for testing (shows time of execution [v2]), another to ensure that the scripts in init.d folder always have the correct permissions
- Adds sysinit in /system/bin, will add the required lines if it already exists. This is for utilising a similar method to enabling init.d in AOSP ROMs
- a rooted phone of course...
- busybox with required applets (especially run-parts), if not sure what is this, just install this by Stericson: Link and please reboot after installing before running this script......use "normal install" method, don't use "smart install"...
- terminal emulator such as this: Link
1. Download the file.
2. Place it in the root of your sdcard directory.
3. Launch terminal emulator.
4. Type: su
5. Grant SuperUser access if prompted
6. Type: sh /sdcard/term-init.sh
7. The script will run and follow the instructions! As simple as that...
**To check whether init.d is working or not, reboot your phone and navigate to /data...you should find a Test.log in there...If it is present, congrats, you have init.d support!
If you have already read all the instructions and understand them, then click here to download:
|app, init.d, stock kernel, terminal emulator|
|Thread Tools||Search this Thread|