Selling my phone. What sections can be cleared?

Hi all . I plan to sell the phone and would like to ask the community which sections can be cleared. (I’m interested in exactly this method) I use dd . Below is the list of sections
I also wanted to know in which sections errors are recorded in order to clear this section.

lrwxrwxrwx 1 root root 15 2023-06-14 22:06 BOOT -> /dev/block/sda5
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 BOTA0 -> /dev/block/sda1
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 BOTA1 -> /dev/block/sda2
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 CACHE -> /dev/block/sda15    Yes, this section can be cleared
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 CPEFS -> /dev/block/sdd1
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 CP_DEBUG -> /dev/block/sda17
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 DNT -> /dev/block/sda10
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 EFS -> /dev/block/sda3
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 HIDDEN -> /dev/block/sda16
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 OTA -> /dev/block/sda7       Yes, this section can be cleared
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 PARAM -> /dev/block/sda4
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 PERSDATA -> /dev/block/sda13  Yes, this section can be cleared
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 PERSISTENT -> /dev/block/sda11
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 RADIO -> /dev/block/sda8
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 RECOVERY -> /dev/block/sda6
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 STEADY -> /dev/block/sda12
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 SYSTEM -> /dev/block/sda14
lrwxrwxrwx 1 root root 15 2023-06-14 22:06 TOMBSTONES -> /dev/block/sda9 Yes, this section can be cleared
lrwxrwxrwx 1 root root 16 2023-06-14 22:06 USERDATA -> /dev/block/sda18  Yes, this section can be cleared

Regain your privacy! Adopt /e/ the unGoogled mobile OS and online servicesphone

I’m unfamiliar with the PERSDATA partition, but everything else marked I know is fine to be set back.

But beware, zeroing with dd is not the magnetic dd type of days. Flash controllers have their own and more reliant erase mechanism. fastboot erase <partition> is imo what you want to do.

adb recovery also has a --wipe-data command that wraps the partitions too

2 Likes

Hello . Thank you very much for your reply.

In my post, I wanted to understand which partitions I can wipe (wipe) As far as I understand, the dd utility is the best option than soft erasing --wipe-data

Here are my steps before selling the phone:

adb device

adb shell

su

cd /dev/block/platform/.../by-name/ 

umount -l /dev/block/sda15


dd if=/dev/urandom of=/dev/block/sda15 bs=1M

I think it’s bad advice dd’ing flash storage, but please go ahead. Bestcase userdata was encrypted anyway, I’d rather check if trustzone enrolls new keys with a reset mechanism

1 Like

Thank you very much for your replies.

We will wait for the response of users who know which sections can be erased and which cannot.

Somewhere there is a factory reset. Let me search and I’ll come back reporting on it


Under reset options in settings

Hello . Thanks for your reply.

As for resetting to factory settings, this is not a problem for me)

I’m looking for information which sections can be overwritten and which ones are better left untouched.
And the dd utility is the best way for those who want to recover your data.

This topic was automatically closed after 90 days. New replies are no longer allowed.