[GUIDE] How to dump and write back the storage on most of Qualcomm devices

Search This thread

kjullian19

Member
Sep 22, 2018
10
0
This is the file I have. QFIL only accepts .elf or .mbn files. If there's no conversion possible, how could I load the programmer?
 

Attachments

  • 000a50e100514985_2acf3a85fde334e2_fhprg_op7t.bin
    723.2 KB · Views: 38
  • qfil screenshot.png
    qfil screenshot.png
    204.6 KB · Views: 39

kjullian19

Member
Sep 22, 2018
10
0
It's a perfectly fine Firehose loader.
Just rename it .elf
Or use an EDL client that isn't so picky on stupid stuff.
Like the Python EDL client. Or mine.
Thanks Renate. I tried to proceed with it. The "partial success" log mentioned in the post shows up:

Code:
2023-03-22 10:29:18.787    10:29:18: Sahara protocol completed
2023-03-22 10:29:18.787    Sending Programmer Finished
2023-03-22 10:29:18.788    Switch To FireHose
2023-03-22 10:29:18.788    Wait for 3 seconds...

So I think you were right, the firehose file works. But then I get the following error, and the Partition Manager doesn't open. (Log Attached)

Code:
2023-03-22 10:29:21.799    Skip Write:False
2023-03-22 10:29:21.800    Always Validate:False
2023-03-22 10:29:21.800    Use Verbose:False
2023-03-22 10:29:21.802    ***** Working Folder:C:\Users\kandr\AppData\Roaming\Qualcomm\QFIL\COMPORT_6
2023-03-22 10:29:21.802    Download Fail:FireHose Fail:FHLoader Fail:The system cannot find the file specified
2023-03-22 10:29:21.808    Finish Get GPT

Do you or anyone else have solved this error in the past, and managed to get Partition Manager to open?
 

Attachments

  • 133239801130170890.log
    5.6 KB · Views: 8

kjullian19

Member
Sep 22, 2018
10
0
I'll give your EDL client a try thanks. Do I need to change the driver or is the one from this guide okay?

EDIT: I managed to get the partition manager working, and got Start LBA 0x00479676 and LBA Number 0x0184C185. Added together it gives 0x01CC57FB or 30,169,083.


I ran the command to dump, changed it to my needs, and this is the most recent log, it has been running for 15 minutes now:

AppData\Roaming\Qualcomm\QFIL\COMPORT_6>"C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe" --port=\\.\COM6 --search_path=C:\oneplusdump --convertprogram2read --sendimage=full_dump.bin --start_sector=0 --lun=0 --num_sectors=30169083 --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=ufs

Base Version: 16.10.28.15.28
Binary build date: Oct 31 2016 @ 22:51:02
Incremental Build version: 16.10.31.22.51.02

12:00:11: INFO: FH_LOADER WAS CALLED EXACTLY LIKE THIS
************************************************
C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe --port=\\.\COM6 --search_path=C:\oneplusdump --convertprogram2read --sendimage=full_dump.bin --start_sector=0 --lun=0 --num_sectors=30169083 --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=ufs
************************************************

12:00:11: INFO: Current working dir (cwd): C:\Users\kandr\AppData\Roaming\Qualcomm\QFIL\COMPORT_6\
12:00:11: INFO: Showing network mappings to allow debugging
12:00:11: INFO: Looking for file 'full_dump.bin'


