Lanchon / REPIT

A Device-Only Data-Sparing Repartitioning Tool For Android
159 stars 25 forks source link

Samsung Galaxy Tab GT-P1000 #58

Closed YossiA1 closed 7 years ago

YossiA1 commented 7 years ago

Hello, I would you to increas system partition to the possible maximum. I would like to install the open gapps Aroma/Super package. The Aroma/Super package is about 800 MB. Or maby to increas internal storage to the possible maximum? Or both? Sorry, I am not an expert on this partitioning resizing... I am hoping you would tell me that it can be done.

Kernel Version: 3.0.101-gd5e6973 (root@vmi49976.contabo.host) (gcc version 4.9.4 20151101 (prerelease) (UBERTC-4.9.4) ) #1 PREEMPT Tue Jul 26 15:49:37 CEST 2016 Tags: test-keys Type: userdebug

repit-dump.txt

AIDA64 for Android v1.42 Report.txt

DiskInfo GT-P1000 07 Nov 2016.txt

TWRP 3.0.2-0 recovery. ROM: cm-13.0-20160726-UNOFFICIAL-p1. This ROM was downloaded from here: https://www.androidfilehost.com/?fid=24651429356503276

The ROM xda forum: http://forum.xda-developers.com/galaxy-tab/development/rombeta-cyanogenmod-13-0-t3356495

I think the device partition layout has been modified by the ROM developer. From the ROM changelog on xda: 13/04/2016 -Rotation sensor fixed -System partition size raised to 900 mb so you can flash gapps securely. But your data partition wiped after flash this build one time. -Switch to Snap camera

Thank you

Lanchon commented 7 years ago

hi,

thank you for a very detailed report.

unfortunately your phone is partitioned in a nonstandard way. the dumper never got to see the partitions, and neither would REPIT, i'm sorry for the bad news.

Lanchon commented 7 years ago
sgdisk /dev/block/mmcblk0 --set-alignment 1 --print
----------------------------------------------------------------------------------------------------------

***************************************************************
Found invalid GPT and valid MBR; converting MBR to GPT format.
***************************************************************

