[MOD][Init.d] for Samsung Galaxy Core 2 [SM-G355H] - Samsung Galaxy Core

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
What is Init.d?
Init.d is a feature which allows you to run brunch of scripts at boot . Thats really useful while you want to set values which reset at boot or run/do any thing at every boot or install tweaks , engines and....
Click to expand...
Click to collapse
Here is the stock kernel Init.d support for Samsung Galaxy Core 2 SM-G355H
What is needed :
1. custom recovery - Preferred My Ported custom recovery with full SELinux support.
2. Busybox pre installed or install BusyBox 1.23 update script just because it use busybox run-parts command to execute the scripts from /system/etc/init.d directory.
Click to expand...
Click to collapse
The ramdisk init.rc have new service usrinit :
Code:
service sysinit /system/bin/logwrapper /system/xbin/busybox run-parts /system/etc/init.d
disabled
oneshot
First it set the scripts permissions in /system/etc/init.d as executable, and then the run-parts launch them all.
How to :
1. Download init.d_by_Dhruvit_G355H.zip and place it in Sdcard.
2. Go to Recovery and choose install zip from sdcard.
3. Select init.d_by_Dhruvit_G355H.zip
4. Enjoy!!
Click to expand...
Click to collapse
Update - [Updated]init.d_by_Dhruvit_G355H.zip
After the boot check the file /data/Test.log and check if the installation succeeded.
Warning :
Backup your kernel ( Boot ) first and then test it !
Feel free to post some. Hit thanks if it works !
Regards !

Tell me if it works or not

I tried it . But how can i know its installed successfully i dont found file data/local/tmp/test.log
Sent from my SM-G355H using XDA Free mobile app

Sorry by mistake written /data/local/tmp it is /data/

Thanks bro .it works:thumbup:
Sent from my SM-G355H using XDA Free mobile app

help me
can any tell me why we need this and what work its will do..?

it runs scripts which can be edited,deleted,created at any time . if you do not have init.d then you have to edit boot.img everytime . and it can zipalign apps at every boot

hi there, nice job u're doing. I have a question, how can I disable a certain script to avoid it to load once I already installed it via recovery?
Thanks in advance!

go to init.d folder and remove the script which you do not want or change its permission

Hello, Can we have the kernel updated with the latest stock kernel?
or atleast give us the instructions and the initrd command lines and info

This post should be moved to the new Core II forum: http://forum.xda-developers.com/t/galaxy-core-2

How?

1) I didnot backup my kernal (BOOT) before testing it. My phone now switches on but it shows NO SIM CARD. Not able to install New Apps. How to get back my phone as per its factory make. Pls help.
2) U already replied to white enregy that "go to init.d folder and remove the script which you do not want or change its permission". How can I do it now since I dont have an app to go to init.d folder. pLs Help help. Thanks in advance.

you can use ES File Manager or Root Explorer and to fix this problem i will update the boot.img to latest version.

Related

[MOD] Add init.d Scripting Support

I didn't make this, the original creator is "DooMLoRD", I just found that it works for our version of the One X as well!
DooMLoRD said:
[ 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!
Please note that some custom ROMs/Kernels already have this feature... This addon is ment to be used on STOCK ROM...
[ requirements ]
stock rooted ROM
windows PC with adb drivers installed
[ how to install ]
download the provided zip package
save it on c:\
extract the contents of the package
connect phone with usb debugging active to PC via ADB
execute "runme.bat"
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:
corrected /system/bin/sysint file
run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
correct /system/etc/install-recovery.sh file (this file gets executed by default on stock kernel too!)
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 ]
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
PAYPAL DONATION LINK
[ download link ]
generic-init.d-support-v01.zip (mirror)
MD5HASH: 4cd2606280524aa96af9d486ce90ea7e
OR
generic-init.d-support-v01.zip
MD5HASH: 2eda273af4b91c34f868807820cceaee
let me know how it goes!
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
ENJOY!
Click to expand...
Click to collapse
So just follow the instructions after downloading the package below. I'll try making a CWM flashable file when I get home.
I will also port over some nice CPU scaling tweaks from my other devices and some nice maintenance scripts.
So how does this do this without modding init.rc in ramdisk? Or does it? I cant look, just wondering how it works.
scrosler said:
So how does this do this without modding init.rc in ramdisk? Or does it? I cant look, just wondering how it works.
Click to expand...
Click to collapse
He's running sysinit via /system/etc/install-recovery.sh
Very nice!
Thanks for sharing this useful script. it worked for me on MIUI Sensation sense base rom.

