Skip to content

[Bug]:termux-setup-storage hangs on Android 13 #5267

Description

@Hackerpower

Problem description

After installing a fresh F-Droid Termux installation, running termux-setup-storage hangs indefinitely and does not create ~/storage.

The same issue occurred before reinstalling Termux, and it still occurs after a completely fresh installation.

Device: Xiaomi 2201117TG
Android: 13
Termux: F-Droid 0.119.0-beta.2
termux-tools: 1.45.0
Architecture: aarch64

The device's shared storage is accessible directly from Termux:
ls /storage/emulated/0 works and shows folders such as Download, DCIM, Pictures, Music, and Movies.

However, termux-setup-storage does not complete and no ~/storage directory is created.

Steps to reproduce the behavior.

  1. Install Termux from F-Droid.
  2. Open Termux.
  3. Run:
    pkg update && pkg upgrade
  4. Run:
    termux-setup-storage
  5. The command hangs indefinitely and does not create ~/storage.
  6. Pressing Ctrl+C returns to the shell.
  7. Run:
    ls -la ~/storage
  8. Result:
    ls: cannot access '/data/data/com.termux/files/home/storage': No such file or directory.

What is the expected behavior?

termux-setup-storage should request/obtain the required storage permission and create the ~/storage directory with the appropriate storage symlinks.

Image

System information

  • Termux application version: 0.119.0-beta.2 (F-Droid)
  • Android OS version: Android 13
  • Device model: Xiaomi 2201117TG

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions