Owners of smartphones based on Android often face a critical lack of free space in the internal memory. When standard cleaning methods and uninstalling applications no longer help, users with superuser rights (Root) begin to explore the root directory of the file system. This is a dangerous path, since one wrong step can turn the device into a โ€œbrick.โ€

The root folder contains system data, kernel settings and configuration files, without which the operating system will not be able to boot. However, there are specific directories in which the accumulation of garbage is a normal process of operating the OS, and their contents can be safely cleaned. In this article, we will look in detail at where gigabytes of useless data are hidden and how to delete them without disrupting the functionality of the gadget.

Before taking any action, you need to understand the structure of the file system ext4 or f2fsused in modern smartphones. User access to the root (/) is usually closed, and manipulation requires special file managers like Root Explorer or Solid Explorer with activated privileges.

Root directory structure and entry points

File system Android hierarchical and strictly regulated by standards Linux. When you open the root directory, you will see many folders with strange names: bin, system, vendor, proc. Most of them are critical for loading the kernel and operating hardware drivers.

The bulk of user data and application cache is stored not in the root itself, but in mounted partitions that are writable. The key points of interest for cleaning are the directories /data and /cache. This is where error logs, temporary installation files and remnants of deleted apps accumulate.

โš ๏ธ Attention: Never delete or rename folders system, vendor, boot or recovery. Removing them will result in the immediate loss of the ability to boot the device (Bootloop).

For safe navigation, use the backup function before making any changes. Some file managers allow you to make a backup of the deleted folder directly to a memory card SD. This is the only insurance if you accidentally touch the system configuration file.

๐Ÿ“Š How do you usually free up space on your smartphone?
Deleting photos and videos
Clearing the application cache
Resetting the settings to factory settings
I use Root access to clean the system

Safely clearing the Cache directory

The folder /cache at the root of the file system is designed to store temporary data that speeds up the operation of the system and applications. This includes the compilation results Dalvik/ART, temporary update files and package installer logs. Over time, this section can grow to several gigabytes.

Cleaning the contents of this directory is completely safe for user data. The next time you boot, the system will automatically recreate the necessary files, although the first start may take a little longer due to re-optimization of applications. This is a standard procedure when troubleshooting software failures.

To perform a manual cleanup, go to the path /cache and select all the files and folders inside, but do not delete the directory itself cache. After removal, you will need to reboot the device. If you are not sure of your actions, the same operation can be performed through the mode Recovery (Wipe Cache Partition item).

  • ๐Ÿ—‘๏ธ Delete the contents of the folder /cache only when the phone is turned off or through a special file manager with root access.
  • โšก After cleaning The first start of the system may be slower than usual due to the cache rebuild.
  • ๐Ÿ“‚ Do not delete the folder itself cache, only the files inside it, to preserve the structure of access rights.
๐Ÿ’ก

If after clearing the cache the phone starts to work slower, give it 10-15 minutes alone on the desktop - the system will shut down background processes optimization.

Analysis and cleaning of the Data section

The section /data is the most voluminous storage of user information. Here are the folders for all installed applications, contact databases, messages and settings. Directly deleting folders in /data/app or /data/data is equivalent to deleting applications, but without correctly deleting entries from the system registry.

The most interesting folder to clean is the /data/tombstonesfolder. It stores memory dumps (error reports) created by the system when applications are forced to close (crashes). If your smartphone is stable, these files are useless and take up valuable space. They can be deleted selectively or completely.

You should also pay attention to the folder /data/local/tmp. Some scripts and installers save temporary data here. Check its contents: if there are no important files that you deliberately placed there, cleaning will be painless. Be extremely careful with the folder /data/system โ€”deleting files from there will reset the interface settings and graphic keys.

Directory Purpose Is it possible to delete Consequences
/data/tombstones Error (crash) reports Yes, completely None, space will be freed up
/data/local/tmp Temporary terminal files Yes, selectively Possible loss of temporary logs
/data/app Installed applications No (only through settings) Loss of application data, system errors
/data/system OS and account settings Absolutely no Reset settings, loss of unlocking