init.d support xperia M2 lollipop

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
1.- Requirements:
- Root
- Android 5.1.1
- Unlocked & locker bootloader
- Busybox
2.- Download the file to leave on the following link: Download
3.- and decompressed on your xperia
4.- use applications that leave the pack and install the application and concenden busybox root and give permissions to install
5.- and install the application busybox checker to find out if in your xperia ah busybox installed correctly
6.- now you are going to edit the file located in the /system /etc/
Code:
init.qcom.post_boot.sh
7.- and add the following line in the file opened
Code:
/system/xbin/busybox run-parts /system/etc/init.d
8.- Now create a folder called init.d with the following permissions
9.- the file that I download above comes a place it in the folder init.d the following file permissions
10.- android variable path
Code:
PATH /sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin
11.- Now just restart your phone and create script as needed to optimize what you want :fingers-crossed: :good:
Note: the script that were never worked before in my terminal with this method that I bring everything works correctly
If you install/flash Xperia M2 5.1.1 RIC disabler, it'll also do all of that for you, so I don't get the point of making another tutorial for it. ¯\_(ツ)_/¯
I did not know there was a tool but carries it another mobile so neither the case with your comments please edit it because it misreads thanks
If ric disable do that work, its useless you tutorial, and for others devices with qualcom they can use the zip on this thread easy and simple
at no time it was to disable ric init.d this is to support the device please read and do not mix topics other than the Xperia M2 thanks
linuxct said:
If you install/flash Xperia M2 5.1.1 RIC disabler, it'll also do all of that for you, so I don't get the point of making another tutorial for it. ¯\_(ツ)_/¯
Click to expand...
Click to collapse
kaiiori said:
I did not know there was a tool but carries it another mobile so neither the case with your comments please edit it because it misreads thanks
Click to expand...
Click to collapse
I don't think I should edit it. I'm just saying that this thread is pretty useless since, for the Xperia M2 (I think we're all talking about the same device, right?), to edit /system in LOLLIPOP and KK, you NEED to disable RIC, and to do that, you need to use that tool. That tool installs the init.d support, so, there's no need to do that all over again since the tool does it for you, either via command line, or via flashable zip, no need to touch the files by your own
I just wanted to clarify this because, I'm pretty sure some people that have flashed/installed the RIC Disabler had no idea they already had init.d, and they're going to follow this and screw something up... Just saying

Recent root problems on my L04 Marshmallow B820

I had the problem, I couldn't root my phone after the update from B521 to the latest B820 version.
I tried out SuperSu versions 2.65 till 2.74.
After rooting through TWRP, I always got bootloops and after unrooting the system starts normally.
As a last try, I looked into the install script and set the "SYSTEMLESS" var to "true".
Now I've got a rooted and starting phone.
So I think there must be a problem, at least for me, with automatically detecting a systemless installable Android version in SuperSu from chainfire at Honor 6, as I understand.
Did anyone else have that problem?
I added SYSTEMLESS=true in /META-INF/com/google/android/update-binary within SuperSu-v2.65.zip, just as described there, but it should defaults to true after proper detecting without this.
At my B521 system, I used SuperSu version 2.52, which worked there and wasn't booting at Marshmallow, too.
Install 2.62
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Sent from my H60-L04 using Tapatalk
What Tools did you use? The multi tool doesn't have emui 4 on L04 yet
gammaanimal said:
What Tools did you use? The multi tool doesn't have emui 4 on L04 yet
Click to expand...
Click to collapse
Flash it using TWRP recovery...
Sent from my H60-L04 using Tapatalk
The Multi Tool says for TWRP L02 and L12, can I also install it on L04?
I've installed SuperSu 2.74 via fastboot/TWRP, but as I wrote, only with an modified updater-script, the system boots up. (for me, not sure why and maybe this can help others)
Machredsch said:
I've installed SuperSu 2.74 via fastboot/TWRP, but as I wrote, only with an modified updater-script, the system boots up. (for me, not sure why and maybe this can help others)
Click to expand...
Click to collapse
I think I have exactly the same issue, could you upload your modified supersu.zip for me or walk me through the modifications?
That'd be swell.
hagehagen said:
I think I have exactly the same issue, could you upload your modified supersu.zip for me or walk me through the modifications?
That'd be swell.
Click to expand...
Click to collapse
Have tested it today with latest stable SuperSu, which is v2.76-20160630161323.
-> open the archive with an archive-manager
-> go to /META-INF/com/google/android/ directory
-> edit update-binary with a text editor (your text editor should respect linux line breaks (LF), so if you're on windows, you have to make sure this, I think)
-> after the commented section(all lines with a # beginning), where you can read about possible system vars and beyond,
you have to set the SYSTEMLESS variable to true like in the following example of code:
Code:
...
# if needed. It must replace the input file and return a 0 exit code.
[COLOR="Red"]SYSTEMLESS=true[/COLOR]
OUTFD=$2
...
Line 2, you have to insert to achieve an systemless installation, which seems to be the only way for you and me to make it work.
Please make sure to pay attention to upper/lower case, because otherwise it will fail.
-> save the updated zip and install it via TWRP, e.g. via sideload
Hope, this was usefully.
Note: This is only usefull for Marshmallow as described in the file, because it will not work below.
If you leave TWRP afterwards, e.g. for reboot and it asks you for installing root, click on "Do not install".

[ ZIP INSTALLER - Mount as RW ] Dynamic Installer V3.4 [ Android 10+ or earlier ]

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
ABOUT THIS:
Recovery or Magisk module installer compatible with multiple Android devices such as different types of partitions, both traditional and new partitions (Focused on the creation of normal and universal flash files)
MOVED TO:
[ZIP - Dual Installer] Dynamic Installer Stable 4.7-b3 [ Android 10+ or earlier ]
SUPPORT: TELEGRAM CHANNEL - TELEGRAM GROUP - SUPPORT ME ABOUT THIS: With this you can make Automatic Installers (.ZIP flash files) for All Android devices without limitations (Supports an installation from Recovery or can be used to create a...
forum.xda-developers.com
None
DOWNLOADS​
Moved to:
[ZIP - Dual Installer] Dynamic Installer Stable 4.7-b3 [ Android 10+ or earlier ]
SUPPORT: TELEGRAM CHANNEL - TELEGRAM GROUP - SUPPORT ME ABOUT THIS: With this you can make Automatic Installers (.ZIP flash files) for All Android devices without limitations (Supports an installation from Recovery or can be used to create a...
forum.xda-developers.com
.... reserved
All I want to do is provide R/W access for /product/media/audio and everything in that folder including /ringtones . Can you please explain the steps this script can do to accomplish that. And please, act like I'm a 5 year old because I couldn't get the script to work. Currently working with a Moto One 5G Ace. Thank you very much.
Articul8Madness said:
All I want to do is provide R/W access for /product/media/audio and everything in that folder including /ringtones . Can you please explain the steps this script can do to accomplish that. And please, act like I'm a 5 year old because I couldn't get the script to work. Currently working with a Moto One 5G Ace. Thank you very much.
Click to expand...
Click to collapse
This script is executed from recovery, to mount system, vendor and product just use auto_mount_partitions in updater-script
BlassGO said:
This script is executed from recovery, to mount system, vendor and product just use auto_mount_partitions in updater-script
Click to expand...
Click to collapse
My phone does not have a custom recovery. How can this be solved and ran as a script inside of android via termux or linux?
how to use this script?
flash from recovery or use terminal or whatever.
sorry for the stupid question please explain better how to use it thank you very much
ale82to said:
how to use this script?
flash from recovery or use terminal or whatever.
sorry for the stupid question please explain better how to use it thank you very much
Click to expand...
Click to collapse
Hi, it depends what u want, its an installer with multiple uses, but if u only want to mount the main partitions as RW, add auto_mount_partitions to the updater-script and then flash it (Partitions will stay mounted while u in recovery after flashing)
PRO
el0xren said:
PRO
Click to expand...
Click to collapse
Thx

Looking for a guide or tutorial to modify init stuff

Hello,
I have a pixel 6a with Android 13. I'm trying to start a hello world service/daemon that just loops at boot.
From what I've been reading, it seems like I have to add a rc file to /system/etc/something(?). I tried to add a rc file to it, but it's read-only
So it seems like I have two choices. Download a factory image, unpack system.img, mount it, add a rc file, repack it, and flash it or add cpio file to boot.img like Magisk.
Am I understanding this right or is there a simpler way?
Thanks!
Look inside here:
[GUIDE] How To Add Init.d Support to Your Kernel & Rom
What is init.d ? Init.d is a feature which allows you to run brunch of scripts at boot . Thats really useful while you want to set values which reset at boot or run/do any thing at every boot or install tweaks , engines and.... There are some...
forum.xda-developers.com
jwoegerbauer said:
Look inside here:
[GUIDE] How To Add Init.d Support to Your Kernel & Rom
What is init.d ? Init.d is a feature which allows you to run brunch of scripts at boot . Thats really useful while you want to set values which reset at boot or run/do any thing at every boot or install tweaks , engines and.... There are some...
forum.xda-developers.com
Click to expand...
Click to collapse
looks like a very old guide, though...
Will it work with newer Android versions (e.g: 13)?
Take note that the Android platform consists of the Linux kernel and the Android API Framework.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
When a mobile device gets powered o then as 1st thing the Linux kernel gets loaded and its code gets processed - and not the Android framework, hence at this time it's irrelevant what Android OS version - what gets loaded and its code gets processed after boot-up is completed - is present on moile device.
jwoegerbauer said:
Look inside here:
[GUIDE] How To Add Init.d Support to Your Kernel & Rom
What is init.d ? Init.d is a feature which allows you to run brunch of scripts at boot . Thats really useful while you want to set values which reset at boot or run/do any thing at every boot or install tweaks , engines and.... There are some...
forum.xda-developers.com
Click to expand...
Click to collapse
Thanks for the guide!
But will it work on Android 13 though?
I know boot.img for Android 13 no longer contains system stuff

Categories

Resources