(_)
__ ____ _ _ __ _ __ _ _ __ __ _
\ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
\ V V / (_| | | | | | | | | | | (_| |
\_/\_/ \__,_|_| |_| |_|_|_| |_|\__, |
__/ |
|___/


12:00:11: WARNING: Couldn't find the file 'full_dump.bin', returning NULL


(_)
__ ____ _ _ __ _ __ _ _ __ __ _
\ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
\ V V / (_| | | | | | | | | | | (_| |
\_/\_/ \__,_|_| |_| |_|_|_| |_|\__, |
__/ |
|___/


12:00:11: WARNING: User specified --num_sectors=30169083 but file only has 30169083 sectors. **Ignoring --num_sectors


12:00:11: INFO: User wants to talk to port '\\.\COM6'
12:00:11: INFO: Took 0.00000000 seconds to open port
12:00:11: INFO: Sorting TAGS to ensure order is <configure>,<erase>, others, <patch>,<power>
12:00:11: INFO: If you don't want this, use --dontsorttags

12:00:11: INFO: Looking for file 'full_dump.bin'


(_)
__ ____ _ _ __ _ __ _ _ __ __ _
\ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
\ V V / (_| | | | | | | | | | | (_| |
\_/\_/ \__,_|_| |_| |_|_|_| |_|\__, |
__/ |
|___/


12:00:11: WARNING: Couldn't find the file 'full_dump.bin', returning NULL
12:00:11: INFO: Sending <configure>

12:00:11: INFO: TARGET SAID: 'Storage type set to value UFS'
12:00:11: INFO: fh.attrs.MaxPayloadSizeToTargetInBytes = 1048576
12:00:11: INFO: fh.attrs.MaxPayloadSizeToTargetInBytesSupported = 1048576
12:00:11: INFO: In handleRead('full_dump.bin')
12:00:11: INFO: Looking for file 'full_dump.bin'


(_)
__ ____ _ _ __ _ __ _ _ __ __ _
\ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
\ V V / (_| | | | | | | | | | | (_| |
\_/\_/ \__,_|_| |_| |_|_|_| |_|\__, |
__/ |
|___/


12:00:11: WARNING: Previous Filesize is 0 bytes. Therefore reading size of partition!! Please check 'C:\Users\kandr\AppData\Roaming\Qualcomm\QFIL\COMPORT_6\full_dump.bin'
12:00:11: INFO: =======================================================
12:00:11: INFO: <read> (120676332.0KB) 30169083 sectors from location 0 FILE: 'full_dump.bin'
12:00:11: INFO: =======================================================

12:00:13: INFO: Overall to target 2.000 seconds (105.30 MBps)
12:00:15: INFO: Overall to target 4.000 seconds (105.50 MBps)
12:00:17: INFO: Overall to target 6.000 seconds (105.79 MBps)
12:00:19: INFO: Overall to target 8.000 seconds (105.75 MBps)
12:00:21: INFO: Overall to target 10.000 seconds (101.01 MBps)
12:00:23: INFO: Overall to target 12.000 seconds (99.42 MBps)
12:00:25: INFO: Overall to target 14.000 seconds (98.41 MBps)
12:00:27: INFO: Overall to target 16.000 seconds (96.69 MBps)
12:00:29: INFO: Overall to target 18.000 seconds (95.56 MBps)
12:00:31: INFO: Overall to target 20.000 seconds (94.45 MBps)
12:00:33: INFO: Overall to target 22.000 seconds (93.63 MBps)
12:00:35: INFO: Overall to target 24.000 seconds (93.63 MBps)
(Repeats every 2 seconds...)

Does anyone know where this error may be coming from? Is it safe to stop the process or disconnect my device?
 
Last edited:

kjullian19

Member
Sep 22, 2018
10
0
Last question. I have the full_dump.img file now, and I tried using 7-zip to extract my (user)data. The file is 115 GB which is in line with phone's storage, but it only extracts to a 7.6MB folder. How can I actually access the userdata?
 

Isrgish

Senior Member
Jan 5, 2018
149
22
Thanks for this great guide.

My Partition Manager results seems to have 2 separate last partitions. Which numbers should I use to get the number of sectors to use? There is a partition called "ALIGN_TO_128K_2" which starts again from 0x06. Should I calculate the numbers from both last partitions separately and then combine them to get my number?

My device is UFS, should I change the `--memoryname=emmc` to `--memoryname=ufs`?

I'm attaching my Partition list file.
 

Attachments

  • COM5_PartitionsList.xml
    18 KB · Views: 10

Renate

Recognized Contributor / Inactive Recognized Dev
  • Like
Reactions: Isrgish

Isrgish

Senior Member
Jan 5, 2018
149
22
No, it actually has 4.
That's just unused space at the end of each unit. There could be 6.

I'm not clear how to calculate the number of sectors I should use.

Am I only looking for the dump of the partitions of LUN 0? (This seems to be what the OP is using since the command has --lun=0).
Wouldn't I need ALL partitions to be able to restore my device?
What are the other LUN's?
 

Isrgish

Senior Member
Jan 5, 2018
149
22
I'm not sure about the Python EDL client, but with mine you can just do:
Code:
C:\>edl.exe /r /u0 unit0.img
You don't have to count sectors.
Will this get all the sectors from all the parts (LUNs)?

How do I connect to the device using your program? I tried edl.exe /I just to see if it works but I get error no device found.
 
Last edited:

Renate

Recognized Contributor / Inactive Recognized Dev
Will this get all the sectors from all the parts (LUNs)?
If you have UFS and 6 LUNs you will need to do 6 separate operations.
Th /u specifies which LUN, obviously the output files should be different.

... I get error no device found.
QFIL only uses the bogus Qualcomm driver.
The Python EDL client can use the Qualcomm driver or generic WinUsb driver (installed by Zadig).
My native Windows EDL client only uses WinUsb driver. See the documentation.
 
  • Like
Reactions: Isrgish

Isrgish

Senior Member
Jan 5, 2018
149
22
QFIL only uses the bogus Qualcomm driver.
The Python EDL client can use the Qualcomm driver or generic WinUsb driver (installed by Zadig).
My native Windows EDL client only uses WinUsb driver. See the documentation.

Will I need to uninstall the dricers I currently have insralled? Will QFIL be able to use the WinUSB driver?
 

Renate

Recognized Contributor / Inactive Recognized Dev
  • Like
Reactions: Isrgish

Top Liked Posts

  • 1
    @Renate
    How do I write back only LUN 0? What do I use for the flags /s & /c?
    The info I see is that /s0 /c0 is acceptable and means the whole device. Since I'm only writing LUN 0 I don't want the whole device.
    To read everything you just need edl /r /u0 bigfile since accidentally reading 64 GB is not so bad.
    To write a single partition you can edl /w /pboot mybootfile.
    But if you forgot the /p then edl /w mybootfile would overwrite the MBR and partitioning with garbage (if we didn't prevent that).
    To write everything you just need edl /w /u0 /s0 /c0 bigfile.
    On UFS by "device" we mean a LUN which is a logical device.
    No single read/write operation can span multiple LUNs.
  • 1
    You know what you forgot to do for the 1000th time?
    How about that HWID and Hash?


    Pardon the ignorance, but where exactly does one get the firehose files for their device?
    It depends. Sometimes the Firehose loaders are distributed in update packages by the OEM.
    Sometimes these are limited or restricted (like Motorola/Lenovo).
    Sometimes these are snuck out in the dead of night from disgruntled/helpful employees and released on the internet.
    Some of these are Qualcomm factory signed Firehose loaders.
    1
    @Renate
    How do I write back only LUN 0? What do I use for the flags /s & /c?
    The info I see is that /s0 /c0 is acceptable and means the whole device. Since I'm only writing LUN 0 I don't want the whole device.
    To read everything you just need edl /r /u0 bigfile since accidentally reading 64 GB is not so bad.
    To write a single partition you can edl /w /pboot mybootfile.
    But if you forgot the /p then edl /w mybootfile would overwrite the MBR and partitioning with garbage (if we didn't prevent that).
    To write everything you just need edl /w /u0 /s0 /c0 bigfile.
    On UFS by "device" we mean a LUN which is a logical device.
    No single read/write operation can span multiple LUNs.
  • 10
    This is a generic guide that could be suitable for many Qualcomm based devices, once the phone can be triggered to EDL mode.

    To make sure this guide will work as expect, following requirements are needed:
    - Know how to trigger the phone to EDL mode, and you can force reboot the phone (Required for Driver Changing)
    - Qualcomm EDL mode doesn't require service authentication, or specially modded (e.g. Lumia Emergency Files)
    - Firehose file for your SoC and storage type (eMMC or UFS storage)
    - Latest Qualcomm USB Drivers (at least 2.1.2.0 or newer, you can check yourself in Device Manager) and QPST Tool

    Driver version is pretty important. If older than 2.1.2.0, it won't support partition dumping properly.
    You may need to reboot your Windows PC to Disable Driver Signature Enforcement mode to allow you use the driver.
    I won't provide any download link of the proper drivers, please find yourself.

    For non-Android Smartphones, HP Elite X3 (At least for prototype unit) is confirmed working with this method.
    Most of Android Smartphones should work as well.

    Step 1: Trigger the phone to EDL mode

    Following methods can be used as reference:
    - Connect your phone to PC with a specific key pressed
    e.g. TCL / Alcatel / Blackberry Android Smartphones can use Volume Down key to trigger to EDL mode

    - EDL cable (DIY or order it on eBay / AliExpress, keyword: Xiaomi EDL cable)
    e.g. Smartisan Smartphones that made recently can use EDL cable to unlock the bootloader.

    - Fastboot command
    e.g. Few Xiaomi Phones

    - Wire trick
    If you know where's the test point / components (like resistant) on CLK pin of eMMC/UFS storage is connected as well, short it to the GND will trigger your phone to EDL mode.
    This will be usable for almost every Qualcomm devices, once you have schematic provided by the manufacturer.

    - Erase aboot / abl / xbl / UEFI from your phone
    This method is dangerous, do it at your own risk!

    Step 2: Change the Driver to Qualcomm HS-USB QDLoader 9008

    Skip this step if it's already indicated as HS-USB QDLoader 9008 in Device Manager, "Ports (COM or LPT)" category.
    If it's indicated as HS-USB Diagnostics 9008 in "Ports (COM or LPT)" category, or "QHSUSB__BULK" in "Universal Serial Bus devices" category, you must update the driver to Qualcomm HS-USB QDLoader 9008, then reboot your phone to Qualcomm EDL mode again to ensure the EDL port will not throttle.

    To reboot your phone, you need to perform hard reboot until you see the port disappeared immediately or refresh (in case the phone is bricked).

    Step 3: Open QFIL, load Firehose file

    You must choose correct storage type in right down corner.
    In many cases keep it as "emmc" for default, otherwise choose "ufs" for flagship devices. In this case we choose emmc.

    Then choose "Flat Build" as Build Type, and select the firehose file for your phone. If there's no firehose file specifically for your device, you may want to choose another firehose file for the same SoC, same storage type for different phone.
    For example, I used the "prog_emmc_firehose_8996_ddr.elf" for ZUK Z2 on HP Elite X3 and it works perfectly.

    In many cases, you can obtain firehose file for your phone from stock firmware.

    Step 4: Open Partition Manager

    Now choose "Tools" - "Partition Manager", and please pay attention to the Status box.
    When it indicates:
    Code:
    2019-07-18 20:04:19.775    20:04:19: Sahara protocol completed
    2019-07-18 20:04:19.776    Sending Programmer Finished
    2019-07-18 20:04:19.776    Switch To FireHose
    2019-07-18 20:04:19.777    Wait for 3 seconds...
    If you didn't see the output above, then the firehose file is incorrect or the EDL port is throttled. Reboot your phone to EDL mode again.

    Then you've partially succeeded, just wait for the Partition Manager appears.

    This is the partition table of your phone. Please take note on the Start LBA and LBA number of the last partition.
    Take HP Elite X3 partition table for example, the last partition is "Data", it's Start LBA and LBA number are 0x01E20000 and 0x0565BFDF. Add both of them will get the total sector numbers of whole eMMC storage - in this case, 0x0747BFDF, or 122,142,687 sectors. Multiple the sector numbers with 512 will get the total bytes of the eMMC storage, in this case, the capacity of eMMC storage is 62,537,055,744‬ bytes.

    You'll need the number 122,142,687 for later use.

    If you don't want to dump userdata partition, just use the Start LBA value of userdata partition and convert it to decimal values - the overall dump will not contain actual userdata.

    Don't close Partition Manager, we need to keep it for later use.
    Now choose either Step 5A or 5B as your wish.

    Step 5A: Dump the storage

    Please copy following path to your File Explorer:
    Code:
    %AppData%\Qualcomm\QFIL
    This will redirect you to C:\Users\[your_user_name]\AppData\Roaming\Qualcomm\QFIL .
    Find the COMPORT_XX directory respective to your exact COM port - in this case, I choose COMPORT_8 for example.

    And open a command prompt or PowerShell window here.
    Execute following command here, remember to change the COM port number and num_sectors to your exact number, or the actual path of fh_loader.exe and your dump if possible:

    Note, this command will not create the path of your dump for you, you must create yourself.
    Code:
    "C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe" --port=\\.\COM8 --search_path=D:\path\to\your\dump --convertprogram2read --sendimage=full_dump.bin --start_sector=0 --lun=0 --num_sectors=122142687 --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=emmc

    Now just wait for dumping procedure complete.

    Expected output should look like this:
    Code:
    20:45:50: INFO: Current working dir (cwd): C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\
    20:45:50: INFO: Showing network mappings to allow debugging
    20:45:50: INFO: Looking for file 'full_dump.bin'
    
    
                                     (_)
            __      ____ _ _ __ _ __  _ _ __   __ _
            \ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
             \ V  V / (_| | |  | | | | | | | | (_| |
              \_/\_/ \__,_|_|  |_| |_|_|_| |_|\__, |
                                               __/ |
                                              |___/
    
    
    20:45:50: WARNING: Couldn't find the file 'full_dump.bin', returning NULL
    
    
                                     (_)
            __      ____ _ _ __ _ __  _ _ __   __ _
            \ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
             \ V  V / (_| | |  | | | | | | | | (_| |
              \_/\_/ \__,_|_|  |_| |_|_|_| |_|\__, |
                                               __/ |
                                              |___/
    
    
    20:45:50: WARNING: User specified --num_sectors=524288 but file only has 524288 sectors. **Ignoring --num_sectors
    
    
    20:45:50: INFO: User wants to talk to port '\\.\COM8'
    20:45:50: INFO: Took       0.00000000 seconds to open port
    20:45:50: INFO: Sorting TAGS to ensure order is <configure>,<erase>, others, <patch>,<power>
    20:45:50: INFO: If  you don't want this, use --dontsorttags
    
    20:45:50: INFO: Looking for file 'full_dump.bin'
    
    
                                     (_)
            __      ____ _ _ __ _ __  _ _ __   __ _
            \ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
             \ V  V / (_| | |  | | | | | | | | (_| |
              \_/\_/ \__,_|_|  |_| |_|_|_| |_|\__, |
                                               __/ |
                                              |___/
    
    
    20:45:50: WARNING: Couldn't find the file 'full_dump.bin', returning NULL
    20:45:50: INFO: Sending <configure>
    
    20:45:50: INFO: TARGET SAID: 'Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1''
    
    20:45:50: INFO: TARGET SAID: 'Calling hotplug_poll_device('MMC')'
    20:45:50: INFO: fh.attrs.MaxPayloadSizeToTargetInBytes = 1048576
    20:45:50: INFO: fh.attrs.MaxPayloadSizeToTargetInBytesSupported = 1048576
    20:45:50: INFO: In handleRead('full_dump.bin')
    20:45:50: INFO: Looking for file 'full_dump.bin'
    
    
                                     (_)
            __      ____ _ _ __ _ __  _ _ __   __ _
            \ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
             \ V  V / (_| | |  | | | | | | | | (_| |
              \_/\_/ \__,_|_|  |_| |_|_|_| |_|\__, |
                                               __/ |
                                              |___/
    
    
    20:45:50: WARNING: Previous Filesize is 0 bytes. Therefore reading size of partition!! Please check 'full_dump.bin'
    20:45:50: INFO: =======================================================
    20:45:50: INFO: <read> (262144.0KB) 524288 sectors from location 0 FILE: 'full_dump.bin'
    20:45:50: INFO: =======================================================
    
    20:45:52: INFO: Overall to target  2.000 seconds (32.34 MBps)
    20:45:54: INFO: Overall to target  4.000 seconds (32.38 MBps)
    20:45:56: INFO: Overall to target  6.000 seconds (32.37 MBps)
    20:45:58: INFO: Overall to target  7.844 seconds (32.64 MBps)
    
    20:45:58: INFO: TARGET SAID: 'Finished reading from sector address 0 to 524288'
    20:45:58: INFO: =======================================================
    20:45:58: INFO: ===================== SUCCESS =========================
    20:45:58: INFO: =======================================================
    
    
    20:45:58: INFO: ==============================================================
    20:45:58: INFO: Files used and their paths
    20:45:58: INFO:   1 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt'
    20:45:58: INFO:   2 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\full_dump.bin'
    
    
    
                                     (_)
            __      ____ _ _ __ _ __  _ _ __   __ _
            \ \ /\ / / _` | '__| '_ \| | '_ \ / _` |
             \ V  V / (_| | |  | | | | | | | | (_| |
              \_/\_/ \__,_|_|  |_| |_|_|_| |_|\__, |
                                               __/ |
                                              |___/
    
    
    20:45:58: INFO: ==============================================================
    20:45:58: INFO: NOTE: There were WARNINGS!! Repeated here, but please see log for more detail
    Couldn't find the file 'full_dump.bin', returning NULL
    User specified --num_sectors=524288 but file only has 524288 sectors. **Ignoring --num_sectors
    
    
    Couldn't find the file 'full_dump.bin', returning NULL
    Previous Filesize is 0 bytes. Therefore reading size of partition!! Please check 'full_dump.bin'
    NOTE: There were WARNINGS!! Repeated above, but please see log for more detail
    
    
    
    20:45:58: INFO: ==============================================================
    20:45:58: INFO:      _             (done)
    20:45:58: INFO:     | |
    20:45:58: INFO:   __| | ___  _ __   ___
    20:45:58: INFO:  / _` |/ _ \| '_ \ / _ \
    20:45:58: INFO: | (_| | (_) | | | |  __/
    20:45:58: INFO:  \__,_|\___/|_| |_|\___|
    20:45:58: INFO: {All Finished Successfully}
    
    20:45:58: INFO: Overall to target  7.969 seconds (32.12 MBps)
    
    Writing log to 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt', might take a minute
    
    
    Log is 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt'

    You can use 7-Zip archiver to open this dump and extract any partition you want.


    Step 5B: Write the dump back to storage


    Open Partition Manager, and don't close it.

    Please copy following path to your File Explorer:
    Code:
    %AppData%\Qualcomm\QFIL
    This will redirect you to C:\Users\[your_user_name]\AppData\Roaming\Qualcomm\QFIL .
    Find the COMPORT_XX directory respective to your exact COM port - in this case, I choose COMPORT_8 for example.

    And open a command prompt or PowerShell window here.
    Execute following command here, remember to change the COM port number and num_sectors to your exact number, or the actual path of fh_loader.exe and your dump if possible:

    In this case, the dump is located at D:\path\to\your\dump\full_dump.bin .

    Code:
    "C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe" --port=\\.\COM8 --search_path=D:\path\to\your\dump --sendimage=full_dump.bin --start_sector=0 --lun=0 --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=emmc

    Now just wait for the procedure complete.

    The output should look like this:
    Code:
    20:05:30: INFO: Current working dir (cwd): C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\
    20:05:30: INFO: Showing network mappings to allow debugging
    20:05:30: INFO: Looking for file 'full_dump.bin'
    20:05:31: INFO: User wants to talk to port '\\.\COM8'
    20:05:31: INFO: Took       0.01600000 seconds to open port
    20:05:31: INFO: Sorting TAGS to ensure order is <configure>,<erase>, others, <patch>,<power>
    20:05:31: INFO: If  you don't want this, use --dontsorttags
    
    20:05:31: INFO: Looking for file 'full_dump.bin'
    20:05:31: INFO:
    
    Total to be tansferd with <program> or <read> is 36.09 GB
    
    
    20:05:31: INFO: Sending <configure>
    
    20:05:31: INFO: TARGET SAID: 'Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1''
    
    20:05:31: INFO: TARGET SAID: 'Calling hotplug_poll_device('MMC')'
    20:05:31: INFO: fh.attrs.MaxPayloadSizeToTargetInBytes = 1048576
    20:05:31: INFO: fh.attrs.MaxPayloadSizeToTargetInBytesSupported = 1048576
    20:05:31: INFO: In handleProgram('full_dump.bin')
    20:05:31: INFO: Looking for file 'full_dump.bin'
    20:05:31: INFO: =======================================================
    20:05:31: INFO: {<program> FILE: 'D:\path\to\your\dump\full_dump.bin'}
    20:05:31: INFO: {<program> (36.09 GB) 75685888 sectors needed at location 0 on LUN 0}
    20:05:31: INFO: =======================================================
    
    
    20:05:31: INFO: TARGET SAID: 'start 0, num 75685888'
    
    20:05:33: INFO: Overall to target  2.031 seconds (26.59 MBps)
    20:05:33: INFO: {percent files transferred   0.15%}
    20:05:35: INFO: Overall to target  4.063 seconds (26.34 MBps)
    20:05:35: INFO: {percent files transferred   0.29%}
    20:05:37: INFO: Overall to target  6.094 seconds (26.26 MBps)
    20:05:37: INFO: {percent files transferred   0.43%}
    20:05:39: INFO: Overall to target  8.110 seconds (26.26 MBps)
    20:05:39: INFO: {percent files transferred   0.58%}
    20:05:41: INFO: Overall to target 10.125 seconds (26.27 MBps)
    20:05:41: INFO: {percent files transferred   0.72%}
    20:05:43: INFO: Overall to target 12.141 seconds (26.27 MBps)
    20:05:43: INFO: {percent files transferred   0.86%}
    20:05:45: INFO: Overall to target 14.141 seconds (26.31 MBps)
    20:05:45: INFO: {percent files transferred   1.01%}
    20:05:47: INFO: Overall to target 16.156 seconds (26.49 MBps)
    20:05:47: INFO: {percent files transferred   1.16%}
    20:05:49: INFO: Overall to target 18.172 seconds (26.52 MBps)
    20:05:49: INFO: {percent files transferred   1.30%}
    20:05:51: INFO: Overall to target 20.188 seconds (26.55 MBps)
    20:05:51: INFO: {percent files transferred   1.45%}
    20:05:53: INFO: Overall to target 22.188 seconds (26.59 MBps)
    20:05:53: INFO: {percent files transferred   1.60%}
    20:05:55: INFO: Overall to target 24.188 seconds (26.62 MBps)
    20:05:55: INFO: {percent files transferred   1.74%}
    20:05:57: INFO: Overall to target 26.188 seconds (26.62 MBps)
    20:05:57: INFO: {percent files transferred   1.89%}
    20:05:59: INFO: Overall to target 28.188 seconds (26.61 MBps)
    20:05:59: INFO: {percent files transferred   2.03%}
    20:06:01: INFO: Overall to target 30.235 seconds (26.59 MBps)
    20:06:01: INFO: {percent files transferred   2.18%}
    20:06:03: INFO: Overall to target 32.266 seconds (26.56 MBps)
    20:06:03: INFO: {percent files transferred   2.32%}
    20:06:05: INFO: Overall to target 34.281 seconds (26.57 MBps)
    20:06:05: INFO: {percent files transferred   2.47%}
    20:06:07: INFO: Overall to target 36.328 seconds (26.56 MBps)
    20:06:07: INFO: {percent files transferred   2.61%}
    20:06:09: INFO: Overall to target 38.328 seconds (26.56 MBps)
    20:06:09: INFO: {percent files transferred   2.75%}
    20:06:11: INFO: Overall to target 40.360 seconds (26.56 MBps)
    20:06:11: INFO: {percent files transferred   2.90%}
    20:06:13: INFO: Overall to target 42.391 seconds (26.56 MBps)
    20:06:13: INFO: {percent files transferred   3.05%}
    
    (ignored too many logs)
    
    20:28:17: INFO: Overall to target 1366.235 seconds (26.33 MBps)
    20:28:17: INFO: {percent files transferred  97.33%}
    20:28:19: INFO: Overall to target 1368.266 seconds (26.33 MBps)
    20:28:19: INFO: {percent files transferred  97.48%}
    20:28:21: INFO: Overall to target 1370.281 seconds (26.33 MBps)
    20:28:21: INFO: {percent files transferred  97.63%}
    20:28:23: INFO: Overall to target 1372.313 seconds (26.33 MBps)
    20:28:23: INFO: {percent files transferred  97.78%}
    20:28:25: INFO: Overall to target 1374.313 seconds (26.33 MBps)
    20:28:25: INFO: {percent files transferred  97.93%}
    20:28:27: INFO: Overall to target 1376.344 seconds (26.34 MBps)
    20:28:27: INFO: {percent files transferred  98.08%}
    20:28:29: INFO: Overall to target 1378.344 seconds (26.34 MBps)
    20:28:29: INFO: {percent files transferred  98.22%}
    20:28:31: INFO: Overall to target 1380.360 seconds (26.34 MBps)
    20:28:31: INFO: {percent files transferred  98.37%}
    20:28:33: INFO: Overall to target 1382.375 seconds (26.34 MBps)
    20:28:33: INFO: {percent files transferred  98.51%}
    20:28:35: INFO: Overall to target 1384.406 seconds (26.34 MBps)
    20:28:35: INFO: {percent files transferred  98.66%}
    20:28:37: INFO: Overall to target 1386.438 seconds (26.34 MBps)
    20:28:37: INFO: {percent files transferred  98.80%}
    20:28:39: INFO: Overall to target 1388.438 seconds (26.34 MBps)
    20:28:39: INFO: {percent files transferred  98.94%}
    20:28:41: INFO: Overall to target 1390.453 seconds (26.34 MBps)
    20:28:41: INFO: {percent files transferred  99.09%}
    20:28:43: INFO: Overall to target 1392.485 seconds (26.34 MBps)
    20:28:43: INFO: {percent files transferred  99.25%}
    20:28:45: INFO: Overall to target 1394.516 seconds (26.34 MBps)
    20:28:45: INFO: {percent files transferred  99.40%}
    20:28:47: INFO: Overall to target 1396.531 seconds (26.34 MBps)
    20:28:47: INFO: {percent files transferred  99.55%}
    20:28:49: INFO: Overall to target 1398.750 seconds (26.33 MBps)
    20:28:49: INFO: {percent files transferred  99.66%}
    20:28:51: INFO: Overall to target 1400.766 seconds (26.33 MBps)
    20:28:51: INFO: {percent files transferred  99.81%}
    20:28:53: INFO: Overall to target 1402.797 seconds (26.33 MBps)
    20:28:53: INFO: {percent files transferred  99.96%}
    20:28:54: INFO: Overall to target 1403.422 seconds (26.33 MBps)
    20:28:54: INFO: {percent files transferred 100.00%}
    
    20:28:54: INFO: TARGET SAID: 'Finished programming start_sector 75685888 and TotalSectorsToProgram 75685888'
    20:28:54: INFO:
    20:28:54: INFO: =======================================================
    20:28:54: INFO: ==================== {SUCCESS} ========================
    20:28:54: INFO: =======================================================
    
    
    20:28:54: INFO: {percent files transferred 100.00%}
    20:28:54: INFO: ==============================================================
    20:28:54: INFO: Files used and their paths
    20:28:54: INFO:   1 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt'
    20:28:54: INFO:   2 'D:\path\to\your\dump\full_dump.bin'
    
    20:28:54: INFO:      _             (done)
    20:28:54: INFO:     | |
    20:28:54: INFO:   __| | ___  _ __   ___
    20:28:54: INFO:  / _` |/ _ \| '_ \ / _ \
    20:28:54: INFO: | (_| | (_) | | | |  __/
    20:28:54: INFO:  \__,_|\___/|_| |_|\___|
    20:28:54: INFO: {All Finished Successfully}
    
    20:28:54: INFO: Overall to target 1403.578 seconds (26.33 MBps)
    20:28:54: INFO: {percent files transferred 100.00%}
    
    Writing log to 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt', might take a minute
    
    
    Log is 'C:\Users\HikariCal\AppData\Roaming\Qualcomm\QFIL\COMPORT_8\port_trace.txt'

    If you only want to write back only one specific partition, you need to specify the start_sector value to the decimal value of a partition's Start LBA.
    Always keep the Partition Manager window opened!


    Step 6: Quit Partition Manager

    After everything dumped, you can close Partition Manager, the QFIL will reboot your phone back to EDL mode or reboot your phone back to normal mode.
    Then you can force reboot your phone or mess up your phone as you want.
    3
    Doing a full raw dump is only useful as a snapshot.
    If you want to backup useful data you'll have to backup files when userdata is mounted (and decrypted) by the system.
    2
    Anyone ever tried this on an ROG phone 2?
    2
    However, that file is in .bin format instead of .elf. How can I convert it, and is that safe?
    Firehose loaders are technically ELF 32 or 64 bit files but may be named elf, bin, img, mbn, whatever.
    Use a hex editor and look at the start of the file.
    It should be 7f 45 4c 46
    Or use my elfview.exe (in the sig) to check it out.
    Or use my qcomview.exe (in the sig) to check it out.
    Code:
    C:\>elfview /p motog.bin
     #  Type     Flags     Size  Offset  Address
    --  -------  -----  -------  ------  --------
     0  null     7         1016  000000  00000000
     1  null     2.2       7384  001000  4602c000
     2  load     RWZ          0  06b4b0  0c100000
     3  load     RX        7772  0549f0  0c119000
     4  load     RWZ          0  056850  0c11c000
     5  load     RWZ          0  06b4b0  0c11e000
     6  load     RWZ          0  0549f0  0c219000
     7  load     RX      301376  003000  0c225000
     8  load     RWZ          0  04c940  0c276c00
     9  load     RW       32932  04c940  0c279c00
    10  load     RWZ          0  0549f0  0c286c00
    11  load     RWX      85080  056850  0c29b000
    12  load     1RWX        84  06b4b0  0c2c9000
    13  load     1RWX     29168  06b504  0c2c9054
    14  load     1RWX      1496  0726f4  0c2d0244
    15  load     5RX     139264  072ccc  0c350000
    16  load     RWZ          0  0549f0  45e11000
    
    C:\>qcomview /h motog.bin
    64 bit ELF, Version 6, SHA384
     0  00000000  000003f8  a3836cd6c3e2dbed 5dd00c97349c8598 92a5051c08ae65d4 171ba1ece407a7b2 1cdf27a97ff437c7 0488bb944956fbc2  Ok
     1  00001000  00001cd8
     2  0006b4b0  00000000
     3  000549f0  00001e5c  3972d9e5346b52cc e71c31a437500b8f 57f2fc8124e97cd5 b2f70a4829e98196 03d89d4b946261e2 9b2a58949b92b7dc  Ok
     4  00056850  00000000
     5  0006b4b0  00000000
     6  000549f0  00000000
     7  00003000  00049940  503b424c75f6d657 e4363c830deeebee afe0ac82ce04dfec e8ac03fb47b129a3 fc221acc0d515b22 ed17d86b0f6b585c  Ok
     8  0004c940  00000000
     9  0004c940  000080a4  2f7aec3605fbce70 ec0c83a703435845 e969988f390787d7 aa8d0a13a6d9e06f ee2af4e9b86b8a75 fc81fbe1017d1c64  Ok
    10  000549f0  00000000
    11  00056850  00014c58  fec3a6b9f6d71a18 aadd3f722fc73bea d3197c24c397d55d 4f3d4a9c25661db1 152c60664fcbe4a6 c2441120afc4b3c9  Ok
    12  0006b4b0  00000054  db139c6f70d88269 a61cb1a7be2ce363 55faf1ff1c3b9c3d 27cd8d65bef7f710 9bc83c6255ea8104 6d7ac582cc778f15  Ok
    13  0006b504  000071f0  a27a7dc0040a1bfa 8e24e4a42bead90e ae10a91c37d19105 bce9da69383004ea c933b87ac4a88653 ccbb4a6b1407d15d  Ok
    14  000726f4  000005d8  8dcaae787361a3c4 3bad6d344641d061 35170b5a30607e20 a30cd23884bbc0b0 790681aa36a1fe60 98501a103b62088a  Ok
    15  00072ccc  00022000  1f939df47e7fae80 2c127e10474ff9e6 2faecd5fab873bf8 928cab0a5ef28261 5d4b19cc57cca817 37fa9fad42971c40  Ok
    16  000549f0  00000000
    1
    This is the file I have. QFIL only accepts .elf or .mbn files.
    It's a perfectly fine Firehose loader.
    Just rename it .elf
    Or use an EDL client that isn't so picky on stupid stuff.
    Like the Python EDL client. Or mine.