Remember that manually deleting application folders from /data/app leaves โ€œtailsโ€ in the package manager database. This may cause the system to consider the application installed, although its files are not present. Use standard uninstallation or utilities like Titanium Backup for correct uninstallation.

Cleaning logs and debug information

The system Android continuously maintains event logs, which are saved in various directories of the root partition. Log files (logging) are needed by developers for debugging, but they do not bring any benefit to the average user, they just take up space.

The main logs are often located in the /data/log or /data/tombstonesfolder, which have already been mentioned. It is also worth checking the presence of the folder /data/anr (Application Not Responding). Reports about app freezes are stored there. If you do not plan to send these reports to developers to fix bugs, you can safely erase them.

adb logcat -c

This command, entered through a computer with debugging mode enabled, clears the log buffer in real time. However, it is better to use a file manager to clean up files on the disk. Regular cleaning of logs can slightly improve I/O performance on older devices with slow flash memory.

โš ๏ธ Attention: Interfaces and locations of system folders may vary depending on the version Android and the manufacturer's shell (MIUI, OneUI, ColorOS). Always check the documentation for your specific model before deleting.

Removing remnants of updates and backups

After successfully updating the operating system via OTA (over the air), installation packages often remain in memory. They can be located in hidden sections or in a folder /data/ota_package. If the update was successful and the phone works stably, these files are no longer needed.

Another source of garbage is backup folders. Many manufacturers create local backups of the system in the root or /data/backup. If you have a fresh copy in the cloud or on your computer, local archives from a year ago can be deleted. This often frees up 1 to 3 GB of space.

How to find hidden update files?

Turn on showing hidden files in File Explorer settings. Look for files with a .zip extension or folders with names containing Android version numbers (for example, 11.0.5).

Also check the folder /mnt or /storage. Sometimes temporary mount points are created there for external cards or USB drives, in which empty or garbage directories remain after incorrect removal of the media. Removing them is safe if nothing is currently connected to the phone.

Using specialized utilities

Manually cleaning the root folder requires high qualifications and care. It is much safer to use proven applications that automate this process and know which files can be touched and which cannot. One of the most powerful utilities is SDS Maid or specialized scripts for Magisk.

These apps scan the file system, identify garbage (logs, cache, empty folders) and offer to delete it with one click. They can also find "orphan" files - remnants of long-deleted applications that the user may have missed during manual cleaning.

  • ๐Ÿ›ก๏ธ Use applications with good reviews to avoid deleting critical system files.
  • ๐Ÿ”„ Regularly update cleaner databases to support new versions. Android.
  • ๐Ÿ“‰ Monitor the partition size /data before and after cleaning to evaluate the effectiveness.

โ˜‘๏ธ Preparing for manual cleaning Root

Done: 0 / 4
๐Ÿ’ก

Automatic cleaners are safer manual cleaning, as they use whitelists of protected system files, preventing fatal user errors.

Frequently asked questions (FAQ)

What happens if I accidentally delete the System folder?

Deleting a folder /system will cause the phone to stop booting. You will end up in an endless reboot loop or emergency recovery mode. To correct the situation, you will need to flash the device via a computer with the loss of all data.

Is it possible to delete files with the .log extension manually?

Yes, files with the extension .log in user directories and folders /data/tombstones can be deleted. However, do not touch the logs inside the folder /proc or /sysas they are virtual kernel interface files and deleting them may cause drivers to crash.

Will clearing the Dalvik-cache folder free up space?

Folder /data/dalvik-cache (or art) takes up a lot of space, but clearing it is a temporary measure. The system will recreate this cache on the first boot, and the space will be occupied again. It makes sense to clean it only when updating the firmware or solving specific application conflicts.

Is it safe to delete the Vendor folder?

No, the folder /vendor contains hardware drivers (camera, modem, screen) specific to your phone model. Removing it will make the key functions of the device inoperable or lead to a complete system failure.