yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] DragonFire1024:
So I can get it to work for maybe 1 or 3 app removals from the system, and about to same for any edits, before it stops allowing any write permission. Sounds like a recovery script that defaults the file system in other directories back to RO. Having a hell of a time trying to find something like that. It's like a needle and a haystack and there's many files to look through.
[Android Software/Hacking General [Developers Only]] Oneironaut84:
work poco f3?
[Android Software/Hacking General [Developers Only]] Oneironaut84:
poco f3
[Android Software/Hacking General [Developers Only]] baxal0:
https://prnt.sc/13r4r0o
[Android Software/Hacking General [Developers Only]] derricksrs:
oneplus 8t working with manual running the script.

auto flash mode ended with error 6.

- Open Terminal and run:

- cd /data/local/tmp/systemrw_1.31d`

- chmod +x systemrw.sh

- ./systemrw.sh size=100

- Wait for a few minutes

- Erase with recovery explorer data/local/* (important)

- Reboot to system
[Android Software/Hacking General [Developers Only]] Oneironaut84:
Poco F3 DOne!!!:cool: thank you!
[Android Software/Hacking General [Developers Only]] Oneironaut84:
has been done..I can not delete a folder and rename it. from inside the bin files, apk are deleted
[Android Software/Hacking General [Developers Only]] BarryViper:
The flashable zip gives 225 error. Doing it manually with the files pushed into *data/local/tmp I gave permission 644 to systemrw.sh then in TWRP terminal executed the commands till the last one ./systemrw.sh size=100 gives error "file not found" What have I missed?
[Android Software/Hacking General [Developers Only]] _BJIAD_:
Hi. I wrote in PM.
[Android Software/Hacking General [Developers Only]] BarryViper:
I'm able to manually use script 1.31 execute the process from ternux. After dumping, both super files are 0bytes.
[Android Software/Hacking General [Developers Only]] BarryViper:
Executed manually from recovery
[Android Software/Hacking General [Developers Only]] lebigmac:
@BarryViper try launching script v1.31d manually from within Android shell like this:

adb shell
su
cd /data/local/tmp/systemrw_1.31d
chmod +x ./systemrw.sh
./systemrw.sh in=`ls -l /dev/block/by-name/super | awk '{print $NF}'` size=15
[Android Software/Hacking General [Developers Only]] Christanval:
i have poco m3 bricked now just only enter twrp and fastboot

i already try this method and its fails

i cant mount system,vendor and product to flash the roms

what i have to do to make it writeable

can you help me?
[Android Software/Hacking General [Developers Only]] Christanval:
and yes there is have super.img any suggestion how to fix this?
[Android Software/Hacking General [Developers Only]] Christanval:
thanks to @lebigmac its solved now
[Android Software/Hacking General [Developers Only]] abszy:
systemrw: Custom size of vendor_b.img in bytes: 2310545408

systemrw: Custom size of vendor_b.img in MB: 2203

systemrw: Custom size of vendor_b.img in 512-byte sectors: 4512784

systemrw: Increasing filesystem size of vendor_b.img...

resize2fs 1.45.4 (23-Sep-2019)

Resizing the filesystem on ./img/vendor_b.img to 564098 (4k) blocks.

The filesystem on ./img/vendor_b.img is now 564098 (4k) blocks long.

=================================================

systemrw: Current size of system_b-cow.img in bytes: 2011955200

systemrw: Current size of system_b-cow.img in MB: 1918

systemrw: Current size of system_b-cow.img in 512-byte sectors: 3929600

=================================================

systemrw: Joining all extracted images back into one single super image...

systemrw: Please wait and ignore the invalid sparse warnings...

Not enough space on device for partition system_b-cow with size 2011955200

systemrw: Error! failed to create super_fixed.img file. Error code: 70

what's wrong with this？The same error as above whether I ran your scrips in termux or TWRP.Thanks!
[Android Software/Hacking General [Developers Only]] abs_khafan_19:
hi

my phone poco x3 pro 256/ ram 8 vayu

stock miui 12.0.6

bootloader unlocked

rooted with magisk

edxposed

busybox .

going to recovery twrp decrypted with pin code

mount all of the parts .

after that flash zip file .

after 1 min got some error

updater process ended with signal :6

error installing zip file /sdcard/makesysrw_1.31_flashable.zip

after that my phone turn on

but cant access to my internal sd card

and get me error

exmaple when want to copy file cant see internal storage .

but again going to twrp and can see my internal storage of my phone to my pc .

i try manual for flash with adb but not happend

3 or 5 times try your file but not happend .

please give me some zip file for flash that can accsess to my internal storage when my phone turn on ...

Metadata version: 10.0

Metadata size: 668 bytes

Metadata max size: 65536 bytes

Metadata slot count: 2

Header flags: none

Partition table:

------------------------

Name: system

Group: qti_dynamic_partitions

Attributes: readonly

Extents:

0 .. 5192823 linear super 2048

------------------------

Name: vendor

Group: qti_dynamic_partitions

Attributes: readonly

Extents:

0 .. 3145727 linear super 5195776

------------------------

Name: product

Group: qti_dynamic_partitions

Attributes: readonly

Extents:

0 .. 2846967 linear super 8341504

------------------------

Name: odm

Group: qti_dynamic_partitions

Attributes: readonly

Extents:

0 .. 2303 linear super 11189248

------------------------

Name: system_ext

Group: qti_dynamic_partitions

Attributes: readonly

Extents:

0 .. 625343 linear super 11192320

------------------------

Super partition layout:

------------------------

super: 2048 .. 5194872: system (5192824 sectors)

super: 5195776 .. 8341504: vendor (3145728 sectors)

super: 8341504 .. 11188472: product (2846968 sectors)

super: 11189248 .. 11191552: odm (2304 sectors)

super: 11192320 .. 11817664: system_ext (625344 sectors)

------------------------

Block device table:

------------------------

Partition name: super

First sector: 2048

Size: 9126805504 bytes

Flags: none

------------------------

Group table:

------------------------

Name: default

Maximum size: 0 bytes

Flags: none

------------------------

Name: qti_dynamic_partitions

Maximum size: 9126805504 bytes

Flags: none

------------------------
[Android Software/Hacking General [Developers Only]] jay.illicit:
Can this be installed through Magisk? Or sideloaded? I can't boot TWRP on my oneplus 8.

Please help. Android 11 Evolution Rom.
[Android Software/Hacking General [Developers Only]] Vethy:
Hi everyone, I know there are others here facing problems but I could really use some help because I've been at this for days and this seems like the only reliable solution to my problem.

I'm running a Sony Xperia 10 ii - Android 10 - Stock ROM and when I try to install the .zip file through TWRP it gets to the end and I get the infamous superimage error {73}

I have also tried doing it manually but it just didn't want to work. All I want to do is edit my build.prop file, I tried the MagiskConfig Hide Module but couldn't for the life of me understand how to use it properly nor find any solid forums online. I can't install the repair script through Linux on a PC as I can't access one away from home. I even went as far to install Andronix, Install Ubuntu, Run a VNC Server and gave access to my phones storage to see if 'maybe' that'd work for the repair file (stupid I know) It didn't. Is there ANYTHING I can do to fix this error from my phone, I have gone through this forum several times and I just see that Linux is the only fix.

I've have termux installed with all the proper dependencies needed, But at this point I'm losing hope because I've been trying this for DAYS.

I'd really appreciate some help if someone could, thankyou! :)
[Android Software/Hacking General [Developers Only]] _xenoxis_:
Hello @lebigmac, i tried to install the version 1.31d on my Redmi Note 9 Pro (TWRP-miatoll-v3.5.2-17042021 / MIUI 12.0.1.0.RJZMIXM - Android 11), it installed perfectly, i can correctly mount my /vendor partition as RW (with the help of ADB_ROOT and ENABLE_ENG magisk's mod, else i can't access adb shell).

But when i tried to replace a file in my /vendor partition, it tells me "remote write failed: No space left on device".

Please note that i just tried with the version 1.30 gamma (that i have download some weeks ago) and it worked perfectly, but not with the latest 1.31d.
[Android Software/Hacking General [Developers Only]] lebigmac:
@_xenoxis_

Hello. Did you try giving more extra space using size= parameter?

@jay.illicit

Try running script in Android operating system with rooted stock firmware.

@abs_khafan_19

Script works perfectly with Xiaomi Poco X3 Pro. Please show your latest log

@abszy

Try removing all cow related stuff in myargs.txt and run lpmake command manually using those arguments.

In next version of script all cow related stuff will be removed automatically. Hopefully this will fix the cow error for OnePlus devices?

@Christanval what exactly was the problem and how did you fix it?

@BarryViper try running v1.31d of script inside Android operating system and send me log. Thanks.

@_BJIAD_ Thank you!

It works?!

Hi derricksrs I'm happy it works on your device. Rather than deleting everything inside /data/local/* it's safer to delete only the script folder itself if you want to uninstall script completely (rm -rf /data/local/tmp/systemrw_1.31d)

@DragonFire1024

Did you get it to work on your device?

Try running latest version of script again and give more extra space using size= parameter of script.

It's important to have a working su binary on your device for all of this to work. It doesn't matter if you use Magisk, Supersu or any other su binary as long as it can give you root access.

Always backup any system files before modifying them. Then you can easily restore the original file in recovery if something goes wrong. One little mistake and you will end up in bootloop!

Hi @megiss thanks for feedback. I can't believe it actually works on your OnePlus device!
[Android Software/Hacking General [Developers Only]] _xenoxis_:
No, in both case I just click on "Install" in TWRP and selected the Zip file, so the defaults values have been selected.
[Android Software/Hacking General [Developers Only]] lebigmac:
If the flashable zip actually works on your device you can extract it and modify the included config.ini and increase the size=* parameter value there. Try size=50 or size=100. Don't go too high or you'll end up with error 70!

Then save config.ini and compress script folder and META-INF folder to new flashable zip (random name) and flash it in recovery.
[Android Software/Hacking General [Developers Only]] _xenoxis_:
Ok, just what this size parameter does ? Is it risky ?

On the version 1.30gamma the size was 50, but now is just 15, may I ask you why ?

Thanks for your reply :)
[Android Software/Hacking General [Developers Only]] todays4:
Can i use your script on Xiaomi Mi 11 Lite 5G

and will it work on my phone without twrp?
[Android Software/Hacking General [Developers Only]] lebigmac:
@_xenoxis_ With every new release I reduced size= parameter value to increase compatibility with more devices ;)

With size= parameter you can specify custom extra size for system, product and vendor partitions.

Hi @todays4

Please feel free to launch v1.31d manually inside Android and let me know your results ;)
[Android Software/Hacking General [Developers Only]] todays4:
I'm worried about getting bootloop ))
[Android Software/Hacking General [Developers Only]] todays4:
how to run the script manually?
[Android Software/Hacking General [Developers Only]] Vethy:
I've got Linux set up, Can someone give me a walkthrough on this repair script please.

1.31d used to work fine but then fail at the end with error 73, Now when I try and install it it throws an error 225 at me. I don't know why, The original 1.31 works and then fails at the end though.
[Android Software/Hacking General [Developers Only]] lebigmac:
@Vethy check troubleshooting section in first post.

@todays4 check examples in first post or in comments section of script itself if some spineless hacker hasn't deleted it yet and replaced with his own meaningless words. Good luck!
[Android Software/Hacking General [Developers Only]] Vethy:
I have man, I've been at this for days. When I try to manually install it I get "permission denied"

Can I just clear a few things up, Manual instillation is possible through Termux right? I have the folder in /data/local/tmp and have made sure it's set to r/w. When I try to make the script executable I get "permission denied" when I try to run su and the script I get, well nothing.

I've checked the shebang and my which sh is what it should be.

I have also tried adb shell, same results for both things^
[Android Software/Hacking General [Developers Only]] Vethy:
Okay I'm an idiot. I used su in the folder, ran the script to make it executable and now it's doing it. Will update!
[Android Software/Hacking General [Developers Only]] Vethy:
Same error, But the script ran. I know I'm meant to use the repair tool, I have Ubuntu on a USB but I'm not all that knowledgeable with Linux. Could you PLEASE walk me through the steps?
[Android Software/Hacking General [Developers Only]] lebigmac:
@Vethy I'm working on a solution to make both installation and script launching easier and more straight forward. Just wait for next version ;)
[Android Software/Hacking General [Developers Only]] Vethy:
Ahh haha I've waited this long I'm sure I can wait for that, thanks bud :)
[Android Software/Hacking General [Developers Only]] PEACH-PIT:
Thanks for the great tool.

I just ran the tool again because of a system update.

It worked fine on both "moto g 5g" and "moto edge s".

adb shell
su
chmod +x /data/local/tmp/systemrw_1.31d/systemrw.sh
setenforce 0
cd /data/local/tmp/systemrw_1.31d
./systemrw.sh in=`ls -l /dev/block/by-name/super | awk '{print $NF}'` size=20

sudo bash sysrw_repair.sh
[Android Software/Hacking General [Developers Only]] hallo6459:
Flashed patched/fixed Super.bin. Difference is about 5 Gigabyte. Why does this not create more available (free) space on my device?

Error on /product.

adb push webview.apk /product/app/webview/webview.apk

adb: error: failed to copy 'webview.apk' to '/product/app/webview/webview.apk': remote couldn't create file: Read-only file system

For difference in size (changed filename super_fixed to super).

Reboot seems to have made a difference, T Commander is able to write to /product. Have not tried adb again because it worked via TC after another reboot and for me that is enough for now.
[Android Software/Hacking General [Developers Only]] Myt7930:
Hi

I'm getting error 225 in TWRP when trying to flash the file. Any clue?
[Android Software/Hacking General [Developers Only]] lebigmac:
Thanks for your feedback @PEACH-PIT

Please keep in mind latest version of script will automatically set selinux to permissive by default ;)

Did you figure out yet what's causing error 73 (CAN'T_CREATE) on some devices?

Could you please try these 2 things:

Try to save super_fixed.bin to an external micro sd card (at least 10GB free space) using the script's out= argument (output).

Try to run lpmake manually using arguments from myargs.txt. If same error 73 try to change output to external micro sd before copy pasting myargs.txt

Thank you for trying to make script even better!
[Android Software/Hacking General [Developers Only]] PEACH-PIT:
If I change the output destination to an sd card, the result is the same.

I get an error 73.

I cannot create super_fixed.bin on the sd card.

If I run sysrw_repair on linux, I can get r/w without any problem.
[Android Software/Hacking General [Developers Only]] walkwitmeinhel:
My phone is nubia red magic 3 with A10 when i flash zip in twrp it gives invalid zip ..what is wrong?
[Android Software/Hacking General [Developers Only]] walkwitmeinhel:
Why abort
[Android Software/Hacking General [Developers Only]] lebigmac:
Hi @walkwitmeinhel congratulations for successfully launching script manually! According to your own screenshot your device already has R/W capability. That's great news. Are you using custom ROM?

To verify this you can try these commands below
[Android Software/Hacking General [Developers Only]] walkwitmeinhel:
Stock rom
[Android Software/Hacking General [Developers Only]] mathan7:
not work on redmi note 10 pro (sweetin)
[Android Software/Hacking General [Developers Only]] QanTnkz:
How exactly to do that? Thanks!
[Android Software/Hacking General [Developers Only]] mions_lv:
does't work in Lenovo Lemon K12 Pro，i got error code 73，anyone can help?

systemrw: Joining all extracted images back into one single super image...

systemrw: Please wait and ignore the invalid sparse warnings...

systemrw: Error! failed to create super_fixed.img file. Error code: 73
[Android Software/Hacking General [Developers Only]] Greenspoof:
Hello, after unsuccessful attend to run the script on Poco f3 stock ROM, I finally manage to run it but I ran across the error 70. I ran it on Termux and ADB (I don't have twrp) Because I'm not sure which log would you need, I put the 4 in log ! I saw that you replied to someone else with the same error something about deleting cow related stuff on myargs.txt then run a command, but I don't understand. Thx and sorry for my bad English !
[Android Software/Hacking General [Developers Only]] munjeni:
Android don't allow apps to write to external storage, more info https://developer.android.com/about/versions/11/privacy/storage , if you need solution simple search xda "how to enable write access to external storage"
[Android Software/Hacking General [Developers Only]] harvey186:
great script. I'm using the 'first run' command now for making a backup of my super.img before I proceed a new 'big change' on it.

Thank you very much
[Android Software/Hacking General [Developers Only]] Bontot7:
@lebigmac work for me sir! Device Poco m3 gsi havoc 3.8 android 10. Thanks sir😘
[Android Software/Hacking General [Developers Only]] Haaleven:
Hello! I tried using this script on Android Studio emulator and successfully created an image inside Android. However I don't know how to flash that image instead current one. Could u help me?

systemrw: Successfully created patched super image @
systemrw: /data/local/tmp/systemrw_1.31d/img/super_fixed.bin

systemrw: Congratulations! Your image(s) should now have R/W capability
systemrw: Please reboot into bootloader and flash the file(s) manually
[Android Software/Hacking General [Developers Only]] cyanGalaxy:
I flashed super_fixed.bin with fastboot flash super super_fixed.bin. Now I can finally mount partitions like /vendor as read-write, but now my phone doesn't boot to System anymore, but instead boots to Fastboot Mode.

@Haaleven You flash super_fixed.bin with fastboot flash super super_fixed.bin
[Android Software/Hacking General [Developers Only]] psi.singh03:
Hello Sir @lebigmac, I feel glad reporting you that your this software works on Redmi 9 Power/Redmi 9T over MIUIMix android 10 without any issues. Sir, one thing I want to hear from you if where super_original.bin is saved? I've root access via Magisk, and I want to delete the original_super.bin image for my own convenience. Please help!

Your big big fan!
[Android Software/Hacking General [Developers Only]] Haaleven:
It doesn't help. Command freezes at "< waiting for any device >". As I read fastboot works only for hardware, not emulators. I don't know how to flash super partition in android emulator.
[Android Software/Hacking General [Developers Only]] amg314:
First of all, you must check the correct installation of the USB drivers with the

'fastboot devices' command

The response should be 'Your_dev_Number device'
[Android Software/Hacking General [Developers Only]] cyanGalaxy:
The very first-of-all is Booting into Fastboot Mode. ^_^
[Android Software/Hacking General [Developers Only]] Greenspoof:
Btw I saw that you say that the cow stuff related is fixed on next update? When we will be able to download it?

Anyways, thx for your great work !
[Android Software/Hacking General [Developers Only]] Greenspoof:
Sorry I misread the solution. If your next update fix the cow error, maybe I should wait for it? Instead of a bootloop ? Or I didn't understand and there will be still the cow error on next update ?

Thx for your time sir !
[Android Software/Hacking General [Developers Only]] lebigmac:
Unfortunately my device have no cow files so it's very difficult for me to fix this cow error. If you try both options I gave you above and send me your feedback then it will be easier for me to fix it in next version ;) Good luck!
[Android Software/Hacking General [Developers Only]] psi.singh03:
Yes sir @lebigmac, MIUIMix is a custom variant of MIUI that I'm using. Very happy to see and read you reply. Nothing is out of order. Right after comenting, I found what I was looking for and deleted it. I'll attach the log files at the earliest.
[Android Software/Hacking General [Developers Only]] Greenspoof:
Ok I will try this afternoon. But idk why someone did it on Poco f3 without this cow error :( I will tell you how it gone
[Android Software/Hacking General [Developers Only]] Greenspoof:
Well, I installed finally twrp, but I got the error 6. What do you mean by decrypt and mount data before ?
[Android Software/Hacking General [Developers Only]] Greenspoof:
From what I understand, my data is already decrypted. (wrote during the launch, after I enter my pin)

Then, when I go on mount, data is already checked. Sorry I'm quite a noob in twrp lol
[Android Software/Hacking General [Developers Only]] lebigmac:
Did you try option A yet?
[Android Software/Hacking General [Developers Only]] Greenspoof:
Well I would preferred doing it by twrp, to avoid bootloop... But I will try in a few minute the solution a and post the log here, so you can maybe figure it out for the others
[Android Software/Hacking General [Developers Only]] Greenspoof:
Well, before trying I want to be sure. The back up of my super original is created by your script right ? But mine is 0B, so if I go to bootloop, I can't restore my super original.bin? So before testing your solution, how can I make a backup of my existing super_original.bin?
[Android Software/Hacking General [Developers Only]] Greenspoof:
Well, I think I will abandon lol. I tried both your solution, before and after running the script manually because I wasn't sure how would I do it.

If I run manually the script 1.31d then your solution, I have on both the error : Invalid sparse file format at header magic and no super_fixed.img in IMG folder.

The script doesn't run, the error is instant

If I run your solution without running first your script (1.31d), then I have on your first solution : can't create ./IMG/system_a-cow.img : No such file or directory

On second solution : ./tools/lpmake : can't execute : permission denied. I was in SU and I tried to modify attributes of tools folder but still.

I'm sorry, I'm a big noob so I'm not sure it will help you. I don't have log for both because script doesn't run. Only log I have is when I first run your 1.31d script, but you already have them.

I think I will simply try to fix the error 6 via twrp, because I don't have enough knowledge to bypass this cow related stuff (but what I don't understand is that a another Poco f3 user manually used your script and it worked)

Thx anyways for your time. If you have a solution for error 6 on twrp I will take it !

(Like said before, twrp is decrypted and data already checked in mount in twrp)

Sorry I can't help you with this cow related stuff