Warning! Secondary partition table overlaps the last partition by
33 blocks!
You will need to delete this partition or resize it in another utility.
Disk /dev/block/mmcblk0: 31105024 sectors, 14.8 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): CD100891-B6CA-4EB8-8C6A-17855E21BD09
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 31104990
Partitions will be aligned on 1-sector boundaries
Total free space is 2270 sectors (1.1 MiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048        26562559   12.7 GiB    0700  Microsoft basic data
   2        26562688        30494719   1.9 GiB     0700  Microsoft basic data
   3        30494848        31105023   297.9 MiB   0700  Microsoft basic data
YossiA1 commented 7 years ago

I see... Is there any way you can help me? Reflashing your tool would help? I don't care if the device will brick. There has to be something that can be done. The ROM developer has raised the size of the system partition as I quoted him from his xda thread.

Lanchon commented 7 years ago

if you dont care about the data, why dont you flash the build and see what happens?

Irome commented 2 years ago

Hello, I would you to increas system partition to the possible maximum. I would like to install the open gapps Aroma/Super package. The Aroma/Super package is about 800 MB. Or maby to increas internal storage to the possible maximum? Or both? Sorry, I am not an expert on this partitioning resizing... I am hoping you would tell me that it can be done.

Kernel Version: 3.0.101-gd5e6973 (root@vmi49976.contabo.host) (gcc version 4.9.4 20151101 (prerelease) (UBERTC-4.9.4) ) #1 PREEMPT Tue Jul 26 15:49:37 CEST 2016 Tags: test-keys Type: userdebug

repit-dump.txt

AIDA64 for Android v1.42 Report.txt

DiskInfo GT-P1000 07 Nov 2016.txt

TWRP 3.0.2-0 recovery. ROM: cm-13.0-20160726-UNOFFICIAL-p1. This ROM was downloaded from here: https://www.androidfilehost.com/?fid=24651429356503276

The ROM xda forum: http://forum.xda-developers.com/galaxy-tab/development/rombeta-cyanogenmod-13-0-t3356495

I think the device partition layout has been modified by the ROM developer. From the ROM changelog on xda: 13/04/2016 -Rotation sensor fixed -System partition size raised to 900 mb so you can flash gapps securely. But your data partition wiped after flash this build one time. -Switch to Snap camera

Thank you

I found this post by chance. His little GUIDE to repartition and then increase the system partition using Windows 10/11, is written down after I managed to screw up my partitions on my Galaxy Tab while rooting it. Luckily I still had some space that allowed me to reinstall stock firmware through Odin. I wrote a blog post on how to do this here. Then I had to get a recovery bootloader that gave me root access in recovery mode and the parted tool. So if you have a booting Android but with fucked up partitions, try this. PS! Android will probably not boot after this. So know you will have to reinstall. And if you have something on your SDcard you should back it up, you probably need to remove all partitions if you have a real screw up. You can resize if you want to get advanced though. The guide is written for windows command line.

  1. Install Samsung Kies (for Windows 7 Only) or download the drivers for GT-P1000, search on google: gt-p1000 Samsung_USB_Driver_v1.7.46.0 gt-p1000 usb_driver_r13-windows.zip gt-p1000 SAMSUNG_USB_Driver_for_Mobile_Phones Minimal_ADB_Fastboot_v1.4.3

  2. extract the archive files each in a different folder and install the drivers and ADB Fastboot you need for use the command console to partition the tablet. Make sure it can connect to your PC, you need the drivers that comes with it.

  3. Download Odin3: https://odindownloader.com/download/odin3-v3-14-4, it is used to flash any version of the official Samsung firmware (Stock ROM), but in this case we need to flash the Kernel to access the ROOT of the GT-P1000

  4. Install ADB, it comes with Android SDK. When you have ADB you should test it. First set your Tab in USB debugging mode (settings/applications/development).

  5. Download the Kernel Overcome_Kernel_v4.0.0.tar (it will be used to use the commands from ADB on the PC to create partitions) that you find here: https://androidfilehost.com/?fid=9390225151984927181 here you will find other interesting tools, especially to recover the tablet from a HARD BRICK, in the next post I will explain how to do it: https://androidfilehost.com/?w=files&flid=1974 Also download this other Kernel CF-Root-TAB7_XX_OXA_JQ1-v3.3-CWM3RFS.tar, it will be used after creating the new partitions to flash a new ROM: https://download.chainfire.eu/77/CF-Root/SGT7/CF-Root-TAB7_XX_

  6. Extract the Odin3 archive and run as administrator (right mouse button) the executable Odin3_v3.14.4.exe to flash the Overcome_Kernel_v4.0.0.tar kernel.

  7. Download the Flash_image file. This is a tool that does what it sounds like, flashes images of your favorite ROM, I recommend: lineage-11-20171228-UNOFFICIAL-p1.zip cm-11-20170107-UNOFFICIAL-p1.zip cm-13.0-20160726-UNOFFICIAL-p1.zip

here you will find all the versions of CyanogenMod ROMs: https://drive.google.com/drive/folders/0B8o3NTrh0lxqV3JFd0k5QVNhTUk?resourcekey=0-txwfVy4zOYlTjDYiWZfWlA https://www.dropbox.com/sh/172xhc9yy2cplge/AABI4Y1Yykddj1bVVzI5yLRba?dl=0

In this Russian forum you will find everything: https://4pda.to/forum/index.php?showtopic=286526&st=10140#entry38929289

  1. Unzip the .zip fil which contains the kernel Kernel Overcome_Kernel_v4.0.0.tar, (or unzip another kernel that has the same or higher version of ClockWorkMod Recovery 5.0) keep the file zImage, this is the ClockWorkMod recovery image we will use. This will give you root access from the recovery mode.

  2. Turn on the tablet in DOWNLOAD mode by simultaneously pressing the down key (to lower the volume) and the power key (to turn on the device), make sure you have installed the USB drivers of the Galaxy Tab and connect it to the PC via the appropriate USB cable, start Odin3_v3. 14.4.exe, then click on OK and then click on the AP button, a window will open where you will have to search for and select the Overcome_Kernel_v4.0.0.tar kernel (or unzip another kernel that has the same or higher version of ClockWorkMod Recovery 5.0) in the directory of your PC, then click on START. At this point the tablet should boot up and you should be able to enter recovery mode (Overcome CWM Recovery v5.1.2.6) by accessing from the tablet off by pressing the up button (to raise the volume) and the power button (to turn on the device) at the same time. (this recovery mode will be used to make the commands work to repartition the device via ADB)

8.1 You can flash the kernel with another procedure, directly on android (NOT RECOMMENDED), by ROOTing the device with SuperOneClick (search on google), follow this guide or find another you like better. Your device must be booted into Android at first.

Flash the recovery bootloader. These commands depend on where you put your files. the syntax works like this: "adb push " Run all these commands:

adb push flash_image /data/local/bin/flash_image adb push zImage /sdcard/ adb shell su chmod 755 /data/local/bin/flash_image /data/local/bin/flash_image boot /sdcard/zImage sync exit exit adb reboot recovery

  1. ONCE YOU HAVE FLASHED THE KERNEL AND ARE IN RECOVERY MODE WITH THE GALAXY TAB CONNECTED TO THE PC, open ADB as administrator and type "adb devices" in the command prompt and see if a device is listed up with a serial number. Then try "adb shell", you will get a new command line with a $ in front if it works.

  2. Now you are hopefully inside Overcome CWM Recovery v5.1.2.6 or ClockWorkMod Recovery 5.0 (equal or higher version) Along with it comes parted, a tool for managing partitions. You can open "adb shell" again and type "su" for root access, which you need for opening parted.

  3. Unmount all partitions in the ClockWorkMod under "mounts and storage". In the shell, open parted by typing: parted /dev/block/mmcblk0 then type "print" to get the partition information, then you will see the madness.

  4. To finally fix the partitions, follow this great guide (XDA Developer forum). It's really detailed and tells how you should part it up. Read it carefully though. If you wish to upgrade to ext3/4 it describes this as well. I put my commands for cleaning up and upgrading to ext4 as an example. Here I create a sdcard partition of 11696mb, ext2 of 4096mb and swap of 128mb. These are parted commands, in case you get confused. remove partitions:

rm 1 rm 2 rm 3

to create a system partition with size of (2GB), I put these values:

mkpartfs primary fat32 0 11696 mkpartfs primary ext2 11696 15792 mkpartfs primary linux-swap 15792 15920

To get a system partition with larger size (6GB), I put these values: mkpartfs primary fat32 0 9264 mkpartfs primary ext2 9264 15408 mkpartfs primary linux-swap 15408 15920 In this case the "Internal SD" partition will be reduced from about 12GB to 8GB, but you can install all the Aroma GAPPS, and other APPS that will end up in the system partition.

now you are done with parted, type quit and get back to shell. upgrade from ext2 to ext4:

tune2fs -O extents,uninit_bg,dir_index,has_journal /dev/block/mmcblk0p2 tune2fs -O extents,uninit_bg,dir_index /dev/block/mmcblk0p2

always run check afterwards: e2fsck /dev/block/mmcblk0p2

  1. After you have fixed your partitions your device probably won't boot into Android. So you have too reinstall somehow, like I mentioned in the beginning.

  2. After creating the new partitions, from the ClockWorkMod Recovery settings, go to the storage menu and select mount internal SD, at this point the SD partition folder of the tablet should appear on the PC. Copy your favorite ROM, GAPPS and everything you want to put in the Tablet. At this point you have everything ready, repeat the procedure of point 8. but this time you will have to flash the CF-Root-TAB7_XX_OXA_JQ1-v3.3-CWM3RFS.tar kernel or any version equal to or higher than the ClockWorkMod Recovery 5.0 (obviously if not the you have already done) and proceed by flashing your favorite ROM and then the Gapps.

I recommend a version with Kitkat 4.4.4 of CyanogenMod 11 (CM11) is the fastest and most stable, it allows you to overclock the CPU from 1000Mhz (maximum factory frequency) to 1400Mhz and optimize the use of RAM memory. CM13 (Marshmallow 6.0.1) slower, but more stable than OmniRom 6, for those who need to use the latest apps.

Irome commented 2 years ago

Below I will explain a procedure to recover (Unbrick the Hard Bricked) Samsung Galaxy Tab GT-P1000, which no longer turns on and no longer shows signs of life, and which if connected to the PC does not connect, and if you try to restore the original firmware to bring it to factory conditions with Odin3, it is not detected by the COM ports and therefore it is not possible to flash it in any way:

  1. If Odin3 does not show the connection of the tablet on the COM5 port of the PC, it is still possible to recover it (Unbrick it), in my case i was able to unbrick it with no sign of connection with the pc and even if i try to charge the tablet, the charging screen doesn't appear and it doesn't seem to charge.

  2. First connect your tablet to the charger and let it charge (to make sure it charges fully) overnight.

  3. Download by searching on Google (or from the links I posted in the previous message in point 7.) the GB_Stock_Safe_v5.zip package, it will be used both to restore and to make Odin3 recognize the tablet.

  4. Extract the files to a folder.

  5. Start Odin3 (I recommend to load version 1.7 or 1.85) with administrator privileges and load the files on the program from the extracted package of GB_Stock_Safe_v5.zip, insert the file gt-p1000_mr.pit (contains the partition tables) in the entry PIT, the GB_Stock_Safe_v5.tar firmware file in the PDA entry (or AP for the latest versions of Odin3) and the modem.bin file from the JPZ Modem folder for Europe and other continents, (the T-Mobile, JMF and JK3 Modems are for specific countries, do research about it) in the PHONE (or CP for the most recent versions of Odin3)

  6. Then connect the tablet to the PC ... Which obviously won't connect the moment you connect it to your PC ... but don't worry ... be patient and wait about 20 minutes (usually 5 minutes is enough) and then suddenly the Tablet will be recognized by Odin3 again and it will be connected to a COM port, at which point you just have to make sure that a com port is displayed on odin3, if so ... then the tablet is ready to be unbricked ;)

All that remains is to start the program by pressing START ...

Flashing with PIT only will give you a better chance to get your tablet into download mode.