• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root I need Advanced Help with Updater-Script

argedion

The TechnoFrog
Jun 20, 2011
6,356
6,303
The Infernal Swamp
I have downloaded the latest Beats Audio Flash Zip I was wanting to change the updater-script file to mount system and then unmount system and reboot

This is the Original updater-script

Code:
ui_print(" Beats Audio ");
ui_print(" By: RockoDev ");
ui_print(" Installing... ");
package_extract_dir("system", "/system");
ui_print(" Installed ! ");
ui_print(" Reboot Now ! ");

This is what I am wanting to do:

Code:
ui_print(" Beats Audio ");
ui_print(" By: RockoDev ");
ui_print(" Installing... ");
mount("MTD", "system", "/system");
package_extract_dir("system", "/system");
unmount("/system");
ui_print(" Installed ! ");
ui_print(" Rebooting Now..... Goodbye! ");
run_program("/sbin/reboot");
I get the error "Mount is expecting 4 args got 3. I have tried adding a -w to it to hopefully be the argument it needs but I got Error 7 from that then last attemp I got Error 6 tried to take it back as it is above and got bad file so I figured I need to ask

I've tried changing the update-binary as well but get the bad file error message as well. The above mount has worked for me in the past on other projects
 
I have downloaded the latest Beats Audio Flash Zip I was wanting to change the updater-script file to mount system and then unmount system and reboot

This is the Original updater-script

Code:
ui_print(" Beats Audio ");
ui_print(" By: RockoDev ");
ui_print(" Installing... ");
package_extract_dir("system", "/system");
ui_print(" Installed ! ");
ui_print(" Reboot Now ! ");

This is what I am wanting to do:

Code:
ui_print(" Beats Audio ");
ui_print(" By: RockoDev ");
ui_print(" Installing... ");
mount("MTD", "system", "/system");
package_extract_dir("system", "/system");
unmount("/system");
ui_print(" Installed ! ");
ui_print(" Rebooting Now..... Goodbye! ");
run_program("/sbin/reboot");
I get the error "Mount is expecting 4 args got 3. I have tried adding a -w to it to hopefully be the argument it needs but I got Error 7 from that then last attemp I got Error 6 tried to take it back as it is above and got bad file so I figured I need to ask

I've tried changing the update-binary as well but get the bad file error message as well. The above mount has worked for me in the past on other projects
I'll upload the file I created, and you can compare the script and binary, if you'd like (or I can just upload the binary and script). In mine, I also mount data, for those ROMs (Sense 3.5) where the libs reside on the data partition.

Your mount commands look fine, though.
 
Upvote 0
I'll upload the file I created, and you can compare the script and binary, if you'd like (or I can just upload the binary and script). In mine, I also mount data, for those ROMs (Sense 3.5) where the libs reside on the data partition.

Your mount commands look fine, though.

Hmmm Well its the Nitrous ROM that I'm using with I think is 2.1 because its based of the 4.67 release. but yeah lets see whats going on. I know the mount command works for when building roms and I have changed the update-binary to the latest stock one but still get errors. so I'm just a bit dumbfounded
 
Upvote 0
Hmmm Well its the Nitrous ROM that I'm using with I think is 2.1 because its based of the 4.67 release. but yeah lets see whats going on. I know the mount command works for when building roms and I have changed the update-binary to the latest stock one but still get errors. so I'm just a bit dumbfounded
When you say latest stock binary, where did you get it from? I was suggesting that you take one from a ROM or kernel zip, because the ones from an official OTA will also likely require 4 arguments. Maybe uploading mine will help you find the difference (but I think it's the update-binary).

P.S. The mounting data shouldn't make a difference either way. It just makes the zip work more universally.

EDIT: updater-script & update-binary attached.
 
  • Like
Reactions: argedion
Upvote 0
nope got the same thing. So I started thinking is it the files or is it my recovery (Amon RA Style 3.11) I'm going to flash 2.3 and see if it works then. One more thing I want to ask to make sure I'm not screwing up the Zip is in compression and not in Store mode correct?

EDIT: Flashed back to Amon RA 2.3 got the same error. So that wasn't the issue. Ok so running out of ideas here.
 
Upvote 0
nope got the same thing. So I started thinking is it the files or is it my recovery (Amon RA Style 3.11) I'm going to flash 2.3 and see if it works then. One more thing I want to ask to make sure I'm not screwing up the Zip is in compression and not in Store mode correct?

EDIT: Flashed back to Amon RA 2.3 got the same error. So that wasn't the issue. Ok so running out of ideas here.
I don't ever touch the compression of the zip file. I literally just drag and drop the updated binary and script into the file using 7-zip, and I've never had a problem. I can give you my whole zip, if you want. You can try just dropping your script into it and see if it works. I know mine works as-is.
 
  • Like
Reactions: Rxpert83
Upvote 0
Yeah go ahead and send it. Oh I hadn't messed with the zip other than updating I was just thinking about extracting and seeing if recompressing it would work
Here you go!

BeatsAudiob0314.zip - update-binary & updater-script updated

Let me know if it doesn't work for you for some reason. Maybe it'll help you figure out what's going on with yours.
 
  • Like
Reactions: argedion
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones