Android终端模拟器Termux上使用Ubuntu

Termux 上安装各种 Linux 系统是通过 proot-distro 工具来实现的,所以先安装一下 proot-distro 工具。

shell 复制代码
~ $ pkg install proot-distro 

查看Termux支持安装那些Linux

shell 复制代码
~ $ proot-distro list

Supported distributions:

  * Alpine Linux

    Alias: alpine
    Installed: no
    Comment: Rolling release branch (edge).

  * Arch Linux

    Alias: archlinux
    Installed: no
    Comment: Currently available only AArch64 and ARM ports.

  * Artix Linux

    Alias: artix
    Installed: no
    Comment: Currently available only for AArch64.

  * Debian

    Alias: debian
    Installed: no
    Comment: A stable release (bookworm).

  * deepin

    Alias: deepin
    Installed: no
    Comment: Supports only 64-bit CPUs.

  * Fedora

    Alias: fedora
    Installed: no
    Comment: Version 39. Supports only 64-bit CPUs.

  * Manjaro

    Alias: manjaro
    Installed: no
    Comment: Currently available only for AArch64.

  * OpenSUSE

    Alias: opensuse
    Installed: no
    Comment: Rolling release (Tumbleweed).

  * Pardus (yirmibir)

    Alias: pardus
    Installed: no

  * Ubuntu

    Alias: ubuntu
    Installed: no
    Comment: Standard release (mantic). Not available for x86 32-bit (i686) CPUs.

  * Void Linux

    Alias: void
    Installed: no

Install selected one with: proot-distro install <alias>

这里我们选择安装 Ubuntu 系统

shell 复制代码
~ $ proot-distro install ubuntu

安装完成后,登录 Ubuntu 系统

shell 复制代码
~ $ proot-distro login ubuntu
root@localhost:~# 

查看一下 Ubuntu 版本

shell 复制代码
root@localhost:~# cat /etc/os-release 
PRETTY_NAME="Ubuntu 23.10"
NAME="Ubuntu"
VERSION_ID="23.10"
VERSION="23.10 (Mantic Minotaur)"
VERSION_CODENAME=mantic
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=mantic
LOGO=ubuntu-logo

最后提一句,安装过程如果出现下面的错误

shell 复制代码
CANNOT LINK EXECUTABLE "curl": library "libssl.so.1.1" not found: needed by /data/data/com.termux/files/usr/lib/libssh2.so in namespace (default)

可以执行一下完整的升级操作,再安装

shell 复制代码
apt full-upgrade
相关推荐
No Silver Bullet15 分钟前
android组包时会把从maven私服获取的包下载到本地吗
android
catchadmin17 分钟前
PHP serialize 序列化完全指南
android·开发语言·php
tangweiguo030519872 小时前
Kable使用指南:Android BLE开发的现代化解决方案
android·kotlin
Galeoto4 小时前
how to setup k3s on an offline ubuntu
linux·运维·ubuntu
00后程序员张4 小时前
iOS App 混淆与资源保护:iOS配置文件加密、ipa文件安全、代码与多媒体资源防护全流程指南
android·安全·ios·小程序·uni-app·cocoa·iphone
柳岸风6 小时前
Android Studio Meerkat | 2024.3.1 Gradle Tasks不展示
android·ide·android studio
编程乐学6 小时前
安卓原创--基于 Android 开发的菜单管理系统
android
小猪写代码8 小时前
Ubuntu C编程 (make工具和Makefile的引用)
linux·运维·ubuntu
whatever who cares8 小时前
android中ViewModel 和 onSaveInstanceState 的最佳使用方法
android
毕设源码-钟学长8 小时前
【开题答辩全过程】以 Android的传统中医诊断管理系统为例,包含答辩的问题和答案
android