termux / proot-distro

An utility for managing installations of the Linux distributions in Termux.
GNU General Public License v3.0
1.8k stars 208 forks source link

Logging into Debian doesnt work #444

Closed Comy112 closed 2 months ago

Comy112 commented 2 months ago

Problem description

Screenshot_20240908_154914_Termux

What steps will reproduce the bug?

I log into proot with proot-distro login debian --shared-tmp it works i type exit exits proot i pack my stuff, go out with friend and in meantime i wanted to show him about proot it doesnt log in i exit termux and reenter, try to login again, doesnt work i start to slam my phone off the desk, try again, doesnt work (did this 6 times) i try proot-distro clear proot-distro remove debian proot-distro install debian nope, wont install debian i uninstall proot-distro

What is the expected behavior?

.

Biswa96 commented 2 months ago

proot Debian installation failed in my setup also but with different error than OP.

Click here to see the error log ``` $ pd install debian [*] Installing Debian (bookworm)... [*] Creating directory '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian'... [*] Creating directory '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/.l2s'... [*] Using cached rootfs tarball... [*] Checking integrity, please wait... [*] Extracting rootfs, please wait... [*] Writing file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/environment'... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/bash.bashrc' if needed... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/profile' if needed... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/login.defs' if needed... [*] Creating file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/resolv.conf'... [*] Creating file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/hosts'... [*] Registering Android-specific UIDs and GIDs... [*] Running distribution-specific configuration steps... Generating locales (this might take a while)... en_US.UTF-8... done Generation complete. *** update-locale: Error: invalid locale settings: LANG=en_US.UTF-8 [!] Exiting due to failure. ```
Comy112 commented 2 months ago

proot Debian installation failed in my setup also but with different error than OP.

Click here to see the error log ``` $ pd install debian [*] Installing Debian (bookworm)... [*] Creating directory '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian'... [*] Creating directory '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/.l2s'... [*] Using cached rootfs tarball... [*] Checking integrity, please wait... [*] Extracting rootfs, please wait... [*] Writing file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/environment'... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/bash.bashrc' if needed... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/profile' if needed... [*] Updating PATH in '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/login.defs' if needed... [*] Creating file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/resolv.conf'... [*] Creating file '/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/debian/etc/hosts'... [*] Registering Android-specific UIDs and GIDs... [*] Running distribution-specific configuration steps... Generating locales (this might take a while)... en_US.UTF-8... done Generation complete. *** update-locale: Error: invalid locale settings: LANG=en_US.UTF-8 [!] Exiting due to failure. ```

proot aint working for us πŸ₯ΆπŸ—£πŸ—£πŸ—£πŸ—£πŸ”₯πŸ”₯πŸ”₯πŸ”₯πŸ”₯πŸ”₯🚬

Biswa96 commented 2 months ago

I am using proot with other distributions. Unfortunately, I am not familiar with Debian or Ubuntu environment and can not suggest any solution.

Biswa96 commented 2 months ago

Some hint. The dpkg-reconfigure locales command fails in https://github.com/termux/proot-distro/blob/master/distro-plugins/debian.sh script. I have been using locale-gen command to generate locale.

Comy112 commented 2 months ago

Ah i see

Comy112 commented 2 months ago

https://media.discordapp.net/attachments/955349075258146876/1282435515412385938/Screenshot_20240908_221602_Termux.jpg?ex=66df58a5&is=66de0725&hm=615a872eb2c843d189a995625393e89ab2bea20931904af3c38f8f489d4d88a5& Even better, another issue.

Biswa96 commented 2 months ago

Even better, another issue.

That could be issue in your system only. proot-distro depends on proot.

sylirre commented 2 months ago

Are you playing with non-native architectures or custom system versions so proot-distro suddenly started to fail for you?

It did not receive updates for couple of months which means components proot-distro script itself, Debian rootfs and debian.sh plugin script did not change and supposed to work. It was tested by me before release, also it is known that specifically "debian" distro works for some other people.

I can't confirm the presence of issue on up-to-date Termux:

Screenshot_20240908-233313_Termux

Proot Distro is just a bash script wrapper around proot. If proot fails on your device, so does proot-distro. In your case it looks like failure happened right during unpacking of rootfs archive because proot used even to execute tar -Jxf command to be able extract hard links.

Also pay attention that support doesn't cover modifications of Proot Distro components. If you used to make changes to $PREFIX/etc/proot-distro/debian.sh, you are on your own if did mistakes.