Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,782,778 Members 38,368 Now Online
XDA Developers Android and Mobile Development Forum

[Q] bash breaks init.d

Tip us?
 
Vincent F.
Old
#1  
Junior Member - OP
Thanks Meter 1
Posts: 3
Join Date: May 2014
Default [Q] bash breaks init.d

Hi,

I wanted to have bash as standardshell, so I replaced /system/bin/sh with a symlink to bash. That worked pretty well except it didnīt load the configuration file. So i replaced it with this script:
Code:
#!/system/bin/bash
exec /system/bin/bash --rcfile /etc/profile
this works correctly, but it seems to break init.d support. At least it no longer mounts my second sdcard partition (for link2sd).
does anybody no how to fix this?

cheers,
Vincent
 
Lgrootnoob
Old
#2  
Lgrootnoob's Avatar
Senior Member
Thanks Meter 104
Posts: 470
Join Date: Oct 2012
Location: Dallas

 
DONATE TO ME
Quote:
Originally Posted by Vincent F. View Post
Hi,

I wanted to have bash as standardshell, so I replaced /system/bin/sh with a symlink to bash. That worked pretty well except it didnīt load the configuration file. So i replaced it with this script:
Code:
#!/system/bin/bash
exec /system/bin/bash --rcfile /etc/profile
this works correctly, but it seems to break init.d support. At least it no longer mounts my second sdcard partition (for link2sd).
does anybody no how to fix this?

cheers,
Vincent
i think its because you replaced a binary with a script and init.d fed code straight to the binary. whereas the script you replaced it with has no entry point for the init.d code.
No need to download the whole android sdk or put adb in your path anymore!
Just extract my tool and run the adbClientLaunch script.
To get started go here >
http://forum.xda-developers.com/show...ight=adbclient
My name is Jacob Lane but I prefer to go by Lgrootnoob. (You may also know me as Faelo the music producer)

What have I created? See here:
 
adbClient
Lg Lucid 2 root and other random contributions to the forums here
 
Vincent F.
Old
#3  
Junior Member - OP
Thanks Meter 1
Posts: 3
Join Date: May 2014
Quote:
Originally Posted by Lgrootnoob View Post
i think its because you replaced a binary with a script and init.d fed code straight to the binary. whereas the script you replaced it with has no entry point for the init.d code.
Thanks, that solved it. for all with the same problem heres the code:
Code:
#!/system/bin/bash
exec /system/bin/bash --rcfile /etc/profile $*
cheers,
Vincent
The Following User Says Thank You to Vincent F. For This Useful Post: [ Click to Expand ]
 
Lgrootnoob
Old
#4  
Lgrootnoob's Avatar
Senior Member
Thanks Meter 104
Posts: 470
Join Date: Oct 2012
Location: Dallas

 
DONATE TO ME
Quote:
Originally Posted by Vincent F. View Post
Thanks, that solved it. for all with the same problem heres the code:
Code:
#!/system/bin/bash
exec /system/bin/bash --rcfile /etc/profile $*
cheers,
Vincent
No need to download the whole android sdk or put adb in your path anymore!
Just extract my tool and run the adbClientLaunch script.
To get started go here >
http://forum.xda-developers.com/show...ight=adbclient
My name is Jacob Lane but I prefer to go by Lgrootnoob. (You may also know me as Faelo the music producer)

What have I created? See here:
 
adbClient
Lg Lucid 2 root and other random contributions to the forums here
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes